After AAA/Auth migration, there were some users in a corner case for import where they had both different users at FAS and ACO level, but using same email address. As pagure keeps in local DB user settings (including default_email), when such users are trying to login through openid/openidc with different username but same email, pagure doesn't like and cancels openid transaction (going back into kind of loop)
default_email
Simple solution (directly in MySQL DB) :
update users set user='new_AAA_username' where user='old_ACO_username';
Next time user will login, it will match local user cached/defined in MySQL
Already confirmed by @ttomecek that it works, so keeping this ticket open to review users in such situation, and then we'll close it
Just also something to have a look at/fix : if user had forked projects, it needs to be reflected too At the pagure side, it's just a matter of moving repository to new username:
mv /srv/git/repositories/forks/old_ACO_username/ /srv/git/repositories/forks/new_AAA_username/
And for users, they can just git remote origin set-url <new url> to reflect, or just decide to delete and clone again from their forked repo (up 2 users to decide what they want to do)
git remote origin set-url <new url>
So in short :
old_user="old_ACO_username" new_user="new_AAA_username" mysql pagure -e "update users set user='${new_user}' where user='${old_user}';" test -d /srv/git/repositories/forks/${old_user} && mv /srv/git/repositories/forks/${old_user} /srv/git/repositories/forks/${new_user}
Closing as nobody seem to be in that case anymore and solution can still be found in this ticket if needed
Metadata Update from @arrfab: - Issue close_status updated to: Fixed - Issue status updated to: Closed (was: Open)
Log in to comment on this ticket.