Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JUJU-732] Fix external user login errors on single controller #13822

Merged
merged 2 commits into from Mar 10, 2022

Conversation

wallyworld
Copy link
Member

When trying to login as an external user, the controller was attempting to find this user in state and returning a not found error. This is wrong because external users do not exist in the model, only their permissions.

Also, some structs and interfaces associated with entity auth were poorly named, eg AgentAuthenticator is actually also used for users.
And the AuthInfo struct has an obsolete LastConnection field that was unused.

QA steps

juju bootstrap --config identity-url=https://api.jujucharms.com/identity --config identity-public-key=hmHaPgCC1UfuhYHUSX5+aihSAZesqpVdjRv0mgfIwjo=
juju grant wallyworld@external login
juju grant wallyworld@external write default

export JUJU_DATA=/path
cd $JUJU_DATA
cp ~/.local/share/juju/controllers.yaml $JUJU_DATA
juju login
juju deploy ubuntu
juju status

Also check local users using juju add-user, juju grant, and juju register.

@wallyworld wallyworld changed the title Fix external user login errors on single controller [JUJU-732] Fix external user login errors on single controller Mar 10, 2022
Copy link
Member

@ycliuhw ycliuhw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm ty

apiserver/authentication/agent.go Outdated Show resolved Hide resolved
@wallyworld
Copy link
Member Author

$$merge$$

@jujubot jujubot merged commit 9e0c10f into juju:2.9 Mar 10, 2022
@wallyworld wallyworld mentioned this pull request Mar 16, 2022
jujubot added a commit that referenced this pull request Mar 16, 2022
#13840

Merge 2.9

#13822
#13763
#13810
#13827 
#13830 
#13831 
#13833 
#13835 
#13836 
#13832 
#13838

```
# Conflicts:
# cmd/juju/application/deploy.go
# cmd/juju/application/deployer/interface.go
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants