Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/biglogic/consule-auto-discovery
https://github.com/biglogic/consule-auto-discovery
Last synced: 2 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/biglogic/consule-auto-discovery
- Owner: biglogic
- Created: 2024-12-17T17:01:16.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2025-01-23T15:06:32.000Z (5 days ago)
- Last Synced: 2025-01-23T16:22:43.746Z (5 days ago)
- Language: HCL
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: ReadME.md
Awesome Lists containing this project
README
# Docker-Compose Console with Auto Service Discovery via Registrator 🐳
This repository demonstrates how to set up a Docker Compose Console with automatic service discovery using Registrator. Registrator dynamically discovers and registers container services to a service discovery backend (e.g., Consul) as soon as they become online.
### 🛠 Features
- Automated Service Discovery: Registrator detects running containers and automatically registers them with their IP addresses.
- Plug-and-Play Setup: No manual configuration needed for service registration.
- Simplified Orchestration: A single docker-compose.yml file manages the entire stack.
### Docker compose Up
Just clone the repo and run
```
docker-compose up -d
```# Run a registrator container
### 📜 Command Explanation
The following command runs the Registrator container in Docker. Its purpose is to listen for Docker events, such as containers starting and stopping, and automatically register or deregister services in Consul based on the container's metadata.
```
$ docker run -d \
--name=registrator \
--net=host \
--volume=/var/run/docker.sock:/tmp/docker.sock \
gliderlabs/registrator:latest \
consul://localhost:8500
```