Skip to content

Build & Push container to GH registry #26

Build & Push container to GH registry

Build & Push container to GH registry #26

name: Build & Push container to GH registry
on:
push:
schedule:
- cron: '0 12 15 * *'
workflow_dispatch:
permissions:
contents: write
jobs:
build-container:
runs-on: ubuntu-latest
steps:
-
name: Checkout source
uses: actions/checkout@v4
-
name: Login to ghcr.io
uses: docker/login-action@v3
with:
registry: ghcr.io
username: yimura
password: ${{ secrets.PACKAGE_WRITE_TOKEN }}
-
name: Build and push container
uses: docker/build-push-action@v6
with:
pull: true
push: true
tags: ghcr.io/yimura/lancache-prefill-cron:latest
-
name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: yimura
password: ${{ secrets.DOCKER_TOKEN }}
-
name: Build and push container
uses: docker/build-push-action@v6
with:
pull: true
push: true
tags: yimura/lancache-prefill-cron:latest