Skip to content

use lowercase tag name #3

use lowercase tag name

use lowercase tag name #3

Workflow file for this run

name: Build and push Docker image
on:
push:
# branches:
# - main
jobs:
build-and-push:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Get lower case repository owner
id: repo_owner
users: ASzc/change-string-case-action@v4
with:
repo_owner: ${{ github.repository_owner }}
- name: Build image
uses: docker/build-push-action@v4
with:
context:
file: ./Dockerfile
push: true
tags: |
ghcr.io/${{ steps.repo_owner.outputs.lowercase }}/shinynbis:latest
ghcr.io/${{ steps.repo_owner.outputs.lowercase }}/shinynbis:${{ needs.tag.outputs.tag }}
labels: |
org.opencontainers.image.source=${{ github.event.repository.clone_url }}
org.opencontainers.image.created=$(date -u +'%Y-%m-%dT%H:%M:%SZ')
org.opencontainers.image.revision=${{ github.sha }}