tangled
alpha
login
or
join now
vicwalker.dev.br
/
pds-mirror
0
fork
atom
Mirror from bluesky-social/pds
0
fork
atom
overview
issues
pulls
pipelines
Merge branch 'main' of github.com:bluesky-social/pds
Jake Gold
2 years ago
2fde0c00
0b17c8ec
+3
-10
1 changed file
expand all
collapse all
unified
split
Dockerfile
+3
-10
Dockerfile
···
2
2
3
3
# Move files into the image and install
4
4
WORKDIR /app
5
5
-
COPY ./service ./service
6
6
-
7
7
-
WORKDIR /app/service
5
5
+
COPY ./service ./
8
6
RUN yarn install --production --frozen-lockfile > /dev/null
9
7
10
8
# Uses assets from build stage to reduce build size
11
9
FROM node:18-alpine
12
10
13
13
-
# RUN npm install -g yarn
14
11
RUN apk add --update dumb-init
15
12
16
13
# Avoid zombie processes, handle signal forwarding
17
14
ENTRYPOINT ["dumb-init", "--"]
18
15
19
19
-
WORKDIR /app/service
16
16
+
WORKDIR /app
20
17
COPY --from=build /app /app
21
21
-
RUN mkdir /app/data && chown node /app/data
22
18
23
23
-
VOLUME /app/data
24
19
EXPOSE 3000
25
20
ENV PDS_PORT=3000
26
21
ENV NODE_ENV=production
27
22
28
28
-
# https://github.com/nodejs/docker-node/blob/master/docs/BestPractices.md#non-root-user
29
29
-
USER node
30
30
-
CMD ["node", "--heapsnapshot-signal=SIGUSR2", "--enable-source-maps", "index.js"]
23
23
+
CMD ["node", "--enable-source-maps", "index.js"]
31
24
32
25
LABEL org.opencontainers.image.source=https://github.com/bluesky-social/pds
33
26
LABEL org.opencontainers.image.description="ATP Personal Data Server (PDS)"