2019-09-16 14:09:59 +01:00
|
|
|
ARG DOCKER_ARCH
|
2019-02-28 20:12:52 +00:00
|
|
|
# Satellite UI static asset generation
|
2021-10-14 13:44:54 +01:00
|
|
|
FROM node:16.11.1 as ui
|
2019-02-28 20:12:52 +00:00
|
|
|
WORKDIR /app
|
|
|
|
COPY web/satellite/ /app
|
|
|
|
# Need to clean up (or ignore) local folders like node_modules, etc...
|
|
|
|
RUN npm install
|
|
|
|
RUN npm run build
|
2018-06-05 22:06:37 +01:00
|
|
|
|
2020-12-08 20:49:41 +00:00
|
|
|
# Fetch ca-certificates file for arch independent builds below
|
2022-03-25 08:18:58 +00:00
|
|
|
FROM debian:buster-slim as ca-cert
|
|
|
|
RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates
|
|
|
|
RUN update-ca-certificates
|
2020-12-08 20:49:41 +00:00
|
|
|
|
2022-03-25 08:18:58 +00:00
|
|
|
FROM ${DOCKER_ARCH:-amd64}/debian:buster-slim
|
2019-04-16 22:06:59 +01:00
|
|
|
ARG TAG
|
|
|
|
ARG GOARCH
|
|
|
|
ENV GOARCH ${GOARCH}
|
2020-06-22 20:06:31 +01:00
|
|
|
ENV CONF_PATH=/root/.local/share/storj/satellite \
|
2019-02-28 20:12:52 +00:00
|
|
|
STORJ_CONSOLE_STATIC_DIR=/app \
|
|
|
|
STORJ_CONSOLE_ADDRESS=0.0.0.0:10100
|
2018-12-21 16:56:57 +00:00
|
|
|
EXPOSE 7777
|
2019-02-28 20:12:52 +00:00
|
|
|
EXPOSE 10100
|
2018-06-05 22:06:37 +01:00
|
|
|
WORKDIR /app
|
2019-09-16 14:09:59 +01:00
|
|
|
COPY --from=ui /app/static /app/static
|
|
|
|
COPY --from=ui /app/dist /app/dist
|
2020-12-08 20:49:41 +00:00
|
|
|
COPY --from=ca-cert /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
|
2020-12-11 01:23:39 +00:00
|
|
|
COPY release/${TAG}/wasm/access.wasm /app/static/wasm/
|
|
|
|
COPY release/${TAG}/wasm/wasm_exec.js /app/static/wasm/
|
2020-12-15 19:10:56 +00:00
|
|
|
COPY release/${TAG}/wasm/access.wasm.br /app/static/wasm/
|
|
|
|
COPY release/${TAG}/wasm/wasm_exec.js.br /app/static/wasm/
|
2019-04-16 22:06:59 +01:00
|
|
|
COPY release/${TAG}/satellite_linux_${GOARCH:-amd64} /app/satellite
|
|
|
|
COPY cmd/satellite/entrypoint /entrypoint
|
2018-08-23 16:48:03 +01:00
|
|
|
ENTRYPOINT ["/entrypoint"]
|