Skip to content

Docker Build and Push #4

Docker Build and Push

Docker Build and Push #4

Workflow file for this run

name: Docker Build and Push
on:
push:
branches:
- main
paths-ignore:
- README.md
- .gitignore
- .github/**
- pi-imager/**
workflow_dispatch:
jobs:
container:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Docker Build
shell: bash
run: |
cd docker
DOCKER_BUILDKIT=1 docker build . -t ghcr.io/${GITHUB_REPOSITORY,,}:$(date +%Y%m%d.$GITHUB_RUN_NUMBER)
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Docker Publish
shell: bash
run: |
docker push ghcr.io/${GITHUB_REPOSITORY,,}:$(date +%Y%m%d.$GITHUB_RUN_NUMBER)