@nilejs/cli 0.0.6 → 0.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/template/.dockerignore +12 -0
- package/template/Dockerfile +19 -0
- package/template/docker-compose.dev.yml +14 -0
- package/template/docker-compose.yml +36 -0
package/package.json
CHANGED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
FROM oven/bun:1-alpine
|
|
2
|
+
|
|
3
|
+
WORKDIR /app
|
|
4
|
+
|
|
5
|
+
# Copy package files
|
|
6
|
+
COPY package.json ./
|
|
7
|
+
COPY bun.lockb ./
|
|
8
|
+
|
|
9
|
+
# Install production dependencies only
|
|
10
|
+
RUN bun install --frozen-lockfile --production
|
|
11
|
+
|
|
12
|
+
# Copy source code
|
|
13
|
+
COPY . .
|
|
14
|
+
|
|
15
|
+
# Expose the port (default for Nile)
|
|
16
|
+
EXPOSE 8000
|
|
17
|
+
|
|
18
|
+
# Start the server
|
|
19
|
+
CMD ["bun", "run", "src/index.ts"]
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
version: "3.8"
|
|
2
|
+
|
|
3
|
+
services:
|
|
4
|
+
nile:
|
|
5
|
+
build:
|
|
6
|
+
context: .
|
|
7
|
+
dockerfile: Dockerfile
|
|
8
|
+
ports:
|
|
9
|
+
- "8000:8000"
|
|
10
|
+
environment:
|
|
11
|
+
- NODE_ENV=production
|
|
12
|
+
- DB_HOST=postgres
|
|
13
|
+
- DB_PORT=5432
|
|
14
|
+
- DB_NAME=nile
|
|
15
|
+
- DB_USER=postgres
|
|
16
|
+
- DB_PASSWORD=postgres
|
|
17
|
+
depends_on:
|
|
18
|
+
postgres:
|
|
19
|
+
condition: service_healthy
|
|
20
|
+
|
|
21
|
+
postgres:
|
|
22
|
+
image: postgres:16-alpine
|
|
23
|
+
environment:
|
|
24
|
+
POSTGRES_DB: nile
|
|
25
|
+
POSTGRES_USER: postgres
|
|
26
|
+
POSTGRES_PASSWORD: postgres
|
|
27
|
+
volumes:
|
|
28
|
+
- postgres_data:/var/lib/postgresql/data
|
|
29
|
+
healthcheck:
|
|
30
|
+
test: ["CMD-SHELL", "pg_isready -U postgres"]
|
|
31
|
+
interval: 5s
|
|
32
|
+
timeout: 5s
|
|
33
|
+
retries: 5
|
|
34
|
+
|
|
35
|
+
volumes:
|
|
36
|
+
postgres_data:
|