mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-25 22:26:42 +00:00
fixing taging for dockerBuild
This commit is contained in:
parent
9eaebea023
commit
3f18d0f6e3
1 changed files with 9 additions and 10 deletions
15
.github/workflows/dockerBuild.yml
vendored
15
.github/workflows/dockerBuild.yml
vendored
|
|
@ -18,6 +18,10 @@ jobs:
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
|
- name: Get short commit SHA
|
||||||
|
id: vars
|
||||||
|
run: echo "COMMIT_SHA=$(echo $GITHUB_SHA | cut -c1-7)" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Build Docker image
|
- name: Build Docker image
|
||||||
run: |
|
run: |
|
||||||
docker build -t my_first_container .
|
docker build -t my_first_container .
|
||||||
|
|
@ -28,14 +32,9 @@ jobs:
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
|
||||||
- name: Tag and push image
|
- name: Tag and push Docker image
|
||||||
uses: docker/login-action@v3
|
|
||||||
with:
|
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
|
||||||
|
|
||||||
- name: Tag and push image
|
|
||||||
run: |
|
run: |
|
||||||
docker tag my_first_container yohands/my_first_container:latest
|
docker tag my_first_container yohands/my_first_container:latest
|
||||||
|
docker tag my_first_container yohands/my_first_container:${{ env.COMMIT_SHA }}
|
||||||
docker push yohands/my_first_container:latest
|
docker push yohands/my_first_container:latest
|
||||||
|
docker push yohands/my_first_container:${{ env.COMMIT_SHA }}
|
||||||
Loading…
Reference in a new issue