This repository has been archived by the owner on Jun 11, 2024. It is now read-only.
chore: add or force update .github/workflows/tagpush.yml #295
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish Docker image | |
on: | |
push | |
jobs: | |
push_to_registry: | |
name: Push Docker image to Docker Hub | |
environment: DockerBuilders | |
runs-on: ubuntu-latest | |
env: | |
IMAGE_NAME: libp2p/hydra-booster | |
steps: | |
- name: Check out the repo | |
uses: actions/checkout@v3 | |
- name: Set SHORT_SHA | |
run: echo $GITHUB_SHA | head -c7 > SHORT_SHA | |
- name: Build Docker image | |
run: docker build -t $IMAGE_NAME:$(cat SHORT_SHA) . | |
- name: Log in to Docker Hub | |
uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Publish SHORT_SHA tag to Docker Hub | |
run: docker push ${IMAGE_NAME}:$(cat SHORT_SHA) |