Overview
Argos Mesh uses environment variables to configure all microservices. This approach provides flexibility for different deployment environments (development, staging, production) without modifying application code.Orders Service
The Orders service is the main application that handles product management and sales transactions.Database Configuration
PostgreSQL database connection URLDefault:
jdbc:postgresql://db:5432/shop_dbExample:Database authentication usernameDefault:
user_shopDatabase authentication passwordDefault:
secretPasswordRabbitMQ Configuration
RabbitMQ message broker hostnameDefault:
message_brokerExample:RabbitMQ AMQP portDefault:
5672RabbitMQ authentication usernameDefault:
adminRabbitMQ authentication passwordDefault:
admin123Redis Configuration
Redis server hostnameDefault:
redis_dbRedis server portDefault:
6379Sentinel Service
The Sentinel service monitors traffic, detects suspicious patterns, and manages IP blacklisting.RabbitMQ Configuration
RabbitMQ message broker hostnameDefault:
message_brokerRabbitMQ AMQP portDefault:
5672RabbitMQ authentication usernameDefault:
adminRabbitMQ authentication passwordDefault:
admin123Redis Configuration
Redis server hostname for IP blacklisting and rate limitingDefault:
redis_dbRedis server portDefault:
6379Virtual Threads
Enable Java virtual threads for improved concurrencyDefault:
trueVirtual threads improve performance when handling many concurrent connections. Requires Java 21+.
Notify Service
The Notify service handles alert notifications sent through RabbitMQ.RabbitMQ Configuration
RabbitMQ message broker hostnameDefault:
message_brokerRabbitMQ AMQP portDefault:
5672RabbitMQ authentication usernameDefault:
adminRabbitMQ authentication passwordDefault:
admin123Docker Compose Configuration
When running Argos Mesh with Docker Compose, environment variables are defined in thedocker-compose.yml file:
Configuration Best Practices
Security Considerations
Security Considerations
- Never commit credentials to version control
- Use environment-specific
.envfiles - Change all default passwords in production
- Use secrets management tools (AWS Secrets Manager, HashiCorp Vault, etc.)
- Rotate credentials regularly
Service Dependencies
Service Dependencies
- Ensure database is healthy before starting the Orders service
- Sentinel requires both Redis and RabbitMQ to be available
- Use Docker health checks to manage startup order
- Configure appropriate restart policies (
on-failure,always)
Development vs Production
Development vs Production
- Use
localhosthostnames for local development - Use service names for Docker Compose (e.g.,
message_broker,redis_db) - Use fully qualified domain names in production
- Consider using external managed services (Amazon RDS, Amazon MQ, Amazon ElastiCache)
Environment File Example
Create a.env file for local development:
.env
Reference this file in your Docker Compose with
env_file: .env or load it in your IDE configuration.