corso/build/Dockerfile
InfraOwner d4ecd53507
[Snyk] Security upgrade alpine from 3.16 to 3.17 (#2439)
<p>This PR was automatically created by Snyk using the credentials of a real user.</p><br />Keeping your Docker base image up-to-date means you’ll benefit from security fixes in the latest version of your chosen image.

#### Changes included in this PR 


- build/Dockerfile

We recommend upgrading to `alpine:3.17`, as this image has only 0 known vulnerabilities. To do this, merge this pull request, then verify your application still works as expected.


---

**Note:** _You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs._

For more information: <img src="https://api.segment.io/v1/pixel/track?data=eyJ3cml0ZUtleSI6InJyWmxZcEdHY2RyTHZsb0lYd0dUcVg4WkFRTnNCOUEwIiwiYW5vbnltb3VzSWQiOiJjOTU1YTFkNC1iNzhlLTQyNWMtODdhZC0zYTJmNmVhMmFlM2MiLCJldmVudCI6IlBSIHZpZXdlZCIsInByb3BlcnRpZXMiOnsicHJJZCI6ImM5NTVhMWQ0LWI3OGUtNDI1Yy04N2FkLTNhMmY2ZWEyYWUzYyJ9fQ==" width="0" height="0"/>
🧐 [View latest project report](https://app.snyk.io/org/alcion/project/4c1165db-1d77-4278-b861-48e29b49c4e7?utm_source&#x3D;github-enterprise&amp;utm_medium&#x3D;referral&amp;page&#x3D;fix-pr)

🛠 [Adjust project settings](https://app.snyk.io/org/alcion/project/4c1165db-1d77-4278-b861-48e29b49c4e7?utm_source&#x3D;github-enterprise&amp;utm_medium&#x3D;referral&amp;page&#x3D;fix-pr/settings)

[//]: # 'snyk:metadata:{"prId":"c955a1d4-b78e-425c-87ad-3a2f6ea2ae3c","prPublicId":"c955a1d4-b78e-425c-87ad-3a2f6ea2ae3c","dependencies":[{"name":"alpine","from":"3.16","to":"3.17"}],"packageManager":"dockerfile","projectPublicId":"4c1165db-1d77-4278-b861-48e29b49c4e7","projectUrl":"https://app.snyk.io/org/alcion/project/4c1165db-1d77-4278-b861-48e29b49c4e7?utm_source=github-enterprise&utm_medium=referral&page=fix-pr","type":"auto","patch":[],"vulns":[],"upgrade":[],"isBreakingChange":false,"env":"prod","prType":"fix","templateVariants":["updated-fix-title"],"priorityScoreList":[]}'

---

**Learn how to fix vulnerabilities with free interactive lessons:**

 🦉 [Learn about vulnerability in an interactive lesson of Snyk Learn.](https://learn.snyk.io/?loc&#x3D;fix-pr)
2023-02-08 19:00:29 +00:00

31 lines
1.0 KiB
Docker

FROM golang:1.19-alpine as builder
WORKDIR /go/src/app
COPY src .
ARG CORSO_BUILD_LDFLAGS=""
RUN go build -o corso -ldflags "$CORSO_BUILD_LDFLAGS"
FROM alpine:3.17
LABEL org.opencontainers.image.title="Corso"
LABEL org.opencontainers.image.description="Free, Secure, and Open-Source Backup for Microsoft 365"
LABEL org.opencontainers.image.url="https://github.com/alcionai/corso"
LABEL org.opencontainers.image.source="https://github.com/alcionai/corso"
LABEL org.opencontainers.image.vendor="Alcion, Inc."
COPY --from=builder /go/src/app/corso /corso
# Pull tls certs directly from latest upstream image
COPY --from=alpine:latest /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
ENV CORSO_HOME=/app/corso
ENV CORSO_CONFIG_DIR=$CORSO_HOME \
KOPIA_CONFIG_PATH=$CORSO_HOME/kopia/config/repository.config \
KOPIA_LOG_DIR=$CORSO_HOME/kopia/logs \
KOPIA_CACHE_DIRECTORY=$CORSO_HOME/kopia/cache \
RCLONE_CONFIG=$CORSO_HOME/kopia/rclone/rclone.conf \
KOPIA_PERSIST_CREDENTIALS_ON_CONNECT=false \
KOPIA_CHECK_FOR_UPDATES=false
ENTRYPOINT ["/corso"]