From 5a4ee215617269e4847ea2dd6c254659d384accb Mon Sep 17 00:00:00 2001 From: Thomas Maurice Date: Mon, 12 Feb 2024 17:31:12 +0100 Subject: [PATCH] fix(config): add the option of a default provider --- mailout.yml.sample | 1 + pkg/config/config.go | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/mailout.yml.sample b/mailout.yml.sample index ecf81f0..038cb20 100644 --- a/mailout.yml.sample +++ b/mailout.yml.sample @@ -5,6 +5,7 @@ postgres: user: postgres password: postgres123 sslmode: disable +defaultProvider: ovh providers: ovh: application_key: diff --git a/pkg/config/config.go b/pkg/config/config.go index f8e864a..15811e8 100644 --- a/pkg/config/config.go +++ b/pkg/config/config.go @@ -16,7 +16,8 @@ type Config struct { Database string `yaml:"database"` SSLMode string `yaml:"sslmode"` } `yaml:"postgres"` - Providers struct { + DefaultProvider string `yaml:"defaultProvider"` + Providers struct { OVH *providerConfigs.OVHConfig `yaml:"ovh"` } `yaml:"providers"` }