Removing autostart from configuration
This commit is contained in:
parent
b42701e4ef
commit
a9a55719aa
@ -33,7 +33,6 @@ type Proxy struct {
|
||||
|
||||
// Settings - Configuration file structure
|
||||
type Settings struct {
|
||||
Autostart []string `"json:autostart"`
|
||||
Crawl bool `"json:crawl"`
|
||||
Banned []string `"json:banned"`
|
||||
Alwaysbot []string `"json:alwaysbot"`
|
||||
|
@ -4,16 +4,6 @@
|
||||
* https://github.com/neoclide/jsonc.vim
|
||||
*/
|
||||
{
|
||||
/*
|
||||
* Automatically start following the following instances's public timeline
|
||||
* If an external account with the same endpoint exists, the autostart
|
||||
* will use the authenticated to follow
|
||||
*/
|
||||
"autostart": [
|
||||
"mastodon.social",
|
||||
"pleroma.site"
|
||||
],
|
||||
|
||||
// Should pollers automatically crawl
|
||||
"crawl": true,
|
||||
|
||||
|
@ -95,20 +95,12 @@ func main() {
|
||||
var endpoint string
|
||||
err = rows.Scan(&endpoint)
|
||||
if err != nil {
|
||||
logErr("Unable to iterate")
|
||||
logErr("Unable to iterate database, exiting.")
|
||||
return
|
||||
}
|
||||
_, exists := GetRunner(endpoint)
|
||||
if exists == false {
|
||||
go StartInstance(endpoint)
|
||||
}
|
||||
}
|
||||
|
||||
// Start from Autostart list
|
||||
for _, endpoint := range settings.Autostart {
|
||||
logInfo("Autostarting " + endpoint)
|
||||
_, exists := GetRunner(endpoint)
|
||||
if exists == false {
|
||||
go StartInstance(endpoint)
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user