Skip to content

Commit

Permalink
Add mainnet deployment with self-hosted runner
Browse files Browse the repository at this point in the history
  • Loading branch information
mesudip committed Nov 22, 2024
1 parent 5e7dbe3 commit 1e12d32
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
jobs:
deploy:
name: Deploy app
runs-on: ubuntu-latest
runs-on: self-hosted
steps:
- name: Set up SSH and deploy
uses: appleboy/[email protected]
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test_integration_playwright.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ on:

jobs:
integration-tests:
runs-on: ubuntu-latest
runs-on: self-hosted
defaults:
run:
working-directory: integration_test
Expand Down Expand Up @@ -63,7 +63,7 @@ jobs:
path: integration_test/allure-results

publish-report:
runs-on: ubuntu-latest
runs-on: self-hosted
if: always()
needs: integration-tests
steps:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test_vitest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ on:

jobs:
unit-tests:
runs-on: ubuntu-latest
runs-on: self-hosted
defaults:
run:
working-directory: .
Expand Down Expand Up @@ -48,7 +48,7 @@ jobs:
path: allure-results

publish-report:
runs-on: ubuntu-latest
runs-on: self-hosted
if: always()
needs: unit-tests
steps:
Expand Down
21 changes: 21 additions & 0 deletions deployment/docker-compose-ccva.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,27 @@ services:
- node.labels.ccva==true
restart_policy:
delay: 15s
webapp-mainnet:
image: ${REGISTRY_BASE}/webapp:${IMAGE_VERSION_TAG}
build:
context: ../
args:
- NPM_AUTH_TOKEN=${NPM_AUTH_TOKEN}
- NEXT_PUBLIC_NETWORK=mainnet
networks:
- postgres
- frontend
environment:
NEXTAUTH_SECRET: ${NEXT_AUTH_SECRET}
VIRTUAL_HOST: https://mainnet-${DEPLOY_BASE_DOMAIN}
DATABASE_URL: postgresql://ccva:${DATABASE_PASSWORD}@postgres:5432/ccva_mainnet
NEXTAUTH_URL: https://mainnet-${DEPLOY_BASE_DOMAIN}
deploy:
placement:
constraints:
- node.labels.ccva==true
restart_policy:
delay: 15s
networks:
frontend:
name: frontend
Expand Down

0 comments on commit 1e12d32

Please sign in to comment.