colossus.Dockerfile 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. FROM --platform=linux/x86-64 node:14 as builder
  2. WORKDIR /joystream
  3. COPY . /joystream
  4. RUN yarn
  5. RUN yarn workspace @joystream/types build
  6. RUN yarn workspace @joystream/metadata-protobuf build
  7. RUN yarn workspace storage-node-v2 build
  8. # Use these volumes to persist uploading data and to pass the keyfile.
  9. VOLUME ["/data", "/keystore"]
  10. # Required variables
  11. ENV WS_PROVIDER_ENDPOINT_URI=ws://not-set
  12. ENV COLOSSUS_PORT=3333
  13. ENV QUERY_NODE_HOST=not-set
  14. ENV WORKER_ID=not-set
  15. # - set external key file using the `/keystore` volume
  16. ENV ACCOUNT_KEYFILE=
  17. ENV ACCOUNT_PWD=
  18. # Optional variables
  19. ENV SYNC_INTERVAL=1
  20. ENV ELASTIC_SEARCH_HOST=
  21. # - overrides account key file
  22. ENV ACCOUNT_URI=
  23. # Colossus node port
  24. EXPOSE ${COLOSSUS_PORT}
  25. WORKDIR /joystream/storage-node-v2
  26. ENTRYPOINT yarn storage-node server --queryNodeHost ${QUERY_NODE_HOST} --port ${COLOSSUS_PORT} --uploads /data --worker ${WORKER_ID} --apiUrl ${WS_PROVIDER_ENDPOINT_URI} --sync --syncInterval=${SYNC_INTERVAL} --keyFile=${ACCOUNT_KEYFILE} --elasticSearchHost=${ELASTIC_SEARCH_HOST}