Gitlab@Informatics

Skip to content
Snippets Groups Projects
Commit 254c755a authored by 65160206's avatar 65160206
Browse files

deploy

parent e823fa55
Branches
No related tags found
No related merge requests found
.env 0 → 100644
VITE_API_BASE_URL=http://localhost:4000
VITE_API_BASE_URL=http://dekdee3.informatics.buu.ac.th:8012
\ No newline at end of file
# Build stage
FROM node:18 AS builder
WORKDIR /app
COPY package*.json ./
RUN npm install
COPY . .
RUN npm run build
# Production stage
FROM nginx:stable-alpine
COPY --from=builder /app/dist /usr/share/nginx/html
# copy nginx config if needed (optional)
# COPY nginx.conf /etc/nginx/nginx.conf
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]
version: "3"
services:
lookoad-frontend:
build: .
ports:
- "8011:80" # นายจองไว้เรียบร้อย
restart: always
...@@ -2,7 +2,7 @@ import router from '@/router' ...@@ -2,7 +2,7 @@ import router from '@/router'
import axios from 'axios' import axios from 'axios'
const instance = axios.create({ const instance = axios.create({
baseURL: 'http://localhost:4000' baseURL: import.meta.env.VITE_API_BASE_URL
}) })
function delay(sec: number) { function delay(sec: number) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment