File tree 1 file changed +6
-3
lines changed
1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change 1
- FROM caddy:2.5.1-builder -alpine as builder
1
+ FROM node:17 -alpine as builder
2
2
3
3
# make the 'app' folder the current working directory
4
4
WORKDIR /app
5
5
6
6
# copy both 'package.json' and 'package-lock.json' (if available)
7
7
COPY package*.json ./
8
8
9
+ # install project dependencies
10
+ RUN npm ci --legacy-peer-deps
11
+
9
12
# copy project files and folders to the current working directory (i.e. 'app' folder)
10
13
COPY . .
11
14
12
15
ARG VUE_APP_VERSION_ID=production
13
16
ARG VUE_APP_BUILD_ID=local
14
17
15
18
# build app for production with minification
16
- RUN xcaddy build
19
+ RUN npm run build --legacy-peer-deps
17
20
18
21
FROM caddy:2.5.1-alpine
19
22
20
23
# copy build artifacts to webserver root
21
24
RUN rm -rf /usr/share/caddy
22
- COPY --from=builder /app/caddy /usr/share/caddy
25
+ COPY --from=builder /app/dist /usr/share/caddy
23
26
24
27
# copy webserver configuration
25
28
COPY ./Caddyfile /etc/caddy/Caddyfile
You can’t perform that action at this time.
0 commit comments