Skip to content

Instantly share code, notes, and snippets.

@jukbot
Last active July 7, 2024 04:33
Show Gist options
  • Save jukbot/289784bdea2909463249a9ef82371f32 to your computer and use it in GitHub Desktop.
Save jukbot/289784bdea2909463249a9ef82371f32 to your computer and use it in GitHub Desktop.
A example of Dockerfile to run elysia static server
FROM oven/bun:latest AS build-stage
WORKDIR /app
ADD package.json bun.lockb ./
RUN bun install --frozen-lockfile
ADD . .
RUN bun run build
FROM oven/bun:1-alpine
WORKDIR /app
ENV NODE_ENV=production
COPY --from=build-stage /app/dist ./dist
ADD elysia.ts ./
CMD ["bun", "run", "/app/elysia.ts"]
EXPOSE 3000
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment