mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52:15 +00:00
Remove the RemoveInvalidUsers job, no longer needed
This commit is contained in:
20
sso/cron.py
20
sso/cron.py
@@ -4,26 +4,6 @@ from django.contrib.auth.models import User, Group
|
||||
from eve_api.models import EVEAccount
|
||||
from sso.models import ServiceAccount, Service
|
||||
|
||||
class RemoveInvalidUsers():
|
||||
"""
|
||||
Cycles through all users and runs the permission checking routine for
|
||||
each profile.
|
||||
"""
|
||||
|
||||
# run every 2 hours
|
||||
run_every = 7200
|
||||
|
||||
@property
|
||||
def _logger(self):
|
||||
if not hasattr(self, '__logger'):
|
||||
self.__logger = logging.getLogger(__name__)
|
||||
return self.__logger
|
||||
|
||||
def job(self, args):
|
||||
for user in User.objects.all():
|
||||
# For each user, update access list based on Corp details
|
||||
user.get_profile().update_access()
|
||||
|
||||
class UpdateServiceGroups():
|
||||
"""
|
||||
Cycles through all service accounts and updates group access.
|
||||
|
||||
Reference in New Issue
Block a user