aboutsummaryrefslogtreecommitdiff
path: root/Dockerfile
diff options
context:
space:
mode:
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile28
1 files changed, 28 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 00000000..a82993fe
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,28 @@
+FROM oven/bun:1.0.15 as build
+
+WORKDIR /due
+
+RUN apt update -y
+RUN apt upgrade -y
+RUN apt install sqlite3 -y
+
+COPY package.json ./
+
+RUN bun install
+
+COPY ./ ./
+
+RUN mkdir data
+RUN sqlite3 data/due_moe.sqlite3 < due_moe_schema.sql
+RUN bun --bun vite build
+
+FROM oven/bun:1.0.15
+
+WORKDIR /due
+
+COPY --from=build /due/build ./build
+COPY --from=build /due/data ./data
+
+EXPOSE 3000
+
+CMD ["bun", "./build/index.js"] \ No newline at end of file