From 8d0ff8f32f8ebd6d77a2966903e12a731c01b036 Mon Sep 17 00:00:00 2001 From: Manuel Ruck Date: Sun, 29 Oct 2023 17:12:11 +0100 Subject: [PATCH] =?UTF-8?q?fix:=20=E2=9C=A8=20use=20pull=20request=20build?= =?UTF-8?q?=20action=20for=20bundestag=20api?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Manuel Ruck --- .../workflows/deploy-bundestag.io-api.yaml | 76 ------------------- bundestag.io/api/package.json | 1 - 2 files changed, 77 deletions(-) delete mode 100644 .github/workflows/deploy-bundestag.io-api.yaml diff --git a/.github/workflows/deploy-bundestag.io-api.yaml b/.github/workflows/deploy-bundestag.io-api.yaml deleted file mode 100644 index fb09c9ee4..000000000 --- a/.github/workflows/deploy-bundestag.io-api.yaml +++ /dev/null @@ -1,76 +0,0 @@ -name: Docker – bundestag.io - -on: - workflow_dispatch: - push: - paths: - - 'bundestag.io/api/**' - branches: - - 'master' - tags: - - 'bundestag.io@v*' - pull_request: - paths: - - 'bundestag.io/api/**' - branches: - - 'master' - -jobs: - push: - runs-on: ubuntu-latest - environment: docker - steps: - - name: Checkout - uses: actions/checkout@v3 - - name: Docker meta - id: meta - uses: docker/metadata-action@v4 - with: - images: democracy/bundestag.io - tags: | - type=ref,event=branch,enable=${{ github.ref == format('refs/heads/{0}', 'master') || github.ref == format('refs/heads/{0}', 'alpha') || github.ref == format('refs/heads/{0}', 'internal') }} - type=ref,event=pr - type=match,asref=foo,pattern=bundestag.io@v(\d+.\d+.\d+)(-alpha.\d+)?,group=1 - type=semver,pattern={{version}},use=foo - type=sha,enable=${{ github.event_name == 'workflow_dispatch' }} - - name: Print Meta Summary - run: | - echo "🏷️ Tags: ${{ steps.meta.outputs.tags }} - " >> $GITHUB_STEP_SUMMARY - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@master - with: - install: true - - name: Cache Docker layers - uses: actions/cache@v3 - with: - path: /tmp/.buildx-cache - key: ${{ runner.os }}-multi-buildx-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-multi-buildx - - name: Login to DockerHub - uses: docker/login-action@v3 - if: github.event_name != 'pull_request' - with: - username: ${{ secrets.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} - - name: Build and push - id: docker_build - uses: docker/build-push-action@v4 - with: - context: bundestag.io/api - file: infra/Dockerfile - platforms: linux/amd64,linux/arm64 - push: ${{ github.event_name != 'pull_request' }} - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - cache-from: type=local,src=/tmp/.buildx-cache - cache-to: type=local,mode=max,dest=/tmp/.buildx-cache-new - - name: Move buildx cache - run: | - rm -rf /tmp/.buildx-cache - mv /tmp/.buildx-cache-new /tmp/.buildx-cache - - name: Image digest - run: echo ${{ steps.docker_build.outputs.digest }} diff --git a/bundestag.io/api/package.json b/bundestag.io/api/package.json index 914bc135b..18862aee1 100644 --- a/bundestag.io/api/package.json +++ b/bundestag.io/api/package.json @@ -8,7 +8,6 @@ "Ulf Gebhardt" ], "license": "Apache2", - "private": true, "scripts": { "build": "tsc", "start": "node build/index.js",