feat: montly rebuilds of builder

This commit is contained in:
Jared Allard 2025-03-13 15:32:40 -07:00
parent cafb8cf4af
commit 35644eddef
Signed by: jaredallard
SSH key fingerprint: SHA256:wyRyyv28jBYw8Yp/oABNPUYvbGd6hyZj23XVXEm5G/U

40
.github/workflows/rebuild-builder.yml vendored Normal file
View file

@ -0,0 +1,40 @@
name: Rebuild Builder Image
on:
workflow_dispatch: {} # For as needed rebuilds.
schedule:
- cron: "0 0 1 * *"
jobs:
updater-base-image:
runs-on: ubuntu-latest
permissions:
packages: write
contents: read
env:
REGISTRY: git.rgst.io
IMAGE_NAME: ${{ github.repository }}
steps:
- name: Checkout
uses: https://code.forgejo.org/actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ github.token }}
- name: Use Last Commit Date as System Timestamp
run: echo "TIMESTAMP=$(git log -1 --pretty=%ct)" >> $GITHUB_ENV
- name: Build and push image
uses: docker/build-push-action@v6
id: push
env:
SOURCE_DATE_EPOCH: ${{ env.TIMESTAMP }}
with:
context: .
push: true
platforms: linux/amd64
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}-builder