mirror of
https://github.com/steveiliop56/tinyauth.git
synced 2026-03-07 07:11:58 +00:00
Compare commits
2 Commits
v5.0.0-alp
...
baf4798665
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
baf4798665 | ||
|
|
bea680edec |
@@ -30,15 +30,9 @@ func healthcheckCmd() *cli.Command {
|
|||||||
|
|
||||||
appUrl := "http://127.0.0.1:3000"
|
appUrl := "http://127.0.0.1:3000"
|
||||||
|
|
||||||
appUrlEnv := os.Getenv("TINYAUTH_APPURL")
|
|
||||||
srvAddr := os.Getenv("TINYAUTH_SERVER_ADDRESS")
|
srvAddr := os.Getenv("TINYAUTH_SERVER_ADDRESS")
|
||||||
srvPort := os.Getenv("TINYAUTH_SERVER_PORT")
|
srvPort := os.Getenv("TINYAUTH_SERVER_PORT")
|
||||||
|
|
||||||
if appUrlEnv != "" {
|
|
||||||
appUrl = appUrlEnv
|
|
||||||
}
|
|
||||||
|
|
||||||
// Local-direct connection is preferred over the public app URL
|
|
||||||
if srvAddr != "" && srvPort != "" {
|
if srvAddr != "" && srvPort != "" {
|
||||||
appUrl = fmt.Sprintf("http://%s:%s", srvAddr, srvPort)
|
appUrl = fmt.Sprintf("http://%s:%s", srvAddr, srvPort)
|
||||||
}
|
}
|
||||||
@@ -48,7 +42,7 @@ func healthcheckCmd() *cli.Command {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if appUrl == "" {
|
if appUrl == "" {
|
||||||
return errors.New("TINYAUTH_APPURL is not set and no argument was provided")
|
return errors.New("Could not determine app URL")
|
||||||
}
|
}
|
||||||
|
|
||||||
tlog.App.Info().Str("app_url", appUrl).Msg("Performing health check")
|
tlog.App.Info().Str("app_url", appUrl).Msg("Performing health check")
|
||||||
|
|||||||
@@ -138,7 +138,7 @@ type OIDCClientConfig struct {
|
|||||||
ClientID string `description:"OIDC client ID." yaml:"clientId"`
|
ClientID string `description:"OIDC client ID." yaml:"clientId"`
|
||||||
ClientSecret string `description:"OIDC client secret." yaml:"clientSecret"`
|
ClientSecret string `description:"OIDC client secret." yaml:"clientSecret"`
|
||||||
ClientSecretFile string `description:"Path to the file containing the OIDC client secret." yaml:"clientSecretFile"`
|
ClientSecretFile string `description:"Path to the file containing the OIDC client secret." yaml:"clientSecretFile"`
|
||||||
TrustedRedirectURIs []string `description:"List of trusted redirect URLs." yaml:"trustedRedirectUrls"`
|
TrustedRedirectURIs []string `description:"List of trusted redirect URIs." yaml:"trustedRedirectUris"`
|
||||||
Name string `description:"Client name in UI." yaml:"name"`
|
Name string `description:"Client name in UI." yaml:"name"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user