-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfileLegacy
More file actions
38 lines (25 loc) · 835 Bytes
/
DockerfileLegacy
File metadata and controls
38 lines (25 loc) · 835 Bytes
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
FROM node:22-alpine AS build
WORKDIR /opt/app
ADD . .
RUN npm ci --legacy-peer-deps
RUN npm run build --omit=dev
FROM node:22-alpine
RUN mkdir -p /var/log/supervisor /var/lib/rnode/xray \
&& echo '{}' > /var/lib/rnode/xray/xray-config.json
WORKDIR /opt/app
COPY --from=build /opt/app/dist ./dist
RUN apk add --no-cache \
curl \
unzip \
bash \
supervisor \
&& curl -L https://raw.githubusercontent.com/localzet/aura-node/main/install-xray.sh | bash -s -- v1.8.23 \
&& apk del curl
COPY supervisord.conf /etc/supervisord.conf
COPY docker-entrypoint.sh /usr/local/bin/
RUN chmod +x /usr/local/bin/docker-entrypoint.sh
COPY package*.json ./
RUN npm ci --omit=dev --legacy-peer-deps \
&& npm cache clean --force
ENTRYPOINT ["/usr/local/bin/docker-entrypoint.sh"]
CMD ["npm", "run", "start:prod"]