Skip to content

Conversation

@grasmash
Copy link
Contributor

@grasmash grasmash commented Nov 19, 2021

Motivation

Fixes CLI-141

Proposed changes

  1. When Federated Login is required and the user runs an acli command using the Cloud IDE provided access token, throw a useful error instructing them to run acli login.
  2. When an API key and secret are present on disk, prefer them over the Cloud IDE defined access token.

Alternatives considered

Testing steps

  1. Follow the contribution guide to set up your development environment.
  2. Clear the kernel cache to pick up new and changed commands: ./bin/acli ckc
  3. (add specific steps for this pr)

Merge requirements

  • Bug, enhancement, or breaking change label applied
  • Manual testing by a reviewer

@anavarre anavarre changed the title Fed auth CLI-141: Fed auth Nov 19, 2021
Matthew Grasmick and others added 2 commits November 19, 2021 16:18
@grasmash
Copy link
Contributor Author

So, I realized that the previous implementation of this will not work. We can't use the Cloud IDE access token at all because it was never scoped to the the org. Therefore, we must force the customer to manually login via acli and use an API token and secret for authentication.

@grasmash
Copy link
Contributor Author

grasmash commented Nov 19, 2021

Initial error:
image

After acli login, it works.

@grasmash grasmash added the bug Something isn't working label Nov 19, 2021
@grasmash grasmash changed the title CLI-141: Fed auth CLI-141: Provide workaround for Fed Auth, prefer api key and secret. Nov 19, 2021
@grasmash grasmash merged commit 29e645d into master Nov 19, 2021
@grasmash grasmash deleted the fed-auth branch November 19, 2021 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants