[skip ci] Update README, add skip ci support for workflow
All checks were successful
Build Docker image / Build image (push) Has been skipped
All checks were successful
Build Docker image / Build image (push) Has been skipped
This commit is contained in:
parent
be780088af
commit
fc24126f69
2 changed files with 12 additions and 2 deletions
|
@ -1,17 +1,23 @@
|
||||||
|
name: Build Docker image
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "0 12 * * *"
|
- cron: "0 12 * * *"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build_image:
|
build_image:
|
||||||
name: Build image
|
name: Build image
|
||||||
|
runs-on: docker
|
||||||
|
if: env.SCHEDULED == 'true' || !contains(github.event.commits[0].message, '[skip ci]')
|
||||||
|
|
||||||
env:
|
env:
|
||||||
VERSION: 22.04
|
VERSION: 22.04
|
||||||
SCHEDULED: ${{ github.event_name == 'schedule' }}
|
SCHEDULED: ${{ github.event_name == 'schedule' }}
|
||||||
PUSHED: ${{ github.event_name == 'push' }}
|
PUSHED: ${{ github.event_name == 'push' }}
|
||||||
REGISTRY: git.korhonen.cc
|
REGISTRY: git.korhonen.cc
|
||||||
REPO: ${{ env.REGISTRY }}/functionalhacker/ubuntu-act
|
REPO: ${{ env.REGISTRY }}/functionalhacker/ubuntu-act
|
||||||
runs-on: docker
|
|
||||||
steps:
|
steps:
|
||||||
- name: Check if update available
|
- name: Check if update available
|
||||||
if: env.SCHEDULED == 'true'
|
if: env.SCHEDULED == 'true'
|
||||||
|
@ -20,12 +26,15 @@ jobs:
|
||||||
with:
|
with:
|
||||||
base-image: docker://ghcr.io/catthehacker/ubuntu:act-${{ env.VERSION }}
|
base-image: docker://ghcr.io/catthehacker/ubuntu:act-${{ env.VERSION }}
|
||||||
derived-image: docker://${{ env.REPO }}:latest
|
derived-image: docker://${{ env.REPO }}:latest
|
||||||
|
|
||||||
- name: Check result
|
- name: Check result
|
||||||
if: env.SCHEDULED == 'true'
|
if: env.SCHEDULED == 'true'
|
||||||
run: echo "Needs updating = ${{ steps.check.outputs.differs }}"
|
run: echo "Needs updating = ${{ steps.check.outputs.differs }}"
|
||||||
|
|
||||||
- name: Set up Docker Buildx
|
- name: Set up Docker Buildx
|
||||||
if: env.PUSHED == 'true' || steps.check.outputs.differs == 'true'
|
if: env.PUSHED == 'true' || steps.check.outputs.differs == 'true'
|
||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
- name: Login to Docker registry
|
- name: Login to Docker registry
|
||||||
if: env.PUSHED == 'true' || steps.check.outputs.differs == 'true'
|
if: env.PUSHED == 'true' || steps.check.outputs.differs == 'true'
|
||||||
uses: docker/login-action@v3
|
uses: docker/login-action@v3
|
||||||
|
@ -33,6 +42,7 @@ jobs:
|
||||||
registry: ${{ env.REGISTRY }}
|
registry: ${{ env.REGISTRY }}
|
||||||
username: ${{ secrets.REGISTRY_USER }}
|
username: ${{ secrets.REGISTRY_USER }}
|
||||||
password: ${{ secrets.REGISTRY_PASSWORD }}
|
password: ${{ secrets.REGISTRY_PASSWORD }}
|
||||||
|
|
||||||
- name: Build and push image
|
- name: Build and push image
|
||||||
if: env.PUSHED == 'true' || steps.check.outputs.differs == 'true'
|
if: env.PUSHED == 'true' || steps.check.outputs.differs == 'true'
|
||||||
uses: docker/build-push-action@v5
|
uses: docker/build-push-action@v5
|
||||||
|
|
|
@ -4,4 +4,4 @@ Based on the link:https://github.com/catthehacker/docker_images[ghcr.io/cattheha
|
||||||
|
|
||||||
* link:https://github.com/containers/skopeo[skopeo]
|
* link:https://github.com/containers/skopeo[skopeo]
|
||||||
|
|
||||||
Image is built at 12:00 EET every day if upstream updates are available.
|
Image is built at 12:00 EET/EEST every day if upstream updates are available.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue