2024-11-15 15:39:26 +00:00
|
|
|
name: Build and push dev image
|
2024-11-13 09:09:20 +00:00
|
|
|
|
|
|
|
on:
|
2024-11-13 10:24:03 +00:00
|
|
|
schedule:
|
2024-11-16 12:44:13 +00:00
|
|
|
- cron: '0 1 * * *'
|
2024-11-14 19:08:07 +00:00
|
|
|
workflow_dispatch:
|
2024-11-13 09:09:20 +00:00
|
|
|
|
2024-11-13 10:02:42 +00:00
|
|
|
env:
|
2024-11-15 15:39:26 +00:00
|
|
|
DOTCLEAR_IMAGE: jcpd/docker-dotclear
|
2024-11-13 10:02:42 +00:00
|
|
|
DOTCLEAR_CANAL: unstable
|
|
|
|
|
2024-11-13 09:09:20 +00:00
|
|
|
jobs:
|
2024-11-16 08:13:02 +00:00
|
|
|
do_image:
|
|
|
|
name: Build dev image and push to Docker hub
|
2024-11-13 09:09:20 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
permissions:
|
|
|
|
packages: write
|
|
|
|
contents: read
|
|
|
|
attestations: write
|
|
|
|
id-token: write
|
|
|
|
steps:
|
|
|
|
- name: Check out the repo
|
|
|
|
uses: actions/checkout@v4
|
|
|
|
|
2024-11-13 10:02:42 +00:00
|
|
|
- name: Set up Docker Buildx
|
|
|
|
uses: docker/setup-buildx-action@v3
|
|
|
|
|
|
|
|
- name: Login to Docker Hub
|
|
|
|
uses: docker/login-action@v3
|
2024-11-13 09:09:20 +00:00
|
|
|
with:
|
|
|
|
username: ${{ secrets.DOCKER_USERNAME }}
|
2024-11-13 10:02:42 +00:00
|
|
|
password: ${{ secrets.DOCKER_TOKEN }}
|
2024-11-13 09:09:20 +00:00
|
|
|
|
2024-11-13 10:02:42 +00:00
|
|
|
- name: Build and push image
|
|
|
|
uses: docker/build-push-action@v6
|
2024-11-13 09:09:20 +00:00
|
|
|
with:
|
2024-11-13 10:02:42 +00:00
|
|
|
context: .
|
|
|
|
sbom: true
|
|
|
|
push: true
|
2024-11-15 15:39:26 +00:00
|
|
|
tags: ${{ env.DOTCLEAR_IMAGE }}:dev
|
2024-11-13 10:09:12 +00:00
|
|
|
build-args: CANAL=${{ env.DOTCLEAR_CANAL }}
|
2024-11-13 10:35:50 +00:00
|
|
|
platforms: linux/386,linux/amd64,linux/arm/V6
|
2024-11-13 12:33:38 +00:00
|
|
|
|
|
|
|
- name: Send Telegram Message Ok
|
|
|
|
uses: appleboy/telegram-action@master
|
|
|
|
env:
|
|
|
|
GITHUB_CONTEXT: ${{toJSON(github)}}
|
|
|
|
with:
|
|
|
|
to: ${{ secrets.TELEGRAM_ID }}
|
|
|
|
token: ${{ secrets.TELEGRAM_TOKEN }}
|
|
|
|
format: markdown
|
2024-11-16 12:38:33 +00:00
|
|
|
message: Image __${{ env.DOTCLEAR_IMAGE }}:dev__ successfully generated.
|