perbaikan docker
This commit is contained in:
parent
3fb2a522ea
commit
e8f8b5eb9d
@ -13,10 +13,9 @@ RUN npm run build
|
||||
# Gunakan NGINX untuk menyajikan SPA
|
||||
FROM nginx:1.29.0-alpine-slim
|
||||
|
||||
# Salin hasil build ke folder root nginx
|
||||
COPY --from=builder /app/.output/public /usr/share/nginx/html
|
||||
RUN rm /etc/nginx/conf.d/default.conf
|
||||
|
||||
# Salin konfigurasi khusus NGINX untuk SPA (opsional tapi direkomendasikan)
|
||||
COPY --from=builder /app/.output/public /usr/share/nginx/html
|
||||
COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
@ -8,4 +8,6 @@ server {
|
||||
location / {
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
error_page 404 /index.html;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user