Deployments
This docker-compose.yml file defines a multi-container Docker application with several services that work together to form a complete system. Each service is configured with specific settings to ensure proper operation and integration.
Overview
Version: The file uses Docker Compose version
3.7. (Depricated)Networks: A custom network named
maiko-localis defined to facilitate communication between the services.Volumes: Several named volumes are defined to persist data across container restarts.
Services
1. maiko-assist
Build: The service is built from the current directory using the
Dockerfilelocated in the root.Restart: The container will always restart if it stops.
Environment: Environment variables are loaded from the
.env.localfile.Ports: Port
3000on the host is mapped to port3000on the container.Devices: The device
/dev/net/tunis added to the container, allowing it to create TUN/TAP devices.Capabilities: The
NET_ADMINcapability is added to the container, allowing it to configure network interfaces.Networks: The service is connected to the
maiko-localnetwork.
2. backend
Build: The service is built from the
backenddirectory using theDockerfile.backendfile.Restart: The container will always restart if it stops.
Environment: Environment variables are loaded from the
./backend/.envfile.Ports: Port
3003on the host is mapped to port3003on the container.Networks: The service is connected to the
maiko-localnetwork.Memory Limits: The container has a maximum memory limit of 4GB and a soft memory limit of 2GB.
3. mongo
Image: The service uses the latest MongoDB image.
Restart: The container will always restart if it stops.
Environment: The MongoDB root user and password are set using environment variables.
Volumes: Data is persisted in the
mongo_datavolume.Ports: Port
27017on the host is mapped to port27017on the container.Networks: The service is connected to the
maiko-localnetwork.Command: The MongoDB server binds to all available network interfaces.
4. chromadb
Image: The service uses the latest ChromaDB image.
Restart: The container will always restart if it stops.
Ports: Port
8000on the host is mapped to port8000on the container.Volumes: Data is persisted in the
chromadbvolume.Environment: The
PERSIST_DIRECTORYandIS_PERSISTENTenvironment variables are set.Networks: The service is connected to the
maiko-localnetwork.
5. main
Image: The service uses the
microhealthllc/flowfusion:v7image.Restart: The container will always restart if it stops.
Depends On: The service depends on the
postgresandredisservices.Environment: Environment variables are loaded from the
.env.localfile.Ports: Port
3002on the host is mapped to port3002on the container.Environment: The
PORTenvironment variable is set to3002.Networks: The service is connected to the
maiko-localnetwork.
6. worker
Image: The service uses the
microhealthllc/flowfusion:v7image.Restart: The container will always restart if it stops.
Depends On: The service depends on the
mainservice.Environment: Environment variables are loaded from the
.env.localfile.Environment: The
WORKERenvironment variable is set totrue.Networks: The service is connected to the
maiko-localnetwork.
7. postgres
Image: The service uses the
postgres:14.5image.Restart: The container will always restart if it stops.
Environment: The PostgreSQL database name, user, and password are set using environment variables.
Volumes: Data is persisted in the
postgres_datavolume.Networks: The service is connected to the
maiko-localnetwork.Healthcheck: A healthcheck is configured to ensure the PostgreSQL server is ready.
8. redis
Image: The service uses the latest Redis image.
Restart: The container will always restart if it stops.
Networks: The service is connected to the
maiko-localnetwork.Ports: Port
6379on the host is mapped to port6379on the container.Memory Limits: The container has a maximum memory limit of 6GB and a soft memory limit of 4GB.
Networks
maiko-local: A custom network is defined to facilitate communication between the services.
Volumes
mongo_data: A named volume for persisting MongoDB data.
chromadb: A named volume for persisting ChromaDB data.
automatisch_storage: A named volume for additional storage (not used in the current configuration).
postgres_data: A named volume for persisting PostgreSQL data.
redis_data: A named volume for persisting Redis data.
This configuration ensures that all services are properly set up and can communicate with each other through the maiko-local network, with data persistence provided by the named volumes.
Last updated