-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
30 lines (23 loc) · 1.04 KB
/
Dockerfile
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
FROM communityfirst/mapeo-settings-builder
WORKDIR /app
# Install dependencies based on the preferred package manager
COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* ./
RUN \
if [ -f yarn.lock ]; then PUPPETEER_SKIP_DOWNLOAD=false yarn --frozen-lockfile && yarn add puppeteer; \
elif [ -f package-lock.json ]; then PUPPETEER_SKIP_DOWNLOAD=false npm ci && npm install puppeteer; \
elif [ -f pnpm-lock.yaml ]; then yarn global add pnpm && PUPPETEER_SKIP_DOWNLOAD=false pnpm i --frozen-lockfile && pnpm add puppeteer; \
else echo "Lockfile not found." && exit 1; \
fi
# Copy source code
COPY . .
RUN yarn deploy
ENV NODE_ENV production
ENV ROOT_DIR /tmp
ENV DEFAULT_CONFIG_URL https://github.com/digidem/mapeo-default-config/releases/download/v3.6.1/mapeo-default-settings-v3.6.1.mapeosettings
# Uncomment the following line in case you want to disable telemetry during runtime.
# ENV NEXT_TELEMETRY_DISABLED 1
EXPOSE 3000
ENV PORT 3000
# set hostname to localhost
ENV HOSTNAME "0.0.0.0"
CMD ["node", ".next/standalone/server.js"]