-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (19 loc) · 704 Bytes
/
Dockerfile
File metadata and controls
27 lines (19 loc) · 704 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
FROM oven/bun:latest
# Set working directory
WORKDIR /app
# Copy package.json and bun.lockb (if exists)
COPY package.json ./
COPY bun.lockb* ./
# Install dependencies
RUN bun install --frozen-lockfile
# Copy all files
COPY . .
# Expose the port your app runs on
EXPOSE 6969
# Set environment variables (these will be overridden by Render)
# ENV RESEND_API_KEY="your-resend-api-key-here"
# Add health check using bun (which is available in the image)
HEALTHCHECK --interval=600s --timeout=10s --start-period=30s --retries=3 \
CMD bun -e "const res = await fetch('http://localhost:6969/health'); process.exit(res.ok ? 0 : 1)" || exit 1
# Start the application
CMD ["bun", "run", "./src/index.ts"]