- Download the repository containing the system (frontend: Vue, backend: Node.js, and Python scripts).
- The structure should include at least three separate projects for each part of the application:
www/frontend/www/backend/lstm/
- Make sure Docker and Docker Compose are installed on your system.
- In the main project folder (or a dedicated directory), include the following files (if they are not already present):
- A
Dockerfilefor each service docker-compose.yml
- A
version: '3'
services:
python-lstm:
build:
context: ./lstm
dockerfile: Dockerfile
environment:
- FLASK_APP=src/app.py
ports:
- "5000:5000"
networks:
- app-network
volumes:
- ./lstm:/app
backend:
build:
context: ./www/backend
dockerfile: Dockerfile
ports:
- "3000:3000"
networks:
- app-network
depends_on:
- python-lstm
frontend:
build:
context: ./www/frontend
dockerfile: Dockerfile
ports:
- "8080:80"
networks:
- app-network
depends_on:
- backend
volumes:
- ./www/frontend:/app
networks:
app-network:
driver: bridge-
Navigate to the main directory (where the
docker-compose.ymlfile is located). -
Run the following command to build the containers:
docker-compose build
-
Start the containers:
docker-compose up -d
-
Verify that the services are running:
- Frontend: http://localhost:8080
- Backend: http://localhost:3000
- Python LSTM: http://localhost:5000
- Depending on your needs, add environment variables (e.g., API keys, database credentials) either in
.envfiles or directly in thedocker-compose.yml. - Make sure each container is properly configured:
- Python services: install required libraries listed in
requirements.txt - Node.js services: install dependencies from
package.json
- Python services: install required libraries listed in
-
After launching the containers, check the logs:
docker-compose logs -f
-
Make sure all services are up and listening on their designated ports.
-
Test the communication between services:
- Frontend should be able to call backend endpoints
- Backend should be able to call the Python LSTM algorithm









