-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy path.env.example
More file actions
195 lines (159 loc) · 6.1 KB
/
.env.example
File metadata and controls
195 lines (159 loc) · 6.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
# ⚠️ DO NOT COMMIT THIS FILE WITH REAL CREDENTIALS
# This is a template - copy to .env and customize
# The .env file is in .gitignore and will not be committed
# OBP-Rabbit-Cats-Adapter Configuration Example
# Copy this file to .env and customize for your environment
# ============================================================================
# RABBITMQ CONFIGURATION
# ============================================================================
# Connection details for RabbitMQ message broker
RABBITMQ_HOST=localhost
RABBITMQ_PORT=5672
RABBITMQ_VIRTUAL_HOST=/
RABBITMQ_USERNAME=guest
RABBITMQ_PASSWORD=guest
# Queue names (must match OBP-API configuration)
RABBITMQ_REQUEST_QUEUE=obp.request
RABBITMQ_RESPONSE_QUEUE=obp.response
# Performance tuning
RABBITMQ_PREFETCH_COUNT=10
RABBITMQ_CONNECTION_TIMEOUT=30
RABBITMQ_HEARTBEAT=60
RABBITMQ_AUTOMATIC_RECOVERY=true
RABBITMQ_QUEUE_DURABLE=true
RABBITMQ_QUEUE_AUTO_DELETE=false
# ============================================================================
# CORE BANKING SYSTEM (CBS) CONFIGURATION
# ============================================================================
# YOUR BANK-SPECIFIC SETTINGS - Configure these for your CBS
# Base URL of your CBS API
CBS_BASE_URL=https://your-cbs-api.bank.com/api/v1
# Authentication type: none, basic, bearer, custom
CBS_AUTH_TYPE=bearer
# Basic Authentication (if CBS_AUTH_TYPE=basic)
# CBS_USERNAME=your-username
# CBS_PASSWORD=your-password
# Bearer Token Authentication (if CBS_AUTH_TYPE=bearer)
CBS_BEARER_TOKEN=your-api-token-here
# Custom Headers (if CBS_AUTH_TYPE=custom)
# Format: key1:value1,key2:value2
# CBS_CUSTOM_HEADERS=X-API-Key:secret123,X-Client-ID:client456
# SOAP Configuration (if using SOAP local adapter)
# CBS_SOAP_ENDPOINT=https://your-cbs.bank.com/soap/v1
# Performance and reliability
CBS_TIMEOUT=30
CBS_MAX_RETRIES=3
CBS_RETRY_DELAY=1
# ============================================================================
# TELEMETRY & OBSERVABILITY CONFIGURATION
# ============================================================================
# Choose telemetry implementation: console, prometheus, datadog, noop
# Telemetry type
TELEMETRY_TYPE=console
# Enable/disable metrics collection
ENABLE_METRICS=true
# Logging configuration
LOG_LEVEL=INFO
# Prometheus configuration (if TELEMETRY_TYPE=prometheus)
# PROMETHEUS_PORT=9090
# PROMETHEUS_HOST=0.0.0.0
# Datadog configuration (if TELEMETRY_TYPE=datadog)
# DATADOG_API_KEY=your-datadog-api-key
# DATADOG_APP_KEY=your-datadog-app-key
# DATADOG_SITE=datadoghq.com
# ============================================================================
# HTTP / DISCOVERY PAGE CONFIGURATION
# ============================================================================
HTTP_HOST=0.0.0.0
HTTP_PORT=52345
HTTP_ENABLED=true
# OBP API Explorer URL (for discovery page links)
API_EXPLORER_URL=http://localhost:5173
# OBP API URL (for discovery page links)
OBP_API_URL=http://localhost:8080
# ============================================================================
# ADAPTER CONFIGURATION
# ============================================================================
# Local Adapter Implementation
# Options: mock, rest, soap, yourbank
LOCAL_ADAPTER_TYPE=mock
# Application name (for logging/metrics)
APP_NAME=OBP-Rabbit-Cats-Adapter
# Application version
APP_VERSION=1.0.0
# Environment (dev, staging, production)
ENVIRONMENT=dev
# ============================================================================
# SEPARATION OF CONCERNS - QUICK REFERENCE
# ============================================================================
#
# GENERIC CODE (DON'T MODIFY):
# - RabbitMQ message handling
# - OBP protocol parsing
# - Message routing
# - Response building
#
# YOUR CODE (CBS-SPECIFIC):
# - LocalAdapter implementation
# - CBS API calls
# - Data mapping
# - Error handling
#
# CONFIGURE HERE:
# - All the settings above
# - CBS connection details
# - Authentication credentials
# - Telemetry backend choice
#
# ============================================================================
# ============================================================================
# EXAMPLES FOR DIFFERENT SCENARIOS
# ============================================================================
# Example 1: REST CBS with Basic Auth
# CBS_BASE_URL=https://cbs.mybank.com/api
# CBS_AUTH_TYPE=basic
# CBS_USERNAME=adapter-user
# CBS_PASSWORD=secure-password
# TELEMETRY_TYPE=console
# Example 2: REST CBS with Bearer Token (Production)
# CBS_BASE_URL=https://cbs.prod.mybank.com/api/v2
# CBS_AUTH_TYPE=bearer
# CBS_BEARER_TOKEN=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
# TELEMETRY_TYPE=prometheus
# ENVIRONMENT=production
# LOG_LEVEL=WARN
# Example 3: SOAP CBS with Custom Headers
# CBS_BASE_URL=https://cbs.mybank.com
# CBS_SOAP_ENDPOINT=https://cbs.mybank.com/soap/BankingService
# CBS_AUTH_TYPE=custom
# CBS_CUSTOM_HEADERS=SOAPAction:urn:getBankInfo,X-API-Key:abc123
# TELEMETRY_TYPE=datadog
# Example 4: Development with Mock CBS
# LOCAL_ADAPTER_TYPE=mock
# TELEMETRY_TYPE=console
# LOG_LEVEL=DEBUG
# ENVIRONMENT=dev
# ============================================================================
# SECURITY NOTES
# ============================================================================
#
# 1. Never commit this file with real credentials to version control
# 2. Use secrets management in production (Kubernetes secrets, Vault, etc.)
# 3. Rotate credentials regularly
# 4. Use least-privilege principle for CBS API access
# 5. Enable HTTPS for all external connections
# 6. Monitor failed authentication attempts
#
# ============================================================================-e
# ============================================================================
# GRPC CONFIGURATION
# ============================================================================
# gRPC transport (alternative to RabbitMQ for OBP-API communication)
GRPC_ENABLED=false
GRPC_PORT=50051
# ============================================================================
# REDIS CONFIGURATION
# ============================================================================
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_ENABLED=true