All checks were successful
ci/woodpecker/push/billing_fees Pipeline was successful
ci/woodpecker/push/billing_documents Pipeline was successful
ci/woodpecker/push/bff Pipeline was successful
ci/woodpecker/push/db Pipeline was successful
ci/woodpecker/push/discovery Pipeline was successful
ci/woodpecker/push/fx_ingestor Pipeline was successful
ci/woodpecker/push/frontend Pipeline was successful
ci/woodpecker/push/fx_oracle Pipeline was successful
ci/woodpecker/push/gateway_mntx Pipeline was successful
ci/woodpecker/push/gateway_chain Pipeline was successful
ci/woodpecker/push/gateway_tgsettle Pipeline was successful
ci/woodpecker/push/gateway_tron Pipeline was successful
ci/woodpecker/push/nats Pipeline was successful
ci/woodpecker/push/ledger Pipeline was successful
ci/woodpecker/push/notification Pipeline was successful
ci/woodpecker/push/payments_methods Pipeline was successful
ci/woodpecker/push/payments_orchestrator Pipeline was successful
ci/woodpecker/push/payments_quotation Pipeline was successful
[infra][rebuild]Reviewed-on: #554
Sendico Development Environment
Docker Compose + Makefile build system for local development.
Architecture
Infrastructure:
- MongoDB replica set (3 nodes) - credentials in
.env.dev - NATS with JetStream - credentials in
.env.dev - Vault (single node) - for application data ONLY (blockchain keys, external API keys)
Services:
- Discovery, Ledger, Billing Fees, Billing Documents, FX Oracle, Payments Orchestrator
- Chain Gateway, MNTX Gateway, TGSettle Gateway
- FX Ingestor, Notification, BFF (Server), Frontend
Quick Start
# 1. Initialize environment (first time)
make init
# 2. Start all services
make up
# 3. Initialize Vault (if services need it for application data)
make vault-init
# 4. View logs
make logs SERVICE=ledger
# 5. Stop everything
make down
Credentials
All in .env.dev (plaintext for dev):
- MongoDB:
dev_root/dev_password_123 - NATS:
dev_nats/nats_password_123 - Vault: Run
make vault-initto get root token
Common Commands
make build # Build all images
make up # Start environment
make down # Stop environment
make logs SERVICE=ledger # View service logs
make rebuild SERVICE=ledger # Rebuild specific service
make proto # Regenerate protobuf
make clean # Remove everything
make status # Check service status
Vault Usage
Vault is ONLY for application data, not infrastructure secrets!
Examples:
- Blockchain private keys (Chain Gateway)
- External API keys (MNTX, TGSettle)
- Production-like secrets
Infrastructure (MongoDB, NATS) uses plain .env.dev credentials.
Network
All services on sendico-dev network. Vault also on cicd network to connect to infra Vault if needed.
Rebuilding Services
After code changes:
# Rebuild specific service
make rebuild SERVICE=ledger
# Or manually
docker compose -f docker-compose.dev.yml build ledger
docker compose -f docker-compose.dev.yml up -d --force-recreate ledger
Adding New Services
- Create Dockerfile:
ci/dev/yourservice.dockerfile - Add service to
docker-compose.dev.yml - Use environment variables from
.env.dev - Connect to
sendico-devnetwork
Troubleshooting
MongoDB replica set not initializing:
make down
make up
# Wait for health checks, then:
docker logs dev-mongo-init
Vault sealed:
make vault-init
# Save the unseal key and root token from vault-keys.txt
Service can't connect to MongoDB:
- Check replica set:
docker exec -it dev-mongo-1 mongosh -u dev_root -p dev_password_123 --eval "rs.status()" - Ensure
dev-mongo-initcompleted:docker ps -a | grep init
Proto generation errors:
make proto
# Check output for missing dependencies
Files
docker-compose.dev.yml- All services.env.dev- Plaintext credentialsMakefile- Build commandsci/dev/*.dockerfile- Service buildsci/dev/mongo.key- MongoDB replica set keyci/dev/vault/config.hcl- Vault config