Machan . podi help ekak one. mama react typescript app ekakui, .net core api ekakui docker walin run karanna baluwe, eth react app eka changes karala "docker compose up"
run karata mage changes apply wenne na. meka kohomada fix karanne.
me thiyenne docker file eka
me thiyenne docker-compose.yml eka
fix karaganna help ekak ona.hadissi machan,pls help
run karata mage changes apply wenne na. meka kohomada fix karanne.
me thiyenne docker file eka
Code:
FROM node:latest
# Set the working directory in the container
WORKDIR /app
# Copy package.json and package-lock.json to the working directory
COPY package*.json ./
# Install dependencies
RUN npm install
# Copy the rest of the application code
COPY . .
# Expose port 3000 to the outside world
EXPOSE 3000
# Start the React app
CMD ["npm", "start"]
me thiyenne docker-compose.yml eka
Code:
version: '3.4'
services:
my_app-ui:
build: ./my_app-ui
container_name: my_app-ui_app
ports:
- "3000:3000"
stdin_open: true
tty: true
my_appdb:
container_name: my_app-db
image: mysql:8.3.0
environment:
MYSQL_ROOT_PASSWORD: W7301@jqir#
ports:
- "8002:3306"
my_app.api:
container_name: my_app-api
image: ${DOCKER_REGISTRY-}my_appapi
build:
context: .
dockerfile: my_app.API/Dockerfile
ports:
- "5000:5000"
- "5001:5001"
environment:
- DB_HOST=my_appdb
- DB_NAME=my_app
- DB_ROOT_PASSWORD=W7301@jqir#
fix karaganna help ekak ona.hadissi machan,pls help