Merge pull request 'changed docker' (#15) from fix/ssh_issue into main
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
Reviewed-on: #15
This commit is contained in:
commit
3092b52a2c
16
.drone.yml
16
.drone.yml
|
|
@ -1,17 +1,13 @@
|
|||
kind: pipeline
|
||||
type: docker
|
||||
name: Build Image
|
||||
|
||||
steps:
|
||||
# - name: Lint Check
|
||||
# image: node:21-alpine
|
||||
# commands:
|
||||
# - yarn install
|
||||
# # - yarn lint
|
||||
|
||||
- name: Build Docker Image
|
||||
image: plugins/docker
|
||||
settings:
|
||||
build_args: "API_BASE_URL=https://www.sangwaritaxi.com/"
|
||||
build_args:
|
||||
- API_BASE_URL=https://www.sangwaritaxi.com/
|
||||
username:
|
||||
from_secret: docker_username
|
||||
password:
|
||||
|
|
@ -42,9 +38,3 @@ steps:
|
|||
- main
|
||||
event:
|
||||
- push
|
||||
# trigger:
|
||||
# branch:
|
||||
# - main
|
||||
# - feature/env_api_url
|
||||
# event:
|
||||
# - push
|
||||
|
|
|
|||
24
Dockerfile
24
Dockerfile
|
|
@ -10,14 +10,30 @@ WORKDIR /app
|
|||
# Copy package.json and package-lock.json
|
||||
COPY package*.json ./
|
||||
|
||||
# Install ALL dependencies (including devDependencies)
|
||||
# Install dependencies
|
||||
RUN npm install
|
||||
|
||||
# Copy source files
|
||||
# Copy all source files
|
||||
COPY . .
|
||||
|
||||
# Pass API URL to Vite
|
||||
ENV VITE_API_BASE_URL=$API_BASE_URL
|
||||
|
||||
# Build the app
|
||||
# RUN npm run build
|
||||
# Build the React app
|
||||
RUN npm run build
|
||||
|
||||
|
||||
# # ------------------------
|
||||
# # Production stage
|
||||
# # ------------------------
|
||||
# FROM nginx:stable-alpine
|
||||
|
||||
# # Copy React build output to Nginx html folder
|
||||
# COPY --from=builder /app/build /usr/share/nginx/html
|
||||
|
||||
# # Optional: custom nginx config for React Router
|
||||
# # (so /about, /contact etc. don’t 404)
|
||||
# COPY nginx.conf /etc/nginx/conf.d/default.conf
|
||||
|
||||
# EXPOSE 80
|
||||
# CMD ["nginx", "-g", "daemon off;"]
|
||||
|
|
|
|||
Loading…
Reference in New Issue