qa: Make gitlabBaseURL configurable through env

This commit is contained in:
nemunaire 2024-09-18 08:39:41 +02:00
parent 81958ef4b9
commit c8f70c48fa

View File

@ -38,6 +38,10 @@ func init() {
oidcRedirectURL = v oidcRedirectURL = v
} }
if v, ok := os.LookupEnv("FIC_GITLAB_BASEURL"); ok {
gitlabBaseURL = v
}
flag.StringVar(&oidcRedirectURL, "oidc-redirect", oidcRedirectURL, "Base URL for the redirect after connection") flag.StringVar(&oidcRedirectURL, "oidc-redirect", oidcRedirectURL, "Base URL for the redirect after connection")
flag.StringVar(&gitlabBaseURL, "gitlab-baseurl", gitlabBaseURL, "Base URL of the Gitlab instance") flag.StringVar(&gitlabBaseURL, "gitlab-baseurl", gitlabBaseURL, "Base URL of the Gitlab instance")
flag.StringVar(&gitlabClientID, "gitlab-clientid", os.Getenv("FIC_GITLAB_CLIENT_ID"), "ClientID for GitLab's OIDC") flag.StringVar(&gitlabClientID, "gitlab-clientid", os.Getenv("FIC_GITLAB_CLIENT_ID"), "ClientID for GitLab's OIDC")