Add folders

This commit is contained in:
Dominic Ferrando
2025-09-03 19:20:59 -04:00
parent 032a6f67b4
commit 1219807557
20 changed files with 6981 additions and 3 deletions
+38
View File
@@ -0,0 +1,38 @@
# syntax = docker/dockerfile:1
FROM oven/bun:1.2.12-slim as base
LABEL fly_launch_runtime="Bun"
# NodeJS app lives here
WORKDIR /app
# Set production environment
ENV NODE_ENV=production
# Throw-away build stage to reduce size of final image
FROM base as build
# Install packages needed to build node modules
RUN apt-get update -qq && \
apt-get install -y python-is-python3 pkg-config build-essential
# Install node modules
COPY --link package.json .
RUN bun install --production
# Copy application code
COPY --link . .
# Final stage for app image
FROM base
# Copy built application
COPY --from=build /app /app
RUN apt-get update && apt-get install -y sqlite3 && rm -rf /var/lib/apt/lists/*
# Start the server by default, this can be overwritten at runtime
CMD [ "bun", "run", "db:seed:prod" ]
CMD [ "bun", "run", "start" ]