5.5 KiB
5.5 KiB
Architecture des Flux et Services - LeCoffre Node
Tableau des Services - IP/Domaines et Ports
🏠 Services Locaux (Docker Compose)
Service | Container | Port Local | Port Interne | Protocole | URL d'accès |
---|---|---|---|---|---|
tor | tor-proxy | - | 9050 | TCP | Réseau interne uniquement |
bitcoin | bitcoin-signet | - | 38332 (RPC) 38333 (P2P) 29000 (ZMQ hash) 29001 (ZMQ rawtx) |
TCP | Réseau interne uniquement |
blindbit | blindbit-oracle | 0.0.0.0:8000 | 8000 | HTTP | http://0.0.0.0:8000 |
sdk_relay | sdk_relay | 0.0.0.0:8090 0.0.0.0:8091 |
8090 (WS) 8091 (HTTP) |
WebSocket/HTTP | ws://0.0.0.0:8090 http://0.0.0.0:8091 |
lecoffre-back | lecoffre-back | 0.0.0.0:8080 | 8080 | HTTP | http://0.0.0.0:8080 |
lecoffre-front | lecoffre-front | 127.0.0.2:3004 | 3000 | HTTP | http://127.0.0.2:3004 |
ihm_client | ihm_client | 0.0.0.0:3003 | 3003 | HTTP | http://0.0.0.0:3003 |
sdk_signer | sdk_signer | 0.0.0.0:3001 | 3001 | HTTP/WebSocket | http://0.0.0.0:3001 |
sdk_storage | sdk_storage | 0.0.0.0:8081 | 8080 | HTTP | http://0.0.0.0:8081 |
🌐 Services Externes
Service | Domaine | Port | Protocole | URL d'accès | Statut |
---|---|---|---|---|---|
Bootstrap Relay | dev3.4nkweb.com | 443 | WSS | wss://dev3.4nkweb.com/ws/ | ✅ Actif |
Signer Externe | dev3.4nkweb.com | 9090 | WS | ws://dev3.4nkweb.com:9090 | ✅ Actif |
Signer Base | dev3.4nkweb.com | 443 | HTTPS | https://dev3.4nkweb.com | ✅ Actif |
Mempool | mempool2.4nkweb.com | 443 | HTTPS | https://mempool2.4nkweb.com | ✅ Actif |
Storage | dev4.4nkweb.com | 443 | HTTPS | https://dev4.4nkweb.com/storage | ✅ Actif |
🔄 Proxy Nginx (dev4.4nkweb.com)
Route | Destination | Port | Protocole | Description |
---|---|---|---|---|
/ | ihm_client | 3003 | HTTP | Interface principale |
/lecoffre | lecoffre-front | 3004 | HTTP | Application LeCoffre |
/api/ | lecoffre-back | 8080 | HTTP | API Backend |
/back/ | lecoffre-back | 8080 | HTTP | API Backend (alias) |
/ws/ | sdk_relay | 8090 | WebSocket | Relay WebSocket |
/signer/ | sdk_signer | 3001 | HTTP/WebSocket | Service Signer |
/src/service-workers/ | ihm_client | 3003 | HTTP | Service Workers |
🏠 Proxy Nginx Local (local.4nkweb.com)
Route | Destination | Port | Protocole | Description |
---|---|---|---|---|
/ | Redirection | 3000 | HTTP | Redirige vers port 3000 |
/lecoffre/ | lecoffre-front | 3004 | HTTP | Application LeCoffre local |
🔧 Configuration Bitcoin Signet
Service | Port | Protocole | Description |
---|---|---|---|
RPC | 38332 | TCP | Interface RPC Bitcoin |
P2P | 38333 | TCP | Réseau peer-to-peer |
ZMQ Hash | 29000 | TCP | Notifications de blocs |
ZMQ RawTx | 29001 | TCP | Notifications de transactions |
Tor | 9050 | TCP | Proxy Tor |
🌐 Réseau Docker
Réseau | Subnet | Driver | Services |
---|---|---|---|
btcnet | 172.20.0.0/16 | bridge | Tous les services |
🔗 Variables d'Environnement Clés
Variable | Valeur | Service |
---|---|---|
VITE_BOOTSTRAPURL | wss://dev4.4nkweb.com/ws/ | ihm_client |
SIGNER_WS_URL | ws://dev3.4nkweb.com:9090 | sdk_signer |
SIGNER_BASE_URL | https://dev3.4nkweb.com | sdk_signer |
RELAY_URLS | wss://dev4.4nkweb.com/ws/,wss://dev3.4nkweb.com/ws/ | sdk_signer |
bootstrap_url | wss://dev3.4nkweb.com/ws/ | sdk_relay |
storage | https://dev4.4nkweb.com/storage | sdk_relay |
Flux d'Architecture
🔄 Flux Principal
Internet → dev4.4nkweb.com (Nginx) → Services Locaux
- Frontend :
https://dev4.4nkweb.com/lecoffre
→ lecoffre-front (127.0.0.2:3004) - API :
https://dev4.4nkweb.com/api/
→ lecoffre-back (0.0.0.0:8080) - IHM :
https://dev4.4nkweb.com/
→ ihm_client (0.0.0.0:3003) - WebSocket :
https://dev4.4nkweb.com/ws/
→ sdk_relay (0.0.0.0:8090)
🔗 Flux de Redirection
local.4nkdev.com → local.4nkweb.com → https://dev4.4nkweb.com/lecoffre
🌐 Flux Externes
- Bootstrap :
wss://dev3.4nkweb.com/ws/
(Relay externe) - Signer :
ws://dev3.4nkweb.com:9090
(Actuellement inactif) - Mempool :
https://mempool2.4nkweb.com
(Réseau Bitcoin Signet)
⚠️ Points d'Attention
- dev3.4nkweb.com:9090 - Service signer externe actuellement inactif
- dev3.4nkweb.com - Retourne 502 Bad Gateway (services backend indisponibles)
- Ports 0.0.0.0 - Services locaux uniquement accessibles depuis la machine
- Ports 127.0.0.2 - lecoffre-front sur interface séparée
📋 Ordre de Démarrage des Services
Selon les règles du projet, l'ordre de démarrage est :
- tor - Proxy anonyme
- bitcoin - Nœud Bitcoin Signet
- blindbit - Oracle Bitcoin
- sdk_storage - Stockage temporaire
- sdk_relay - Relais des transactions
- sdk_signer - Signature des processus
- ihm_client - Interface utilisateur
🔧 Configuration Critique
- Mempool du réseau signet :
https://mempool2.4nkweb.com/fr/docs/api/rest
- Test de connectivité Bitcoin :
docker exec bitcoin-signet bitcoin-cli -signet -rpccookiefile=/home/bitcoin/.bitcoin/signet/.cookie getblockchaininfo
- Test WebSocket Bootstrap :
wss://dev3.4nkweb.com/ws/