Build & Push container to GH registry #22
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: 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 |