Make corredor calls more configurable

JWT is now sent as part of the Config prop, along with msg/sys/cmp base api URLs

This still needs to be configured through env:
 - CORREDOR_API_BASE_URL_SYSTEM
 - CORREDOR_API_BASE_URL_MESSAGING
 - CORREDOR_API_BASE_URL_COMPOSE
This commit is contained in:
Denis Arh
2019-08-24 12:21:42 +02:00
parent 2b3f196e60
commit f3ee556b3f
4 changed files with 98 additions and 62 deletions
+5 -1
View File
@@ -15,7 +15,11 @@ type (
Log bool `env:"CORREDOR_LOG_ENABLED"`
MaxBackoffDelay time.Duration `env:"CORREDOR_MAX_BACKOFF_DELAY"`
Log bool `env:"CORREDOR_LOG_ENABLED"`
// @todo do autodiscovery & prefill these with values we know
ApiBaseURLSystem string `env:"CORREDOR_API_BASE_URL_SYSTEM"`
ApiBaseURLMessaging string `env:"CORREDOR_API_BASE_URL_MESSAGING"`
ApiBaseURLCompose string `env:"CORREDOR_API_BASE_URL_COMPOSE"`
}
)