FROM node:20.19-bullseye

WORKDIR /app

COPY node_modules ./node_modules
COPY package.json ./package.json
COPY json-server.json ./json-server.json
COPY routes.json ./routes.json
COPY singular.js ./singular.js
COPY src ./src

EXPOSE 3000

ENTRYPOINT ["node", "./node_modules/.bin/json-server", "src/index.js"]
