Skip to content

Commit b539d15

Browse files
committed
wip
1 parent e7ab528 commit b539d15

38 files changed

+2830
-1240
lines changed

.env

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
NEXT_PUBLIC_BASE_PATH="/syk/kartleggingssporsmal"
2+
3+
MEROPPFOLGING_BACKEND_URL="dummy-value"
4+
TOKEN_X_WELL_KNOWN_URL="dummy-value"
5+
TOKEN_X_CLIENT_ID="dummy-value"
6+
TOKEN_X_PRIVATE_JWK="dummy-value"
7+
IDPORTEN_WELL_KNOWN_URL="dummy-value"
8+
IDPORTEN_CLIENT_ID="dummy-value"
9+
NAIS_CLUSTER_NAME="dummy-value"

.env.development.local

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
NEXT_PUBLIC_RUNTIME_ENVIRONMENT=local

.github/dependabot.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
version: 2
2+
3+
registries:
4+
npm-github:
5+
type: npm-registry
6+
url: https://npm.pkg.github.com
7+
token: ${{ secrets.READER_TOKEN }}
8+
9+
updates:
10+
- package-ecosystem: github-actions
11+
directory: '/'
12+
schedule:
13+
interval: daily
14+
15+
- package-ecosystem: npm
16+
directory: '/'
17+
schedule:
18+
interval: daily
19+
time: '14:30'
20+
timezone: Europe/Oslo
21+
open-pull-requests-limit: 20
22+
registries: '*'
23+
reviewers:
24+
- ''
25+
groups:
26+
aksel-dependencies:
27+
patterns:
28+
- '@navikt/aksel*'
29+
- '@navikt/ds*'
30+
react-dependencies:
31+
patterns:
32+
- 'react'
33+
- 'react-dom'
34+
- '@types/react'
35+
- '@types/react-dom'
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
name: Build & Deploy
2+
on:
3+
push:
4+
workflow_dispatch:
5+
6+
jobs:
7+
next-app:
8+
uses: navikt/teamesyfo-github-actions-workflows/.github/workflows/next-app.yaml@main
9+
permissions:
10+
contents: read
11+
id-token: write
12+
packages: write
13+
secrets: inherit
14+
with:
15+
app: bro-frontend
16+
base-path: /syk/kartleggingssporsmal
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
name: label-dependabot-pr
2+
on:
3+
pull_request:
4+
types: [ opened, unlabeled ]
5+
6+
jobs:
7+
label-dependabot-pr:
8+
uses: navikt/teamesyfo-github-actions-workflows/.github/workflows/label-dependabot-pr.yaml@main
9+
permissions:
10+
pull-requests: write
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: merge-dependabot-pr
2+
on:
3+
workflow_dispatch:
4+
schedule:
5+
- cron: '0,15,30,45 7-14 * * 1,2,3,4,5'
6+
7+
jobs:
8+
merge-dependabot-pr:
9+
uses: navikt/teamesyfo-github-actions-workflows/.github/workflows/merge-dependabot-pr.yaml@main
10+
permissions:
11+
actions: write
12+
checks: read
13+
contents: write
14+
pull-requests: write
15+
statuses: read

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,6 @@ yarn-debug.log*
3232
yarn-error.log*
3333
.pnpm-debug.log*
3434

35-
# env files (can opt-in for committing if needed)
36-
.env*
37-
3835
# vercel
3936
.vercel
4037

Dockerfile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
FROM gcr.io/distroless/nodejs22-debian12 as runtime
2+
3+
WORKDIR /app
4+
5+
COPY package.json /app/
6+
COPY .next/standalone /app/
7+
COPY public /app/public/
8+
9+
EXPOSE 3000
10+
11+
ENV NODE_ENV=production
12+
13+
CMD ["server.js"]

nais/envs/.env.dev

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
NEXT_PUBLIC_RUNTIME_ENVIRONMENT=dev
2+
NEXT_PUBLIC_TELEMETRY_URL=https://telemetry.ekstern.dev.nav.no/collect
3+
NEXT_PUBLIC_ASSET_PREFIX=https://cdn.nav.no/team-esyfo/bro-frontend
4+
NEXT_PUBLIC_BASE_PATH="/syk/kartleggingssporsmal"

nais/nais-dev.yaml

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
apiVersion: 'nais.io/v1alpha1'
2+
kind: 'Application'
3+
metadata:
4+
name: bro-frontend
5+
namespace: team-esyfo
6+
labels:
7+
team: team-esyfo
8+
spec:
9+
image: {{image}}
10+
replicas:
11+
min: 2
12+
max: 4
13+
cpuThresholdPercentage: 90
14+
port: 3000
15+
tokenx:
16+
enabled: true
17+
idporten:
18+
enabled: true
19+
sidecar:
20+
enabled: true
21+
autoLogin: true
22+
level: Level4
23+
autoLoginIgnorePaths:
24+
- /syk/kartleggingssporsmal/api/internal/isAlive
25+
- /syk/kartleggingssporsmal/api/internal/isReady
26+
liveness:
27+
path: /syk/kartleggingssporsmal/api/internal/isAlive
28+
initialDelay: 20
29+
timeout: 5
30+
periodSeconds: 5
31+
failureThreshold: 30
32+
readiness:
33+
path: /syk/kartleggingssporsmal/api/internal/isReady
34+
initialDelay: 20
35+
periodSeconds: 5
36+
timeout: 5
37+
prometheus:
38+
enabled: true
39+
path: actuator/metrics
40+
observability:
41+
logging:
42+
destinations:
43+
- id: elastic
44+
- id: loki
45+
autoInstrumentation:
46+
enabled: true
47+
runtime: nodejs
48+
resources:
49+
limits:
50+
cpu: 500m
51+
memory: 512Mi
52+
requests:
53+
cpu: 200m
54+
memory: 256Mi
55+
ingresses:
56+
- 'https://www.ekstern.dev.nav.no/syk/kartleggingssporsmal'
57+
env:
58+
- name: MEROPPFOLGING_BACKEND_URL
59+
value: http://meroppfolging-backend
60+
accessPolicy:
61+
outbound:
62+
rules:
63+
- application: nav-dekoratoren
64+
namespace: personbruker
65+
- application: meroppfolging-backend

0 commit comments

Comments
 (0)