-
Notifications
You must be signed in to change notification settings - Fork 115
/
colossus.Dockerfile
44 lines (35 loc) · 1.41 KB
/
colossus.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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
FROM node:18 as builder
WORKDIR /joystream
COPY ./chain-metadata.json chain-metadata.json
COPY ./yarn.lock yarn.lock
COPY ./types/package.json types/package.json
COPY ./metadata-protobuf/package.json metadata-protobuf/package.json
COPY ./devops/eslint-config/package.json ./devops/eslint-config/package.json
COPY ./devops/prettier-config/package.json ./devops/prettier-config/package.json
COPY ./storage-node/package.json storage-node/package.json
COPY ./storage-node/client/package.json storage-node/client/package.json
COPY ./opentelemetry/package.json opentelemetry/package.json
COPY ./package.json package.json
RUN yarn --frozen-lockfile
COPY ./types types
COPY ./metadata-protobuf metadata-protobuf
COPY ./devops/eslint-config ./devops/eslint-config
COPY ./devops/prettier-config ./devops/prettier-config
COPY ./storage-node storage-node
COPY ./opentelemetry opentelemetry
COPY ./tsconfig.json ./tsconfig.json
RUN yarn workspace @joystream/types build
RUN yarn workspace @joystream/metadata-protobuf build
RUN yarn workspace @joystream/opentelemetry build
RUN yarn workspace storage-node build
RUN yarn cache clean
FROM node:18 as final
WORKDIR /joystream
COPY --from=builder /joystream /joystream
RUN yarn --frozen-lockfile --production
# Use these volumes to persist uploading data and to pass the keyfile.
VOLUME ["/data", "/keystore", "/logs"]
# Colossus node port
EXPOSE 3333
ENTRYPOINT ["yarn", "storage-node"]
CMD ["server"]