forked from TrueCloudLab/restic
CI: Ensure that github containers match the official binaries
The binaries accidentally included VCS information whereas binaries built from the release tarball do not. For consistency remove the .git directory before building the container on Github.
This commit is contained in:
parent
b2b0856908
commit
bd3816fa14
1 changed files with 7 additions and 0 deletions
7
.github/workflows/docker.yml
vendored
7
.github/workflows/docker.yml
vendored
|
@ -47,6 +47,13 @@ jobs:
|
|||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@f95db51fddba0c2d1ec667646a06c2ce06100226
|
||||
|
||||
- name: Ensure consistent binaries
|
||||
run: |
|
||||
echo "removing git directory for consistency with release binaries"
|
||||
rm -rf .git
|
||||
# remove VCS information from release builds, keep VCS for nightly builds on master
|
||||
if: github.ref != 'refs/heads/master'
|
||||
|
||||
- name: Build and push Docker image
|
||||
uses: docker/build-push-action@f2a1d5e99d037542a71f64918e516c093c6f3fc4
|
||||
with:
|
||||
|
|
Loading…
Reference in a new issue