diff --git a/docker-compose-ci.yaml b/docker-compose-ci.yaml index be9ea60a..397bdb90 100644 --- a/docker-compose-ci.yaml +++ b/docker-compose-ci.yaml @@ -65,9 +65,11 @@ services: - backend networks: - vh-net + volumes: + - /app/node_modules + - ./frontend:/app + -volumes: - db-data: @@ -85,3 +87,5 @@ volumes: # networks: # vh-net: # ipv4_address: 172.19.0.6 +volumes: + db-data: diff --git a/frontend/Dockerfile b/frontend/Dockerfile index 77227e42..5df6bebb 100644 --- a/frontend/Dockerfile +++ b/frontend/Dockerfile @@ -1,17 +1,14 @@ # Use a specific version of the Node.js image FROM node:16.13.2 -# Set the working directory inside the container -WORKDIR /frontend - -# Copy only the package.json and package-lock.json files to leverage Docker cache -COPY package.json package-lock.json ./ - +WORKDIR /app +COPY package.json . +COPY package-lock.json . # Install dependencies RUN npm install -# Copy the rest of the application code -COPY . . + + # Command to start the application CMD ["npm", "start"] diff --git a/frontend/src/Components/LoginScreen/Signin/Signin.jsx b/frontend/src/Components/LoginScreen/Signin/Signin.jsx index 7b91ffd7..e34f5ed9 100644 --- a/frontend/src/Components/LoginScreen/Signin/Signin.jsx +++ b/frontend/src/Components/LoginScreen/Signin/Signin.jsx @@ -96,7 +96,7 @@ function Signin(props) {