Skip to main content

Dockerfile

The Dockerfile for a hook looks like the following. If you use the provided hook-sdk, you won't need to apply any changes to it.

ARG baseImageTagFROM node:12-alpine as buildRUN mkdir -p /home/appWORKDIR /home/appCOPY package.json package-lock.json ./RUN npm ci --production
FROM securecodebox/hook-sdk-nodejs:${baseImageTag:-latest}WORKDIR /home/app/hook-wrapper/hook/COPY --from=build --chown=app:app /home/app/node_modules/ ./node_modules/COPY --chown=app:app ./hook.js ./hook.js