aboutsummaryrefslogtreecommitdiff
path: root/Dockerfile
diff options
context:
space:
mode:
authorFuwn <[email protected]>2023-10-26 15:38:35 -0700
committerFuwn <[email protected]>2023-10-26 15:38:35 -0700
commit6f0a6e3020dbc186962babac8566d62dc0c4d9c3 (patch)
tree4273c0ebe5567109daf8b7a4d2c92d51694677cf /Dockerfile
parentrefactor(badges): move to bun:sqlite (diff)
downloaddue.moe-badges.tar.xz
due.moe-badges.zip
feat: move back to bunbadges
Diffstat (limited to 'Dockerfile')
-rw-r--r--Dockerfile16
1 files changed, 11 insertions, 5 deletions
diff --git a/Dockerfile b/Dockerfile
index 94719c00..f2a433e2 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,18 +1,24 @@
-FROM node:19-bullseye as build
+FROM oven/bun:1.0.1 as build
WORKDIR /due
RUN apt update -y && apt upgrade -y
+RUN apt install sqlite3 -y
+
COPY package.json ./
-RUN yarn install
+RUN bun install
COPY ./ ./
-RUN yarn run build
+RUN mkdir data
+
+RUN sqlite3 data/due_moe.sqlite3 < due_moe_schema.sql
+
+RUN bun --bun vite build
-FROM node:19-bullseye
+FROM oven/bun:1.0.1
WORKDIR /due
@@ -20,4 +26,4 @@ COPY --from=build /due .
EXPOSE 3000
-CMD ["node", "build"] \ No newline at end of file
+CMD ["bun", "./build/index.js"] \ No newline at end of file