12 lines
436 B
Docker

FROM node:latest
WORKDIR /app
COPY package.json ./
RUN npm install
COPY src/ ./
RUN apt-get update && apt-get install -y wget jq
# Fetch latest noble-curves.js from github
RUN URL=$(wget -q -O - https://api.github.com/repos/paulmillr/noble-curves/releases/latest | jq -r '.assets[] | select(.name | contains("noble-curves.js")) | .browser_download_url') && \
wget -O ./public/noble-curves.js $URL
EXPOSE 3333
CMD ["node", "app.js"]