diff --git a/DOCKER.md b/DOCKER.md new file mode 100644 index 00000000..44d473a2 --- /dev/null +++ b/DOCKER.md @@ -0,0 +1,7 @@ +``` +docker build -t pythagora . + +docker run -v ./:/data -it pythagora npx pythagora \ + --unit-tests \ + --path /data/src/helpers/api.js +``` diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..28473107 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,18 @@ +FROM node:18 + +# Create app directory +RUN mkdir /app + +# Set working directory +WORKDIR /app + +# Copy package.json and package-lock.json +COPY package*.json ./ + +# Install dependencies +RUN npm i -g pythagora + +# Copy source code +COPY . . + +VOLUME [ "/data" ]