issues
search
Optum
/
dce-cli
Disposable Cloud Environment CLI
Apache License 2.0
37
stars
19
forks
source link
Add `dce auth`; Refactor Config file mgmt; Add integration tests
#38
Closed
eschwartz
closed
4 years ago
eschwartz
commented
4 years ago
Stuff going on here
Add
dce auth
command
pops you out to a browser at the
/auth
endpoint that @joshmarsh is working on
see #33
Remove dce.yml configs we aren't using
Configure a AWS creds provider that will load creds from the auth token, but fallback to env vars or the
~/.aws/credentials
file
Run
dce auth
before any command, if we don't have any valid creds in our chain
Refactor how to load and save our config YAML, so it's easier to work with from inside multiple commands
Remove viper dependency (wasn't really being used)
Some other cleanup/refactor around init logic, to get this all wired up properly
I'll try to point these out in the code
New setup for integration tests
These test call our cobra CLI programmatically. For some reasons:
Lets us use debugger to run through tests
Don't need to rebuild for every test run
Can still use mocks at boundaries (eg. mock out web browser call)
I'm hoping this new testing pattern makes it easier to write tests for CLI commands going forward.
Stuff going on here
dce auth
command/auth
endpoint that @joshmarsh is working on~/.aws/credentials
filedce auth
before any command, if we don't have any valid creds in our chain