**What**
- Support configuration the faas-cli configuration directory path via
the `OPENFAAS_CONFIG` env variable. When this value is set, the path
will be overridden. When empty, we will also check the CI flag, which
defaults the location to the current working directory. When neither
`OPENFAAS_CONFIG` or `CI` are set, then the default location is in
the current HOME folder.
- Various tests have been updated to use this new env variable instead
of modifying the global variables. Also, the variables are now
constants to prevent this kind of modiication in general.
Signed-off-by: Lucas Roesler <roesler.lucas@gmail.com>
Decouples the "config" package from the "proxy" package so that
it can stand alone.
Signed-off-by: Vivek Singh <vivekkmr45@yahoo.in>
Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
This commit saves oauth2 tokens to the openfaas config file with a
different auth type. The different auth type helps to determine whether
it is basic auth token or oauth2 token. It also refactors existing
config file function to cater the needs of auth command.
Fixes: #663
Signed-off-by: Vivek Singh <vivekkmr45@yahoo.in>