diff --git a/README.md b/README.md index f15ef8d4..09b96373 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,88 @@ -# ServiceManager - + +# ServiceManager + +Monitoring your services from different machine on a same place. + + + +## Installation + +docker-compose.yaml + +```YAML +services: + migrate: + image: migrate/migrate + volumes: + # Attention : assure-toi que le dossier migrations est présent sur ton serveur + - ./migrations:/migrations + networks: + - app-net + command: -path=/migrations/ -database "postgres://admin:admin@db:5432/monitoring?sslmode=disable" up + depends_on: + db: + condition: service_healthy + + backend: + image: gitea.anthonybouteiller.ovh/blomios/servicemanager-backend:latest + container_name: sm-api + networks: + - app-net + depends_on: + migrate: + condition: service_completed_successfully + # On expose les ports si nécessaire, sinon Nginx s'en occupe via le réseau interne + expose: + - "8080" + + frontend: + image: gitea.anthonybouteiller.ovh/blomios/servicemanager-frontend:latest + container_name: sm-ui + networks: + - app-net + depends_on: + - backend + expose: + - "3000" + + db: + image: postgres:16-alpine + container_name: db + environment: + POSTGRES_USER: admin + POSTGRES_PASSWORD: admin + POSTGRES_DB: monitoring + ports: + - "5432:5432" + volumes: + - db-data:/var/lib/postgresql/data + networks: + - app-net + healthcheck: + test: ["CMD-SHELL", "pg_isready -U admin -d monitoring"] + interval: 5s + timeout: 5s + retries: 5 + + nginx: + image: nginx:alpine + container_name: monitor-proxy + ports: + - "8082:80" + - "444:443" + volumes: + - ./nginx.conf:/etc/nginx/nginx.conf:ro + depends_on: + - frontend + - backend + networks: + - app-net + +networks: + app-net: + driver: bridge + +volumes: + db-data: +``` + \ No newline at end of file