From 965cf754cf7f234f75ca1fdb9a501c13fa2bb9ed Mon Sep 17 00:00:00 2001 From: Dan Sosedoff Date: Tue, 27 Nov 2018 14:58:50 -0600 Subject: [PATCH] Allow settings url prefix with URL_PREFIX env var --- pkg/command/options.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pkg/command/options.go b/pkg/command/options.go index cf41983..7503ac5 100644 --- a/pkg/command/options.go +++ b/pkg/command/options.go @@ -54,6 +54,10 @@ func ParseOptions(args []string) (Options, error) { opts.Url = os.Getenv("DATABASE_URL") } + if opts.Prefix == "" { + opts.Prefix = os.Getenv("URL_PREFIX") + } + if os.Getenv("SESSIONS") != "" { opts.Sessions = true }