1
0
Fork 0
mirror of https://github.com/Luzifer/cloudkeys-go.git synced 2024-11-09 14:40:05 +00:00
cloudkeys-go/config_gae.go
Knut Ahlers 76a6a0100a
Switch to Go 1.12+ modules (#20)
* Switch to Go 1.12+ modules

Signed-off-by: Knut Ahlers <knut@ahlers.me>

* Wipe vendor directory

Signed-off-by: Knut Ahlers <knut@ahlers.me>

* Add dockerized builder

Signed-off-by: Knut Ahlers <knut@ahlers.me>

* Update image to build on recent Go version

Signed-off-by: Knut Ahlers <knut@ahlers.me>
2019-11-07 11:56:54 +00:00

21 lines
360 B
Go

// +build appengine
package main
import (
"os"
"github.com/Luzifer/rconfig/v2"
)
func loadConfig() *config {
cfg := &config{}
// Workaround as GAE supplies more parameters than expected.
// This removes all CLI flags for parsing and relies only on parsing
// environment variables.
os.Args = []string{os.Args[0]}
rconfig.Parse(cfg)
return cfg
}