sso icon indicating copy to clipboard operation
sso copied to clipboard

*: add useful --help output

Open mccutchen opened this issue 7 years ago • 1 comments

We should add a --help CLI flag to both sso-auth and sso-proxy that outputs documentation about configuration, for anyone exploring or debugging the apps at the command line.

At the moment, the --help flag is ignored and instead the user is greeted with a big error message about a bunch of invalid settings (see also #33):

$ docker run --rm buzzfeed/sso:latest sso-proxy --help
{"error":"Invalid configuration:\n  missing setting: cluster\n  missing setting: provider-url\n  missing setting: upstream-configs\n  missing setting: cookie-secret\n  missing setting: client-id\n  missing setting: client-secret\n  missing setting: email-domain\n  missing setting: statsd-host\n  missing setting: statsd-port","level":"error","msg":"error validing options","service":"sso-proxy","time":"2018-08-24 23:49:58.82411"}

mccutchen avatar Aug 24 '18 23:08 mccutchen

Isn't --help a builtin feature of Go's CLI flag library? Are we not using that under-the-hood?

mreiferson avatar Nov 26 '18 01:11 mreiferson