Fixed base path (again)

This commit is contained in:
2022-02-02 10:10:47 +01:00
parent cac2111296
commit cfe33f517b
4 changed files with 6 additions and 12 deletions

View File

@@ -12,6 +12,7 @@ var (
ServerAddress string
ServerPort string
Protocol string
Prefix string
@@ -30,11 +31,12 @@ func init() {
ServerAddress = os.Getenv("SERVER_ADDRESS")
ServerPort = os.Getenv("SERVER_PORT")
Protocol = os.Getenv("PROTOCOL")
Prefix = path.Join(os.Getenv("PREFIX"))
DatabaseFile = os.Getenv("DATABASE_FILE")
FrontendDir = os.Getenv("FRONTEND_DIR")
BasePath = path.Join(fmt.Sprintf("%s:%s", ServerAddress, ServerPort), Prefix) + "/"
BasePath = Protocol + path.Join(fmt.Sprintf("%s:%s", ServerAddress, ServerPort), Prefix) + "/"
}