Spaces:
Running
Running
Commit
•
5183689
1
Parent(s):
fdab00f
finally figured out the dockerfile :)
Browse files- Dockerfile +15 -7
- bun.lockb +0 -0
- package.json +1 -0
- svelte.config.js +1 -1
Dockerfile
CHANGED
@@ -1,15 +1,23 @@
|
|
1 |
-
FROM oven/bun:1
|
2 |
|
3 |
WORKDIR /app
|
4 |
|
5 |
-
COPY
|
|
|
|
|
6 |
|
7 |
-
|
8 |
|
9 |
-
|
10 |
|
11 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
|
13 |
-
EXPOSE
|
14 |
|
15 |
-
CMD ["bun", "
|
|
|
1 |
+
FROM oven/bun:1 AS build
|
2 |
|
3 |
WORKDIR /app
|
4 |
|
5 |
+
COPY . .
|
6 |
+
RUN bun install
|
7 |
+
RUN bun run build
|
8 |
|
9 |
+
FROM oven/bun:1-slim AS run
|
10 |
|
11 |
+
WORKDIR /app
|
12 |
|
13 |
+
COPY --from=build /app/package.json .
|
14 |
+
COPY --from=build /app/bun.lockb .
|
15 |
+
COPY --from=build /app/build ./build
|
16 |
+
|
17 |
+
RUN bun install
|
18 |
+
|
19 |
+
USER bun
|
20 |
|
21 |
+
EXPOSE 3000
|
22 |
|
23 |
+
CMD ["bun", "./build/index.js"]
|
bun.lockb
CHANGED
Binary files a/bun.lockb and b/bun.lockb differ
|
|
package.json
CHANGED
@@ -16,6 +16,7 @@
|
|
16 |
"@tailwindcss/typography": "^0.5.14",
|
17 |
"autoprefixer": "^10.4.20",
|
18 |
"svelte": "^4.2.7",
|
|
|
19 |
"svelte-check": "^3.6.0",
|
20 |
"tailwindcss": "^3.4.9",
|
21 |
"typescript": "^5.0.0",
|
|
|
16 |
"@tailwindcss/typography": "^0.5.14",
|
17 |
"autoprefixer": "^10.4.20",
|
18 |
"svelte": "^4.2.7",
|
19 |
+
"svelte-adapter-bun": "^0.5.2",
|
20 |
"svelte-check": "^3.6.0",
|
21 |
"tailwindcss": "^3.4.9",
|
22 |
"typescript": "^5.0.0",
|
svelte.config.js
CHANGED
@@ -1,4 +1,4 @@
|
|
1 |
-
import adapter from
|
2 |
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
|
3 |
|
4 |
/** @type {import('@sveltejs/kit').Config} */
|
|
|
1 |
+
import adapter from "svelte-adapter-bun";
|
2 |
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
|
3 |
|
4 |
/** @type {import('@sveltejs/kit').Config} */
|