2021-01-16 09:16:05 +00:00
|
|
|
name: "Build Stable on Schedule"
|
|
|
|
|
|
|
|
on:
|
|
|
|
schedule:
|
|
|
|
- cron: "0 0 * * 5"
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
publish:
|
2021-01-16 14:34:31 +00:00
|
|
|
runs-on: ubuntu-20.04
|
2021-01-16 09:16:05 +00:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
with:
|
|
|
|
ref: stable
|
|
|
|
submodules: recursive
|
2021-01-25 12:42:33 +00:00
|
|
|
- name: Prepare tags
|
2021-01-16 09:16:05 +00:00
|
|
|
id: prep
|
2021-01-25 12:42:33 +00:00
|
|
|
uses: crazy-max/ghaction-docker-meta@v1
|
|
|
|
with:
|
|
|
|
images: |
|
|
|
|
${{ secrets.DOCKER_REPOSITORY }}
|
|
|
|
${{ secrets.GHCR_REPOSITORY }}
|
|
|
|
tag-custom: stable
|
|
|
|
tag-custom-only: true
|
2021-01-16 09:16:05 +00:00
|
|
|
- name: Set up QEMU
|
|
|
|
uses: docker/setup-qemu-action@v1
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
uses: docker/setup-buildx-action@v1
|
|
|
|
id: buildx
|
|
|
|
- name: Login to DockerHub
|
|
|
|
uses: docker/login-action@v1
|
|
|
|
with:
|
|
|
|
username: ${{ secrets.DOCKER_USERNAME }}
|
|
|
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
2021-01-25 12:42:33 +00:00
|
|
|
- name: Login to GitHub Container Registry
|
|
|
|
uses: docker/login-action@v1
|
|
|
|
with:
|
|
|
|
registry: ghcr.io
|
|
|
|
username: ${{ secrets.GHCR_USERNAME }}
|
|
|
|
password: ${{ secrets.GHCR_PASSWORD }}
|
2021-01-16 09:16:05 +00:00
|
|
|
- name: Build image locally
|
|
|
|
uses: docker/build-push-action@v2
|
|
|
|
with:
|
|
|
|
builder: ${{ steps.buildx.outputs.name }}
|
|
|
|
context: .
|
|
|
|
file: ./Dockerfile
|
|
|
|
build-args: |
|
|
|
|
VCS_REF=${{ github.sha }}
|
|
|
|
VCS_VER=${{ github.ref }}
|
|
|
|
platforms: linux/amd64,linux/arm/v7,linux/arm64
|
|
|
|
push: true
|
|
|
|
tags: ${{ steps.prep.outputs.tags }}
|