diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..f965aed --- /dev/null +++ b/.dockerignore @@ -0,0 +1,15 @@ +node_modules +Dockerfile* +docker-compose* +.dockerignore +.git +.gitignore +README.md +LICENSE +.vscode +Makefile +helm-charts +.env +.editorconfig +.idea +coverage* diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..9220be8 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM oven/bun:1 as builder +WORKDIR /builder + +COPY package.json bun.lockb /app +RUN bun install --frozen-lockfile +COPY . . + +RUN bun run build + +FROM oven/bun:1 +WORKDIR /app +COPY --from=builder /builder/.output . + +USER bun +ARG APP_PORT=3000 +EXPOSE $APP_PORT +ENTRYPOINT [ "bun" "run" ".output/server/index.mjs" ]