mirror of
https://github.com/octoleo/restic.git
synced 2024-11-22 04:45:15 +00:00
CI: Remove .dockerignore to ensure reproducible builds
Since go 1.18, built binaries also include VCS information such as the built commit. This information is also included in the official binaries. To ensure that the Docker container recreates the same binaries, the .git folder must also be transferred into the container. Thus, remove the .dockerignore file. The copied files must also be owned by the current user within the container, as git refuses to work otherwise.
This commit is contained in:
parent
6b82cce1bd
commit
3a93e28605
@ -1,11 +0,0 @@
|
||||
# Folders
|
||||
.git/
|
||||
.github/
|
||||
changelog/
|
||||
doc/
|
||||
docker/
|
||||
|
||||
# Files
|
||||
.gitignore
|
||||
.golangci.yml
|
||||
*.md
|
@ -5,7 +5,7 @@ FROM --platform=linux/amd64 restic/builder:latest as helper
|
||||
ARG TARGETOS
|
||||
ARG TARGETARCH
|
||||
|
||||
COPY . /restic
|
||||
COPY --chown=build . /restic
|
||||
RUN go run helpers/build-release-binaries/main.go --platform $TARGETOS/$TARGETARCH --skip-compress
|
||||
RUN mv /output/restic_${TARGETOS}_${TARGETARCH} /output/restic
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user