Skip to content

Build Docker

Build Docker #3

Workflow file for this run

name: Build Docker
on:
push:
branches:
- "main"
schedule:
- cron: "0 0 * * sun"
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to GHCR
uses: docker/login-action@v1
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
push: true
context: .
file: ./Dockerfile
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:latest
platforms: |
linux/amd64
linux/arm64