Skip to content

Commit

Permalink
REALLY Hacky workaround to get BitHunt containerised
Browse files Browse the repository at this point in the history
  • Loading branch information
RJMurg committed Aug 4, 2024
1 parent 9f790a7 commit f65a57a
Show file tree
Hide file tree
Showing 9 changed files with 973 additions and 8 deletions.
9 changes: 9 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
node_modules
bun.lockb
.dockerignore
.git
README.md
docker-compose.yaml
Dockerfile
docs
build
15 changes: 15 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Step 1: Build stage
FROM node:18-alpine AS build
WORKDIR /app
COPY package.json package-lock.json ./
RUN npm ci --force
COPY . .

# Step 2: Production stage
FROM node:18-alpine
WORKDIR /app
COPY --from=build /app .
RUN npm run build
COPY start.sh start.sh
RUN chmod +x start.sh
CMD ["./start.sh"]
31 changes: 31 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
services:
app:
build: .
ports:
- '3000:3000'
environment:
DATABASE_URL: postgresql://prisma:prisma@db:5432/prismadb?schema=public
ADMIN_PASSWORD: password
ORIGIN: http://localhost:3000
depends_on:
- db
networks:
- app-network

db:
image: postgres:13
environment:
POSTGRES_USER: prisma
POSTGRES_PASSWORD: prisma
POSTGRES_DB: prismadb
volumes:
- postgres-data:/var/lib/postgresql/data
networks:
- app-network

networks:
app-network:
driver: bridge

volumes:
postgres-data:
Loading

0 comments on commit f65a57a

Please sign in to comment.