Compare commits
26
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8930852d1a | ||
|
|
558915d250 | ||
|
|
3ab51ef70b | ||
|
|
72a48de836 | ||
|
|
5dd9bc1c68 | ||
|
|
b36af795ab | ||
|
|
83c9787057 | ||
|
|
e2c8f61cfd | ||
|
|
a0ba2f1994 | ||
|
|
7b9a0c520a | ||
|
|
b6cd230388 | ||
|
|
0fef6088da | ||
|
|
0ae94bd37b | ||
|
|
b41477836b | ||
|
|
20820cc417 | ||
|
|
f307593c7b | ||
|
|
b275093fcb | ||
|
|
7b94d6506c | ||
|
|
64be03fdae | ||
|
|
7db0be29cf | ||
|
|
56b261e761 | ||
|
|
a205f24615 | ||
|
|
567ba2a323 | ||
|
|
1bacb8d62c | ||
|
|
1a1768059e | ||
|
|
295b979400 |
+30
-41
@@ -1,60 +1,49 @@
|
|||||||
name: Nightly Rebuild
|
name: Nightly Rebuild
|
||||||
|
|
||||||
on:
|
on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 0 * * *'
|
- cron: '0 0 * * *'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
hadolint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
|
||||||
- name: Build image
|
continue-on-error: true
|
||||||
run: docker build -t ci-image:${{ github.sha }} .
|
|
||||||
- name: Save image
|
|
||||||
run: docker save ci-image:${{ github.sha }} > image.tar
|
|
||||||
- name: Upload artifact
|
|
||||||
uses: ChristopherHX/gitea-upload-artifact@62ac910c5d3dfa85c7cb2df15afe2e342b2407c2 # main
|
|
||||||
with:
|
with:
|
||||||
name: docker-image
|
dockerfile: Dockerfile
|
||||||
path: image.tar
|
|
||||||
|
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: build
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
- name: Download artifact
|
- run: docker build -t ci-image:${{ github.sha }} .
|
||||||
uses: ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
|
- run: bash tests/test.sh ci-image:${{ github.sha }}
|
||||||
with:
|
build-push:
|
||||||
name: docker-image
|
needs: [test]
|
||||||
- name: Load image
|
|
||||||
run: docker load < image.tar
|
|
||||||
- name: Run tests
|
|
||||||
run: bash tests/test.sh ci-image:${{ github.sha }}
|
|
||||||
|
|
||||||
push:
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: test
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- name: Download artifact
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
uses: ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
|
- uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4
|
||||||
with:
|
|
||||||
name: docker-image
|
|
||||||
- name: Load image
|
|
||||||
run: docker load < image.tar
|
|
||||||
- name: Login to Docker Hub
|
|
||||||
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3
|
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
- name: Tag and push latest
|
- id: get-latest-tag
|
||||||
run: |
|
run: |
|
||||||
docker tag ci-image:${{ github.sha }} jcabillot/crond:latest
|
TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo "")
|
||||||
docker push jcabillot/crond:latest
|
echo "tag=$TAG" >> $GITHUB_OUTPUT
|
||||||
|
- id: meta
|
||||||
|
uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6
|
||||||
|
with:
|
||||||
|
images: jcabillot/crond
|
||||||
|
tags: |
|
||||||
|
type=raw,value=${{ steps.get-latest-tag.outputs.tag }}-latest,enable=${{ steps.get-latest-tag.outputs.tag != '' }}
|
||||||
|
- uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7.3.0
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
push: true
|
||||||
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
pull: true
|
||||||
|
|||||||
+23
-59
@@ -1,79 +1,43 @@
|
|||||||
name: Main Branch
|
name: Main Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches: [master]
|
branches: [master]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
lint:
|
hadolint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
|
||||||
- name: Hadolint
|
|
||||||
uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
|
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
|
|
||||||
build:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: lint
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
|
||||||
- name: Build image
|
|
||||||
run: docker build -t ci-image:${{ github.sha }} .
|
|
||||||
- name: Save image
|
|
||||||
run: docker save ci-image:${{ github.sha }} > image.tar
|
|
||||||
- name: Upload artifact
|
|
||||||
uses: ChristopherHX/gitea-upload-artifact@62ac910c5d3dfa85c7cb2df15afe2e342b2407c2 # main
|
|
||||||
with:
|
with:
|
||||||
name: docker-image
|
dockerfile: Dockerfile
|
||||||
path: image.tar
|
|
||||||
|
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: build
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
- name: Download artifact
|
- run: docker build -t ci-image:${{ github.sha }} .
|
||||||
uses: ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
|
- run: bash tests/test.sh ci-image:${{ github.sha }}
|
||||||
with:
|
build:
|
||||||
name: docker-image
|
needs: [test]
|
||||||
- name: Load image
|
|
||||||
run: docker load < image.tar
|
|
||||||
- name: Run tests
|
|
||||||
run: bash tests/test.sh ci-image:${{ github.sha }}
|
|
||||||
|
|
||||||
push:
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: test
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
|
- run: docker build -t jcabillot/crond:${{ github.sha }} .
|
||||||
|
tag:
|
||||||
|
needs: [build]
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- name: Download artifact
|
- name: Configure git auth
|
||||||
uses: ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
|
|
||||||
with:
|
|
||||||
name: docker-image
|
|
||||||
- name: Load image
|
|
||||||
run: docker load < image.tar
|
|
||||||
- name: Login to Docker Hub
|
|
||||||
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3
|
|
||||||
with:
|
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
||||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
||||||
- name: Tag and push latest
|
|
||||||
run: |
|
run: |
|
||||||
docker tag ci-image:${{ github.sha }} jcabillot/crond:latest
|
git remote set-url origin "https://x-access-token:${{ secrets.SA_TOKEN_ACTION_PUSH_TAGS }}@scm.cabillot.eu/perso/crond.git"
|
||||||
docker push jcabillot/crond:latest
|
- uses: anothrNick/github-tag-action@4ed44965e0db8dab2b466a16da04aec3cc312fd8 # v1.75.0
|
||||||
- name: Bump version and push tag
|
|
||||||
if: github.event_name == 'push'
|
|
||||||
uses: anothrNick/github-tag-action@4ed44965e0db8dab2b466a16da04aec3cc312fd8 # v1
|
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.SA_TOKEN_ACTION_PUSH_TAGS }}
|
||||||
DEFAULT_BUMP: patch
|
DEFAULT_BUMP: patch
|
||||||
RELEASE_BRANCHES: master
|
RELEASE_BRANCHES: master
|
||||||
WITH_V: true
|
WITH_V: true
|
||||||
|
|||||||
+11
-25
@@ -1,34 +1,20 @@
|
|||||||
name: PR Checks
|
name: PR Checks
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
|
branches: [master]
|
||||||
jobs:
|
jobs:
|
||||||
lint:
|
hadolint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
|
||||||
- name: Hadolint
|
|
||||||
uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
|
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
|
with:
|
||||||
build:
|
dockerfile: Dockerfile
|
||||||
|
build-test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: lint
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
- name: Build image
|
- run: docker build -t ci-image:${{ github.sha }} .
|
||||||
run: docker build -t ci-image:${{ github.sha }} .
|
- run: bash tests/test.sh ci-image:${{ github.sha }}
|
||||||
|
|
||||||
test:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: build
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
|
||||||
- name: Build image
|
|
||||||
run: docker build -t ci-image:${{ github.sha }} .
|
|
||||||
- name: Run tests
|
|
||||||
run: bash tests/test.sh ci-image:${{ github.sha }}
|
|
||||||
|
|||||||
+29
-50
@@ -1,65 +1,44 @@
|
|||||||
name: Tag Release
|
name: Tag Release
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
tags:
|
tags: ['*']
|
||||||
- 'v*'
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
hadolint:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
|
||||||
- name: Build image
|
continue-on-error: true
|
||||||
run: docker build -t ci-image:${{ github.sha }} .
|
|
||||||
- name: Save image
|
|
||||||
run: docker save ci-image:${{ github.sha }} > image.tar
|
|
||||||
- name: Upload artifact
|
|
||||||
uses: ChristopherHX/gitea-upload-artifact@62ac910c5d3dfa85c7cb2df15afe2e342b2407c2 # main
|
|
||||||
with:
|
with:
|
||||||
name: docker-image
|
dockerfile: Dockerfile
|
||||||
path: image.tar
|
|
||||||
|
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: build
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
- name: Download artifact
|
- run: docker build -t ci-image:${{ github.sha }} .
|
||||||
uses: ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
|
- run: bash tests/test.sh ci-image:${{ github.sha }}
|
||||||
with:
|
build-push:
|
||||||
name: docker-image
|
needs: [test]
|
||||||
- name: Load image
|
|
||||||
run: docker load < image.tar
|
|
||||||
- name: Run tests
|
|
||||||
run: bash tests/test.sh ci-image:${{ github.sha }}
|
|
||||||
|
|
||||||
push:
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
needs: test
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
||||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
|
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
|
||||||
with:
|
- uses: docker/login-action@af1e73f918a031802d376d3c8bbc3fe56130a9b0 # v4
|
||||||
fetch-depth: 0
|
|
||||||
- name: Download artifact
|
|
||||||
uses: ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
|
|
||||||
with:
|
|
||||||
name: docker-image
|
|
||||||
- name: Load image
|
|
||||||
run: docker load < image.tar
|
|
||||||
- name: Login to Docker Hub
|
|
||||||
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 # v3
|
|
||||||
with:
|
with:
|
||||||
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
||||||
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
||||||
- name: Extract tag name
|
- id: meta
|
||||||
run: echo "TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
|
uses: docker/metadata-action@dc802804100637a589fabce1cb79ff13a1411302 # v6
|
||||||
- name: Tag and push with version
|
with:
|
||||||
run: |
|
images: jcabillot/crond
|
||||||
docker tag ci-image:${{ github.sha }} jcabillot/crond:${{ env.TAG }}
|
tags: |
|
||||||
docker tag ci-image:${{ github.sha }} jcabillot/crond:latest
|
type=ref,event=tag
|
||||||
docker push jcabillot/crond:${{ env.TAG }}
|
type=ref,event=tag,suffix=-latest
|
||||||
docker push jcabillot/crond:latest
|
- uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7.3.0
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
push: true
|
||||||
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
pull: true
|
||||||
|
|||||||
Reference in New Issue
Block a user