Documentation
¶
Overview ¶
Package config provides functions to read in various configuration files into definded types. This includes the main configuration file specifying all details about the distributed setup of pluto.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthFile ¶
AuthFile provides information on authenticating user taken from a designated authorization text file.
type AuthPostgres ¶ added in v0.1.6
type AuthPostgres struct {
IP string
Port uint16
Database string
User string
Password string
UseTLS bool
}
AuthPostgres defines parameters for connecting to a Postgres database for authenticating users.
type Config ¶
type Config struct {
RootCertLoc string
IntlConnTimeout int
IntlConnRetry int
IMAP IMAP
Distributor Distributor
Workers map[string]Worker
Storage Storage
}
Config holds all information parsed from supplied config file.
func LoadConfig ¶
LoadConfig takes in the path to the main config file of pluto in TOML syntax and places the values from the file in the corresponding struct.
type Distributor ¶
type Distributor struct {
IP string
Port string
AuthAdapter string
PublicTLS TLS
InternalTLS TLS
AuthFile *AuthFile
AuthPostgres *AuthPostgres
}
Distributor describes the configuration of the first entry point of a pluto setup, the IMAP request authenticator and distributor.
type Storage ¶
type Storage struct {
IP string
MailPort string
SyncPort string
MaildirRoot string
CRDTLayerRoot string
TLS TLS
}
Storage configures the global database node storing all user data in a very safe manner.