2024-07-23 18:17:00 +00:00
|
|
|
---
|
2024-04-09 20:10:09 +00:00
|
|
|
name: Container Publish
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2024-07-25 06:26:46 +00:00
|
|
|
# tags:
|
|
|
|
# - 'live'
|
2024-04-09 20:10:09 +00:00
|
|
|
schedule:
|
|
|
|
- cron: "0 12 * * *"
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build-image:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
container:
|
|
|
|
image: catthehacker/ubuntu:act-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
with:
|
|
|
|
submodules: true # Fetch Hugo themes (true OR recursive)
|
|
|
|
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
|
|
|
|
|
2024-07-25 06:26:46 +00:00
|
|
|
- uses: actions/cache@v3
|
|
|
|
with:
|
|
|
|
path: .resources/
|
|
|
|
key: bglug-it-hugo-resources
|
|
|
|
|
2024-04-09 20:10:09 +00:00
|
|
|
- name: Set up QEMU
|
|
|
|
uses: docker/setup-qemu-action@v3
|
|
|
|
|
|
|
|
- name: Set up Docker BuildX
|
|
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
|
2024-07-25 06:26:46 +00:00
|
|
|
# - name: Login to registry
|
|
|
|
# uses: docker/login-action@v3
|
|
|
|
# with:
|
|
|
|
# registry: git.libreschool.org
|
|
|
|
# username: ${{ secrets.REGISTRY_USER }}
|
|
|
|
# password: ${{ secrets.REGISTRY_TOKEN }}
|
2024-04-09 20:10:09 +00:00
|
|
|
|
|
|
|
- name: Build and publish
|
2024-06-03 20:03:26 +00:00
|
|
|
uses: docker/build-push-action@v5
|
2024-04-09 20:10:09 +00:00
|
|
|
with:
|
|
|
|
context: .
|
|
|
|
file: ./Dockerfile
|
2024-06-03 20:03:26 +00:00
|
|
|
platforms: linux/amd64
|
2024-07-25 06:26:46 +00:00
|
|
|
push: false
|
|
|
|
tags: git.libreschool.org/paspo/bglug.it:latest
|
2024-05-15 21:00:47 +00:00
|
|
|
|
|
|
|
- name: send mattermost notification
|
|
|
|
uses: mattermost/action-mattermost-notify@master
|
|
|
|
with:
|
|
|
|
MATTERMOST_WEBHOOK_URL: ${{ secrets.MM_WEBHOOK_URL }}
|
|
|
|
TEXT: |
|
2024-07-25 06:26:46 +00:00
|
|
|
:white_check_mark: `${{ github.repository }}` A new container image has been pushed to `git.libreschool.org/paspo/bglug.it:latest`
|
2024-05-15 21:00:47 +00:00
|
|
|
MATTERMOST_ICON: https://cdn3.iconfinder.com/data/icons/system-basic-vol-4-1/20/icon-note-attention-alt3-512.png
|