Skip to content

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
BillChirico authored Nov 6, 2023
1 parent 8bce966 commit 4ca7042
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,20 @@ LABEL name="Docusaurus on docker latest-stable" \
description="Volvox.Apollo Docs \
on Node 20.x, lts-alpine"

# run as our node user from base image
# we delete the dockerfiles we don't need
# this leaves us with a default v1 docusarus install
# we can mount our own into the container
USER node
RUN npm install
RUN mkdir ~/npm-global \
&& npm config set prefix '~/npm-global' \
&& echo 'export PATH=~/npm-global/bin:$PATH' > ~/.profile \
&& mkdir -p /home/node/docs \
&& cd /home/node/docs \
&& npm install --global docusaurus-init \
&& sh -l -c docusaurus-init \
&& rm Dockerfile \
&& rm docker-compose.yml

EXPOSE 5001/tcp
USER node
Expand Down

0 comments on commit 4ca7042

Please sign in to comment.