Rotate robot user uuid when the credentials change

This commit is contained in:
Jake Moshenko 2015-12-31 13:57:43 -05:00 committed by Jimmy Zelinskie
parent ce8fcbeaae
commit a9b7ac6b48

View file

@ -255,6 +255,7 @@ def regenerate_robot_token(robot_shortname, parent):
robot = lookup_robot(robot_username)
password = random_string_generator(length=64)()
robot.email = password
robot.uuid = str(uuid4())
service = LoginService.get(name='quayrobot')
login = FederatedLogin.get(FederatedLogin.user == robot, FederatedLogin.service == service)