Skip to content

Commit

Permalink
Add docker file.
Browse files Browse the repository at this point in the history
  • Loading branch information
realazthat committed Aug 20, 2024
1 parent 4db24d8 commit 5bfad38
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM node:20.12.1-bullseye-slim


WORKDIR /excalidraw-brute-export-cli

RUN apt-get -y update && apt-get -y --no-install-recommends install bash && \
apt-get -y clean && \
apt-get -y autoremove && \
rm -rf /var/lib/apt/lists/* && \
useradd -m -d /home/user -s /bin/bash user && \
mkdir -p /home/user/.local && \
chown -R user:user /excalidraw-brute-export-cli /home/user/.local && \
chmod -R a+wrX /excalidraw-brute-export-cli

COPY --chown=user:user . /excalidraw-brute-export-cli
USER user
ENV NPM_CONFIG_PREFIX=/home/user/.npm-global
ENV PATH=/home/user/.npm-global/bin:$PATH
WORKDIR /excalidraw-brute-export-cli
RUN npm install -g .

# This is where the user will mount their data to.
WORKDIR /data

ENTRYPOINT ["npx", "excalidraw-brute-export-cli"]
CMD ["--help"]
HEALTHCHECK --interval=30s --timeout=10s --retries=3 \
CMD npx excalidraw-brute-export-cli --version || exit 1

0 comments on commit 5bfad38

Please sign in to comment.