diff --git a/.github/workflows/dev-push.yml b/.github/workflows/dev-push.yml index 2d3c6bb..ce4c79f 100644 --- a/.github/workflows/dev-push.yml +++ b/.github/workflows/dev-push.yml @@ -106,5 +106,6 @@ jobs: EMAIL_SMTP_USER: ${{ secrets.EMAIL_SMTP_USER }} EMAIL_SMTP_PASSWORD: ${{ secrets.EMAIL_SMTP_PASSWORD }} EMAIL_SMTP_SERVER: ${{ secrets.EMAIL_SMTP_SERVER }} + VITE_BASE_URL: ${{ secrets.VITE_BASE_URL }} TEST: "true" run: docker-compose -f docker-compose-dev.yml -p dm-nms up -d diff --git a/.github/workflows/prod-build.yml b/.github/workflows/prod-build.yml index 3339e83..7b6136b 100644 --- a/.github/workflows/prod-build.yml +++ b/.github/workflows/prod-build.yml @@ -29,7 +29,9 @@ jobs: run: npm install - name: Buildear client working-directory: ./client - run: npm run build + run: npm run build + env: + VITE_API_KEY: ${{ secrets.VITE_API_KEY }} build-admin: @@ -45,23 +47,13 @@ jobs: - name: Buildear admin working-directory: ./admin run: npm run build + - deploy-client: - runs-on: potus - needs: build-client - steps: - - uses: FirebaseExtended/action-hosting-deploy@v0 - with: - firebaseServiceAccount: "${{ secrets.FIREBASE_SERVICE_ACCOUNT }}" - projectId: nms-devmaster - channelId: live - target: web-client - - deploy-admin: + deploy-front: runs-on: potus - needs: build-admin + needs: [build-admin, build-client] steps: - uses: lowply/deploy-firebase@v0.0.5 env: @@ -105,5 +97,7 @@ jobs: EMAIL_SMTP_USER: ${{ secrets.EMAIL_SMTP_USER }} EMAIL_SMTP_PASSWORD: ${{ secrets.EMAIL_SMTP_PASSWORD }} EMAIL_SMTP_SERVER: ${{ secrets.EMAIL_SMTP_SERVER }} + VITE_BASE_URL: ${{ secrets.VITE_BASE_URL }} TEST: "true" - run: docker-compose -f docker-compose-prod.yml -p dm-nms up -d \ No newline at end of file + run: docker-compose -f docker-compose-prod.yml -p dm-nms up -d + diff --git a/docker-compose-dev.yml b/docker-compose-dev.yml index cbdd6a0..afce4a5 100644 --- a/docker-compose-dev.yml +++ b/docker-compose-dev.yml @@ -26,6 +26,8 @@ services: restart: unless-stopped ports: - "5173:5173" + environment: + - VITE_BASE_URL=${VITE_BASE_URL} networks: default: