diff options
author | Neil Alexander <neilalexander@users.noreply.github.com> | 2020-12-02 17:41:00 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-02 17:41:00 +0000 |
commit | b5aa7ca3ab1c91397700637c91d60860a0535f1e (patch) | |
tree | 9da277c7b22027f09a7f45b0b0d771e44949e8f0 /internal/config/config_keyserver.go | |
parent | 3ef6187e96ca2d68b3014bbd150e69971b6f7800 (diff) |
Top-level setup package (#1605)
* Move config, setup, mscs into "setup" top-level folder
* oops, forgot the EDU server
* Add setup
* goimports
Diffstat (limited to 'internal/config/config_keyserver.go')
-rw-r--r-- | internal/config/config_keyserver.go | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/internal/config/config_keyserver.go b/internal/config/config_keyserver.go deleted file mode 100644 index 89162300..00000000 --- a/internal/config/config_keyserver.go +++ /dev/null @@ -1,22 +0,0 @@ -package config - -type KeyServer struct { - Matrix *Global `yaml:"-"` - - InternalAPI InternalAPIOptions `yaml:"internal_api"` - - Database DatabaseOptions `yaml:"database"` -} - -func (c *KeyServer) Defaults() { - c.InternalAPI.Listen = "http://localhost:7779" - c.InternalAPI.Connect = "http://localhost:7779" - c.Database.Defaults() - c.Database.ConnectionString = "file:keyserver.db" -} - -func (c *KeyServer) Verify(configErrs *ConfigErrors, isMonolith bool) { - checkURL(configErrs, "key_server.internal_api.listen", string(c.InternalAPI.Listen)) - checkURL(configErrs, "key_server.internal_api.bind", string(c.InternalAPI.Connect)) - checkNotEmpty(configErrs, "key_server.database.connection_string", string(c.Database.ConnectionString)) -} |