diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4d4400e --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +milkwatch-server \ No newline at end of file diff --git a/main.go b/main.go index 4bd2e34..820a048 100644 --- a/main.go +++ b/main.go @@ -13,6 +13,8 @@ import ( const yourDomain string = "sandbox403bedf0d09d4e539131fabf0ab7c11f.mailgun.org" // e.g. mg.yourcompany.com const privateAPIKey string = "key-2b58bc1193c549df83d8d5ed54e1c982" +const host = "rodberrypi" + func main() { for { log.Println("Checking Fridge") @@ -27,8 +29,7 @@ func main() { } func endPointAlive() bool { - - res, err := http.Get("http://localhost:2122/heartbeat") + res, err := http.Get("http://"+host+":2122/heartbeat") if err != nil { log.Println(err) return false