Url shortner
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
linkylinky/Dockerfile

18 lines
624 B

FROM registry.odit.services/hub/library/node:18.0.0-alpine3.14
ARG NPM_REGISTRY_DOMAIN=registry.npmjs.org
ARG NPM_REGISTRY_TOKEN=null
WORKDIR /app
COPY package.json .
RUN npm config set registry https://$NPM_REGISTRY_DOMAIN && npm config set //$NPM_REGISTRY_DOMAIN/:_authToken $NPM_REGISTRY_TOKEN
RUN npm i -g pnpm && pnpm i
COPY migrations ./migrations
COPY src ./src
COPY knexfile.js ./
RUN mkdir db
FROM registry.odit.services/hub/library/node:18.0.0-alpine3.14
WORKDIR /app
COPY --from=0 /app /app
ENV NODE_ENV production
EXPOSE 3000
ENTRYPOINT ["/bin/sh", "-c", "yarn migrate && node ./src/server.js"]