Include git info into docker build, show git ref at version (#3829)
* ci: include .git directory into build * p2p: include git ref into version for user agent, show git commit hash instead of last tag into log * p2p: do not show anything after version if git commit hash is empty * fix: user agent typo
This commit is contained in:
@@ -41,13 +41,12 @@ jobs:
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v6
|
||||
|
||||
- name: Build and push by digest
|
||||
id: build
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
build-args: |
|
||||
BUILDKIT_CONTEXT_KEEP_GIT_DIR=1
|
||||
provenance: false # Disable provenance to avoid unknown/unknown
|
||||
sbom: false # Disable sbom to avoid unknown/unknown
|
||||
platforms: ${{ matrix.platform }}
|
||||
|
||||
Reference in New Issue
Block a user