Skip to content

Commit 183d1dc

Browse files
committed
dockerfile?
1 parent 4366ff5 commit 183d1dc

File tree

5 files changed

+22
-14
lines changed

5 files changed

+22
-14
lines changed

.drone.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ platform:
88
trigger:
99
branch:
1010
- main
11+
- integration/chat
1112
- a/kanopy
1213

1314
steps:

apps/chatbot-server/Dockerfile

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,29 @@ FROM node:20-alpine
44
# Expects the context `./` to be the root of the monorepo
55
# and expects the package to be built
66

7-
COPY ./apps/chatbot-server ./apps/chatbot-server
7+
COPY ./apps/chatbot-server/ apps/chatbot-server/
88

9-
# Copy the node_modules directory from the root
10-
COPY node_modules ./node_modules
9+
# Copy package files and workspace configuration
10+
COPY package.json pnpm-lock.yaml pnpm-workspace.yaml turbo.json ./
11+
12+
# Copy all required directories with their content
13+
COPY tools/ tools/
14+
COPY packages/ packages/
15+
16+
# Ensure the build scripts are executable
17+
RUN chmod +x tools/build/scripts/build.sh
18+
RUN chmod +x tools/build/scripts/build-ts.sh
19+
RUN ls -la tools/build/scripts/
1120

1221
# Install pnpm globally
1322
RUN npm install -g [email protected]
1423

24+
# Install dependencies
25+
RUN pnpm install --frozen-lockfile
26+
27+
# Build the server
28+
RUN pnpm build --filter "lg-chatbot-server"
29+
1530
# Set the working directory to the chatbot-server
1631
WORKDIR ./apps/chatbot-server
1732

apps/chatbot-server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"ingest": "pnpm build && ingest all --config ./dist/esm/ingest.config.js",
1515
"dev": "tsx src/index.ts",
1616
"start": "node dist/esm/index.js",
17-
"docker:build": "pnpm run build && docker build -t chatbot-server --file ./Dockerfile ../..",
17+
"docker:build": "docker build -t chatbot-server --file ./Dockerfile ../..",
1818
"docker:prune": "docker builder prune --filter \"label=app=chatbot-server\" -f",
1919
"docker:start": "docker run -p 3030:3030 chatbot-server"
2020
},

tools/build/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
"module": "dist/esm/index.js",
1515
"types": "./dist/types/index.d.ts",
1616
"scripts": {
17-
"build": "scripts/build.sh",
18-
"tsc": "scripts/build-ts.sh"
17+
"build": "./scripts/build.sh",
18+
"tsc": "./scripts/build-ts.sh"
1919
},
2020
"dependencies": {
2121
"@babel/core": "7.24.3",

tools/build/scripts/tsconfig.json

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)