From 1bf15d4ff14c11f8c6da4049048316ae3e3dd519 Mon Sep 17 00:00:00 2001 From: elimoshkovich Date: Wed, 27 Mar 2024 19:24:32 +0200 Subject: [PATCH] check1 --- .github/workflows/pdp_cicd.yml | 29 ++++++++++++++++++++--------- requirements.txt | 3 ++- 2 files changed, 22 insertions(+), 10 deletions(-) diff --git a/.github/workflows/pdp_cicd.yml b/.github/workflows/pdp_cicd.yml index c0ef294e..1ad5a6fe 100644 --- a/.github/workflows/pdp_cicd.yml +++ b/.github/workflows/pdp_cicd.yml @@ -1,7 +1,7 @@ name: Build and Push PDP Docker Image -on: - release: - types: [published] +on: push + # release: + # types: [published] jobs: build-and-push-pdp-vanilla: runs-on: ubuntu-latest @@ -28,7 +28,7 @@ jobs: if: "!github.event.release.prerelease" uses: docker/build-push-action@v5 with: - push: true + push: false context: . platforms: linux/amd64,linux/arm64 tags: permitio/pdp-v2-vanilla:${{ github.event.release.tag_name }}, permitio/pdp-v2-vanilla:latest @@ -39,7 +39,7 @@ jobs: if: "github.event.release.prerelease" uses: docker/build-push-action@v5 with: - push: true + push: false context: . platforms: linux/amd64,linux/arm64 tags: permitio/pdp-v2-vanilla:${{ github.event.release.tag_name }} @@ -83,10 +83,11 @@ jobs: if: "github.event.release.prerelease" uses: docker/build-push-action@v5 with: - push: true + push: false context: . platforms: linux/amd64,linux/arm64 - tags: permitio/pdp-v2:${{ github.event.release.tag_name }} + #tags: permitio/pdp-v2:${{ github.event.release.tag_name }} + tags: permitio/pdp-v2:0.3.0-rc.1 cache-from: type=gha cache-to: type=gha,mode=max @@ -94,9 +95,19 @@ jobs: if: "!github.event.release.prerelease" uses: docker/build-push-action@v5 with: - push: true + push: false context: . platforms: linux/amd64,linux/arm64 - tags: permitio/pdp-v2:${{ github.event.release.tag_name }},permitio/pdp-v2:latest + #tags: permitio/pdp-v2:${{ github.event.release.tag_name }},permitio/pdp-v2:latest + tags: permitio/pdp-v2:0.3.0-rc.1 cache-from: type=gha cache-to: type=gha,mode=max + + - name: Install Docker + uses: docker-practice/actions-setup-docker@master + + - name: local PDP runnning + env: + # PDP_API_KEY: ${{ secrets.PDP_API_KEY }} + # PERMIT_API_KEY: ${{ secrets.PDP_API_KEY }} + run: docker run -p 7766:7000 --env PDP_API_KEY=permit_key_Hqeh8UrI1WpAwQJZGqkROkf5spS9b83Yk0z4YcSidhzEf4TTeE4ldKnIYQsfO7RM6vFml8nMinuVfeLEBn6SU3 --env PDP_DEBUG=true permitio/pdp-v2:0.3.0-rc.1 \ No newline at end of file diff --git a/requirements.txt b/requirements.txt index 5e97727a..7e9835ac 100644 --- a/requirements.txt +++ b/requirements.txt @@ -10,5 +10,6 @@ uvicorn[standard]>=0.17.6,<1 logzio-python-handler ddtrace protobuf>=3.20.2 # not directly required, pinned by Snyk to avoid a vulnerability -opal-client @ git+https://github.com/permitio/opal.git@master +opal-client @ git+https://github.com/permitio/opal.git@master#subdirectory=packages/opal-client +