diff --git a/Dockerfile b/Dockerfile index 7d85c9b..abf5c39 100644 --- a/Dockerfile +++ b/Dockerfile @@ -16,10 +16,10 @@ WORKDIR /app COPY --from=builder /app/dist /app -RUN npm install -g pm2 +RUN npm install -g pm2 serve COPY ecosystem.config.js ./ EXPOSE 3000 -CMD ["pm2-runtime", "ecosystem.config.js"] \ No newline at end of file +CMD ["pm2-runtime", "start", "ecosystem.config.js"] \ No newline at end of file diff --git a/ecosystem.config.js b/ecosystem.config.js index bcf1b4c..6872a50 100644 --- a/ecosystem.config.js +++ b/ecosystem.config.js @@ -1,10 +1,11 @@ /*eslint no-undef: "off"*/ +// ecosystem.config.js module.exports = { apps: [ { name: 'vite-react-app', script: 'serve', - args: '-s . -l 3000', + args: '-s /app -l 3000', env: { NODE_ENV: 'production', },