Add SOCKS5 proxy support to bot
In Soviet Russia... wait, wrong time period.
This commit is contained in:
@@ -30,6 +30,14 @@ type TelegramConnection struct {
|
||||
ListenAddress string `yaml:"listen_address"`
|
||||
}
|
||||
|
||||
// ProxySettings handles settings for SOCKS5 proxy in config.yml
|
||||
type ProxySettings struct {
|
||||
Enabled bool `yaml:"enabled"`
|
||||
Address string `yaml:"address,omitempty"`
|
||||
Username string `yaml:"username,omitempty"`
|
||||
Password string `yaml:"password,omitempty"`
|
||||
}
|
||||
|
||||
// SpecialChats handles settings for special chats
|
||||
type SpecialChats struct {
|
||||
AcademyID string `yaml:"academy_id"`
|
||||
@@ -48,6 +56,7 @@ type LoggingConfig struct {
|
||||
type Config struct {
|
||||
Telegram TelegramConnection `yaml:"telegram_connection"`
|
||||
Database DatabaseConnection `yaml:"database_connection"`
|
||||
Proxy ProxySettings `yaml:"socks_proxy"`
|
||||
SpecialChats SpecialChats `yaml:"special_chats"`
|
||||
Logs LoggingConfig `yaml:"logs"`
|
||||
}
|
||||
|
Reference in New Issue
Block a user