1
0
Fork 0
cautious-journey/Dockerfile.stretch

28 lines
746 B
Docker

FROM docker.artifacts.apextoaster.com/library/node:19
# dependencies: log filtering
RUN apt-get update -y \
&& apt-get install -y jq \
&& rm -rf /var/lib/apt/lists/* \
&& yarn global add bunyan
ENV PATH="${PATH}:$(yarn global bin)"
WORKDIR /cautious-journey
# copy config, which changes rarely
COPY docs/config.yml /root/.cautious-journey.yml
# copy package first, to invalidate other layers when version changes
COPY package.json /cautious-journey/package.json
COPY yarn.lock /cautious-journey/yarn.lock
RUN yarn
# copy chunks, largest to smallest (entrypoint)
COPY out/src/ /cautious-journey/out/src/
# set up as global cli tool
RUN yarn global add file:$(pwd)
ENTRYPOINT [ "node", "/cautious-journey/out/index.js" ]
CMD [ "--help" ]