From 9a0d1670890923cdfc32b659ec2a1e6d77d465db Mon Sep 17 00:00:00 2001 From: Gregor Middell Date: Mon, 3 Feb 2025 11:08:24 +0100 Subject: [PATCH] feat(Project): CI/CD based on GitHub-Actions Release-As: 1.0.0 --- .github/workflows/ci.yml | 42 ++++++++++++++++++++++++++++ .github/workflows/release-please.yml | 17 +++++++++++ 2 files changed, 59 insertions(+) create mode 100644 .github/workflows/ci.yml create mode 100644 .github/workflows/release-please.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..d4963be --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,42 @@ +name: ci + +on: + workflow_dispatch: + push: + branches: + - 'main' + tags: + - 'v*' + pull_request: + branches: + - 'main' + +jobs: + docker: + runs-on: ubuntu-latest + steps: + - + name: Checkout + uses: actions/checkout@v4 + - + name: Docker meta + id: meta + uses: docker/metadata-action@v5 + with: + images: docker.zdl.org/ddc-fcs + - + name: Login to DockerHub + if: github.event_name != 'pull_request' + uses: docker/login-action@v3 + with: + registry: docker.zdl.org + username: ${{ secrets.ZDL_DOCKER_USERNAME }} + password: ${{ secrets.ZDL_DOCKER_TOKEN }} + - + name: Build and push + uses: docker/build-push-action@v5 + with: + context: . + push: ${{ github.event_name != 'pull_request' }} + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.yml new file mode 100644 index 0000000..0f78367 --- /dev/null +++ b/.github/workflows/release-please.yml @@ -0,0 +1,17 @@ +on: + push: + +permissions: + contents: write + pull-requests: write + +name: Release Please + +jobs: + release-please: + runs-on: ubuntu-latest + steps: + - uses: googleapis/release-please-action@v4 + with: + token: ${{ secrets.RP_TOKEN }} + release-type: simple