🚀deploy

Co-authored-by: Amalie Erdal Mansaker <amalie.erdal.mansaker@nav.no>
This commit is contained in:
sindrekjelsrud 2023-06-28 16:17:21 +02:00
parent 6c08b11d37
commit 06c08ce89e
4 changed files with 84 additions and 0 deletions

18
frontend/Dockerfile Normal file
View file

@ -0,0 +1,18 @@
FROM node:18-alpine
ENV NODE_ENV production
RUN addgroup --system --gid 1069 nodejs
RUN adduser --system --uid 1069 nextjs
WORKDIR /app
COPY --chown=nextjs:nodejs .next/standalone ./
COPY --chown=nextjs:nodejs .next/static ./.next/static
USER nextjs
EXPOSE 3000
ENV PORT 3000
CMD ["node", "server.js"]

19
frontend/nais.yml Normal file
View file

@ -0,0 +1,19 @@
apiVersion: "nais.io/v1alpha1"
kind: "Application"
metadata:
name: "helse-sprik"
namespace: "helse-sprik"
spec:
image: {{ image }}
port: 3000
replicas:
min: 1
max: 2
resources:
requests:
cpu: 100m
memory: 128Mi
limits:
memory: 128Mi
ingresses:
- https://helse-sprik.intern.dev.nav.no

View file

@ -1,6 +1,7 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,
output: 'standalone',
}
module.exports = nextConfig