Commit 2168f3cc authored by Nogweii's avatar Nogweii
Browse files

pushover configuration

parent 8597838d
......@@ -6,6 +6,7 @@ require (
github.com/CaliDog/certstream-go v0.0.0-20200713031452-eca7997412f1
github.com/gobwas/glob v0.2.3
github.com/gorilla/websocket v1.4.2 // indirect
github.com/gregdel/pushover v1.1.0 // indirect
github.com/jmoiron/jsonq v0.0.0-20150511023944-e874b168d07e // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/sirupsen/logrus v1.8.1
......
......@@ -8,12 +8,16 @@ import (
type Configuration struct {
DomainsListPath string
PushoverAppToken string
PushoverUserKey string
}
var configuration Configuration
func readConfig() {
configuration.DomainsListPath = requireEnvVar("DOMAINS_LIST_PATH")
configuration.PushoverAppToken = requireEnvVar("PUSHOVER_APP_TOKEN")
configuration.PushoverUserKey = requireEnvVar("PUSHOVER_USER_KEY")
}
func requireEnvVar(envName string) string {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment