From d336161f8b1f8c5ab9d838d3e10dfd666533d307 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 23 Aug 2024 18:55:17 +0000 Subject: [PATCH 1/3] ci: publish cloud image --- .github/workflows/publish.yml | 38 ++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 4d6fc18dd..bd120a981 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -5,7 +5,43 @@ on: types: [published] jobs: - publish: + publish-cloud: + runs-on: ubuntu-latest + steps: + - name: Checkout the repo + uses: actions/checkout@v2 + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + - name: Log in to Docker Hub + uses: docker/login-action@v3 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v5 + with: + images: appwrite/console-cloud + tags: | + type=semver,pattern={{major}}.{{minor}}.{{patch}} + type=semver,pattern={{major}}.{{minor}} + type=semver,pattern={{major}} + - name: Build and push Docker image + id: push + uses: docker/build-push-action@v6 + with: + context: . + push: true + platforms: linux/amd64,linux/arm64 + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + build-args: | + "PUBLIC_CONSOLE_MODE=cloud" + "PUBLIC_GROWTH_ENDPOINT=${{ secrets.PUBLIC_GROWTH_ENDPOINT }}" + "PUBLIC_STRIPE_KEY=${{ secrets.PUBLIC_GROWTH_ENDPOINT }}" + publish-self-hosted: runs-on: ubuntu-latest steps: - name: Checkout the repo From 9c8489d33f10d03748b87b2029da6a4c245b65b3 Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 23 Aug 2024 18:58:53 +0000 Subject: [PATCH 2/3] ci: fix stripe key env varaible --- .github/workflows/publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index bd120a981..3714dd202 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -40,7 +40,7 @@ jobs: build-args: | "PUBLIC_CONSOLE_MODE=cloud" "PUBLIC_GROWTH_ENDPOINT=${{ secrets.PUBLIC_GROWTH_ENDPOINT }}" - "PUBLIC_STRIPE_KEY=${{ secrets.PUBLIC_GROWTH_ENDPOINT }}" + "PUBLIC_STRIPE_KEY=${{ secrets.PUBLIC_STRIPE_KEY }}" publish-self-hosted: runs-on: ubuntu-latest steps: From 1067dff3f503e11bb28a11d622ac9b0cfe5a1a3e Mon Sep 17 00:00:00 2001 From: Torsten Dittmann Date: Fri, 23 Aug 2024 19:05:17 +0000 Subject: [PATCH 3/3] fix: growth endpoint env variable --- Dockerfile | 4 ++-- compose.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index e3377ac44..221460c05 100644 --- a/Dockerfile +++ b/Dockerfile @@ -20,11 +20,11 @@ ADD ./static /app/static ARG PUBLIC_CONSOLE_MODE ARG PUBLIC_APPWRITE_ENDPOINT -ARG PUBLIC_APPWRITE_GROWTH_ENDPOINT +ARG PUBLIC_GROWTH_ENDPOINT ARG PUBLIC_STRIPE_KEY ENV PUBLIC_APPWRITE_ENDPOINT=$PUBLIC_APPWRITE_ENDPOINT -ENV PUBLIC_APPWRITE_GROWTH_ENDPOINT=$PUBLIC_APPWRITE_GROWTH_ENDPOINT +ENV PUBLIC_GROWTH_ENDPOINT=$PUBLIC_GROWTH_ENDPOINT ENV PUBLIC_CONSOLE_MODE=$PUBLIC_CONSOLE_MODE ENV PUBLIC_STRIPE_KEY=$PUBLIC_STRIPE_KEY diff --git a/compose.yml b/compose.yml index 3ff3e995b..6d26917d5 100644 --- a/compose.yml +++ b/compose.yml @@ -6,7 +6,7 @@ services: args: PUBLIC_CONSOLE_MODE: ${PUBLIC_CONSOLE_MODE} PUBLIC_APPWRITE_ENDPOINT: ${PUBLIC_APPWRITE_ENDPOINT} - PUBLIC_APPWRITE_GROWTH_ENDPOINT: ${PUBLIC_GROWTH_ENDPOINT} + PUBLIC_GROWTH_ENDPOINT: ${PUBLIC_GROWTH_ENDPOINT} PUBLIC_STRIPE_KEY: ${PUBLIC_STRIPE_KEY} develop: watch: