Skip to content
Snippets Groups Projects
Commit 260fa9a5 authored by Mohamed Anis Koubaa's avatar Mohamed Anis Koubaa :speech_balloon:
Browse files

make both docker running.

parent 98d35b06
No related branches found
No related tags found
No related merge requests found
...@@ -12,8 +12,7 @@ services: ...@@ -12,8 +12,7 @@ services:
frontend: frontend:
build: ./services/frontend build: ./services/frontend
volumes:
- './services/frontend:/app'
- '/app/node_modules'
ports: ports:
- "3000:3000" - "8080:8080"
\ No newline at end of file volumes:
- ./services/frontend/src:/app/src
\ No newline at end of file
FROM python:3.10-alpine FROM python:3.10-alpine
RUN mkdir app
WORKDIR /app WORKDIR /app
ENV PATH="${PATH}:/root/.local/bin" ENV PATH="${PATH}:/root/.local/bin"
...@@ -11,3 +10,5 @@ RUN pip install --upgrade pip ...@@ -11,3 +10,5 @@ RUN pip install --upgrade pip
RUN pip install -r requirements.txt RUN pip install -r requirements.txt
COPY src/ . COPY src/ .
CMD ["uvicorn", "main:app", "--reload", "--host", "0.0.0.0", "--port", "8000"]
FROM node:lts-alpine FROM node:lts-alpine
RUN mkdir app # Set the working directory
WORKDIR /app WORKDIR /app
ENV PATH /app/node_modules/.bin:$PATH
RUN npm install -g npm@11.1.0 RUN npm install -g npm@11.1.0
COPY package.json . # Copy package.json
COPY package.json ./
# Install dependencies
RUN npm install RUN npm install
# Copy the rest of the application code
COPY . .
# Expose the application port
EXPOSE 8080
# Start the application
CMD ["npm", "run", "dev"] CMD ["npm", "run", "dev"]
\ No newline at end of file
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
"type": "module", "type": "module",
"version": "0.1.0", "version": "0.1.0",
"scripts": { "scripts": {
"dev": "vite", "dev": "vite --host 0.0.0.0",
"build": "vite build", "build": "vite build",
"preview": "vite preview", "preview": "vite preview",
"lint": "eslint . --fix" "lint": "eslint . --fix"
......
...@@ -44,7 +44,7 @@ ...@@ -44,7 +44,7 @@
<template #subtitle> <template #subtitle>
<div class="text-subtitle-1"> <div class="text-subtitle-1">
Replace this page by removing <v-kbd>{{ `<HelloWorld></HelloWorld>` }}</v-kbd> in <v-kbd>pages/index.vue</v-kbd>. Please login to access.
</div> </div>
</template> </template>
......
...@@ -62,7 +62,7 @@ export default defineConfig({ ...@@ -62,7 +62,7 @@ export default defineConfig({
], ],
}, },
server: { server: {
port: 3000, port: 8080,
}, },
css: { css: {
preprocessorOptions: { preprocessorOptions: {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment