diff --git a/.github/workflows/mr-veileder-flate.yaml b/.github/workflows/mr-veileder-flate.yaml index 4f8fb06f7f..d9cc7bf24b 100644 --- a/.github/workflows/mr-veileder-flate.yaml +++ b/.github/workflows/mr-veileder-flate.yaml @@ -40,16 +40,11 @@ jobs: uses: ./.github/actions/setup-frontend - name: Test run: npx turbo run lint test:ci playwright --filter=mulighetsrommet-veileder-flate - env: - VITE_SANITY_PROJECT_ID: xegcworx - VITE_SANITY_DATASET: test - deploy-dev: + deploy-modia-dev: name: Deploy (dev) runs-on: ubuntu-latest needs: [ci] - permissions: - id-token: "write" # Used to authenticate with Google Cloud if: github.event_name == 'push' && github.ref_name == 'main' || github.event_name == 'workflow_dispatch' steps: - uses: actions/checkout@v4 @@ -57,15 +52,15 @@ jobs: uses: ./.github/actions/setup-frontend - name: Build run: npx turbo run build:modia --filter=mulighetsrommet-veileder-flate - - name: Authenticate to Google Cloud - uses: google-github-actions/auth@v2 + env: + VITE_FARO_URL: https://telemetry.ekstern.dev.nav.no/collect + - name: Upload to NAV CDN + uses: navikt/frontend/actions/cdn-upload/v1@main with: - workload_identity_provider: projects/932652929200/locations/global/workloadIdentityPools/github/providers/github-action - service_account: dev-deploy@team-mulighetsrommet-dev-a2d7.iam.gserviceaccount.com - - name: Set up gcloud - uses: google-github-actions/setup-gcloud@v2 - - name: Upload files to GCS - run: gsutil -m rsync -r /home/runner/work/mulighetsrommet/mulighetsrommet/frontend/mulighetsrommet-veileder-flate/dist gs://mulighetsrommet-veilederflate-dev + cdn-team-name: mulighetsrommet + source: dist + destination: /arbeidsmarkedstiltak-modia-dev/ + no-cache-paths: arbeidsmarkedstiltak-modia-dev/build/asset-manifest.json deploy-demo: name: Deploy (demo) diff --git a/frontend/mulighetsrommet-veileder-flate/package.json b/frontend/mulighetsrommet-veileder-flate/package.json index 1faa2591d9..a0b2c296c5 100644 --- a/frontend/mulighetsrommet-veileder-flate/package.json +++ b/frontend/mulighetsrommet-veileder-flate/package.json @@ -9,7 +9,7 @@ "build": "cross-env VITE_MULIGHETSROMMET_API_BASE='http://localhost:8080' vite build", "serve": "vite preview", "build:demo": "cross-env APP=DEMO VITE_MULIGHETSROMMET_API_MOCK=true vite build", - "build:modia": "cross-env APP=MODIA VITE_MULIGHETSROMMET_API_BASE='/mulighetsrommet-api' VITE_FARO_URL=https://telemetry.nav.no/collect vite build", + "build:modia": "cross-env APP=MODIA VITE_MULIGHETSROMMET_API_BASE='/mulighetsrommet-api' vite build", "build:nav": "cross-env APP=NAV VITE_MULIGHETSROMMET_API_BASE='/mulighetsrommet-api' VITE_FARO_URL=https://telemetry.ekstern.dev.nav.no/collect vite build", "build:preview": "cross-env APP=PREVIEW VITE_MULIGHETSROMMET_API_BASE='/mulighetsrommet-api' VITE_FARO_URL=https://telemetry.ekstern.dev.nav.no/collect vite build", "lint": "eslint src --ext ts,tsx --report-unused-disable-directives --max-warnings 0 && tsc",