AdventureLog v0.1.4-alpha #7
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: Upload Docker image to GHCR | |
on: | |
release: | |
types: [published] | |
env: | |
IMAGE_NAME: "adventurelog" | |
jobs: | |
upload: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Login to GitHub Container Registry | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.ACESS_TOKEN }} | |
- name: Build Docker image | |
run: docker build -t $IMAGE_NAME:${{ github.event.release.tag_name }} . | |
- name: Tag Docker image | |
run: docker tag $IMAGE_NAME:${{ github.event.release.tag_name }} ghcr.io/${{ github.repository_owner }}/$IMAGE_NAME:${{ github.event.release.tag_name }} | |
- name: Push Docker image to GHCR | |
run: docker push ghcr.io/${{ github.repository_owner }}/$IMAGE_NAME:${{ github.event.release.tag_name }} |