File tree Expand file tree Collapse file tree 2 files changed +19
-3
lines changed
Expand file tree Collapse file tree 2 files changed +19
-3
lines changed Original file line number Diff line number Diff line change 1+ # Vite.js build
2+ FROM node:lts-alpine AS node
3+
4+ WORKDIR /app
5+
6+ # Cache layer for "npm ci"
7+ COPY /package.json /package-lock.json /app/
8+ RUN npm ci
9+ # Copy JavaScript
10+ COPY /vite.config.js /app/
11+ COPY /resources/ /app/resources/
12+ # Build using Vite.js
13+ RUN npm run build
14+
115FROM nginx:1-alpine
216
317WORKDIR /app/public
418
5- COPY public/ /app/public/
19+ COPY --from=node /app/public/build/ /app/public/build/
20+
21+ COPY /public/ /app/public/
Original file line number Diff line number Diff line change @@ -32,8 +32,8 @@ RUN install-php-extensions bcmath pdo_pgsql redis
3232WORKDIR /app
3333
3434COPY / /app
35- COPY --from=node /app/public/build /app/public/build
36- COPY --from=composer /app/vendor/ /app/vendor
35+ COPY --from=node /app/public/build /app/public/build/
36+ COPY --from=composer /app/vendor/ /app/vendor/
3737
3838RUN chown --recursive www-data:www-data /app/storage
3939
You can’t perform that action at this time.
0 commit comments