From 4854ce1d4e3adca3b416a564a8d0018448808e52 Mon Sep 17 00:00:00 2001 From: Martin Treusch von Buttlar Date: Mon, 22 May 2017 09:23:23 +0200 Subject: remove use of viper to parse env variables --- cmd/ponzu/main.go | 8 -------- 1 file changed, 8 deletions(-) (limited to 'cmd') diff --git a/cmd/ponzu/main.go b/cmd/ponzu/main.go index fc9757d..acbe214 100644 --- a/cmd/ponzu/main.go +++ b/cmd/ponzu/main.go @@ -21,7 +21,6 @@ import ( "github.com/ponzu-cms/ponzu/system/db" "github.com/ponzu-cms/ponzu/system/tls" "github.com/spf13/cobra" - "github.com/spf13/viper" _ "github.com/ponzu-cms/ponzu/content" ) @@ -190,13 +189,6 @@ func init() { pflags := rootCmd.PersistentFlags() pflags.StringVar(&gocmd, "gocmd", "go", "custom go command if using beta or new release of Go") - - viper.SetEnvPrefix("PONZU") - viper.BindPFlag("gocmd", pflags.Lookup("gocmd")) - // bind the flags for run to environment variables, with PONZU_ prefix. - viper.BindPFlag("port", runCmd.Flags().Lookup("port")) - viper.BindPFlag("httpsport", runCmd.Flags().Lookup("httpsport")) - viper.BindPFlag("devhttps", runCmd.Flags().Lookup("devhttps")) } func main() { -- cgit v1.2.3