forked from sushi-labs/sushiswap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.router
42 lines (26 loc) · 887 Bytes
/
Dockerfile.router
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
FROM node:20-slim AS base
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
ENV PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1
ARG TURBO_TEAM
ENV TURBO_TEAM=$TURBO_TEAM
ARG TURBO_TOKEN
ENV TURBO_TOKEN=$TURBO_TOKEN
RUN corepack enable
WORKDIR /app
# RUN pnpm install turbo --global
COPY apis/router apis/router
COPY config/jest config/jest
COPY config/typescript config/typescript
COPY packages/extractor packages/extractor
COPY packages/sushi packages/sushi
COPY patches patches
COPY package.json package.json
COPY pnpm-lock.yaml pnpm-lock.yaml
COPY pnpm-workspace.yaml pnpm-workspace.yaml
COPY turbo.json turbo.json
RUN pnpm install --frozen-lockfile
RUN pnpm exec turbo run build --filter=@sushiswap/router-api
EXPOSE 80
ENV NODE_ENV=production
CMD NODE_OPTIONS=--max-old-space-size=$(expr $(echo "$(free -m)" | awk '/^Mem:/ {print $2}') - 512) node /app/apis/router/dist/index.js