mirror of
https://github.com/bitvora/wot-relay.git
synced 2025-06-06 18:31:05 +00:00
Update main.go to support icon and rename contact
This commit is contained in:
parent
d291251887
commit
0ce65fb549
9
main.go
9
main.go
@ -33,7 +33,8 @@ type Config struct {
|
|||||||
RefreshInterval int
|
RefreshInterval int
|
||||||
MinimumFollowers int
|
MinimumFollowers int
|
||||||
ArchivalSync bool
|
ArchivalSync bool
|
||||||
Contact string
|
RelayContact string
|
||||||
|
RelayIcon string
|
||||||
}
|
}
|
||||||
|
|
||||||
var pool *nostr.SimplePool
|
var pool *nostr.SimplePool
|
||||||
@ -78,7 +79,8 @@ func main() {
|
|||||||
|
|
||||||
relay.Info.Name = config.RelayName
|
relay.Info.Name = config.RelayName
|
||||||
relay.Info.PubKey = config.RelayPubkey
|
relay.Info.PubKey = config.RelayPubkey
|
||||||
relay.Info.Contact = config.Contact
|
relay.Info.Icon = config.RelayIcon
|
||||||
|
relay.Info.Contact = config.RelayContact
|
||||||
relay.Info.Description = config.RelayDescription
|
relay.Info.Description = config.RelayDescription
|
||||||
relay.Info.Software = "WoT Relay"
|
relay.Info.Software = "WoT Relay"
|
||||||
relay.Info.Version = version
|
relay.Info.Version = version
|
||||||
@ -192,6 +194,8 @@ func LoadConfig() Config {
|
|||||||
RelayName: getEnv("RELAY_NAME"),
|
RelayName: getEnv("RELAY_NAME"),
|
||||||
RelayPubkey: getEnv("RELAY_PUBKEY"),
|
RelayPubkey: getEnv("RELAY_PUBKEY"),
|
||||||
RelayDescription: getEnv("RELAY_DESCRIPTION"),
|
RelayDescription: getEnv("RELAY_DESCRIPTION"),
|
||||||
|
RelayContact: getEnv("RELAY_CONTACT"),
|
||||||
|
RelayIcon: getEnv("RELAY_ICON"),
|
||||||
DBPath: getEnv("DB_PATH"),
|
DBPath: getEnv("DB_PATH"),
|
||||||
RelayURL: getEnv("RELAY_URL"),
|
RelayURL: getEnv("RELAY_URL"),
|
||||||
IndexPath: getEnv("INDEX_PATH"),
|
IndexPath: getEnv("INDEX_PATH"),
|
||||||
@ -199,7 +203,6 @@ func LoadConfig() Config {
|
|||||||
RefreshInterval: refreshInterval,
|
RefreshInterval: refreshInterval,
|
||||||
MinimumFollowers: minimumFollowers,
|
MinimumFollowers: minimumFollowers,
|
||||||
ArchivalSync: getEnv("ARCHIVAL_SYNC") == "TRUE",
|
ArchivalSync: getEnv("ARCHIVAL_SYNC") == "TRUE",
|
||||||
Contact: getEnv("CONTACT"),
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return config
|
return config
|
||||||
|
Loading…
x
Reference in New Issue
Block a user