From 191768ac8c3ab78560729ccd399a38649c102e92 Mon Sep 17 00:00:00 2001 From: Petar_mc Date: Sat, 2 May 2026 19:49:43 +0000 Subject: [PATCH] add docker support --- .dockerignore | 6 ++++++ Dockerfile | 29 +++++++++++++++++++++++++++++ 2 files changed, 35 insertions(+) create mode 100644 .dockerignore create mode 100644 Dockerfile diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..fdcbf4e --- /dev/null +++ b/.dockerignore @@ -0,0 +1,6 @@ +node_modules/ +web/node_modules/ +web/.svelte-kit/ +web/build/ +.env +.env.* diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..57f8de2 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,29 @@ +# build +FROM oven/bun:1 AS builder +WORKDIR /app + +COPY package.json bunfig.toml bun.lock ./ +COPY web/package.json ./web/ +COPY web-extension/package.json ./web-extension/ + +# install deps +RUN bun install --frozen-lockfile + + +COPY web/ ./web/ + +# build using bun +RUN cd web && NODE_ENV=development bun run build + +# runtime +FROM oven/bun:1-slim AS runner +WORKDIR /app + +COPY --from=builder /app/web/build ./build + +#run app on port 3000 +EXPOSE 3000 +ENV HOST=0.0.0.0 +ENV PORT=3000 + +CMD ["bun", "./build/index.js"]