mirror of
https://github.com/httpjamesm/AnonymousOverflow.git
synced 2025-04-20 05:49:15 +00:00
16 lines
205 B
Go
16 lines
205 B
Go
package env
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
)
|
|
|
|
func RunChecks() {
|
|
checkEnv("APP_URL")
|
|
}
|
|
|
|
func checkEnv(key string) {
|
|
if os.Getenv(key) == "" {
|
|
panic(fmt.Sprintf("Environment variable %s is not set", key))
|
|
}
|
|
}
|