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:
@@ -3,6 +3,5 @@ ROOT=/home/matalok/auth/auth
|
|||||||
@daily $ROOT/run-cron.py reddit.cron UpdateAPIs > $ROOT/logs/redditapi-update.log 2>&1
|
@daily $ROOT/run-cron.py reddit.cron UpdateAPIs > $ROOT/logs/redditapi-update.log 2>&1
|
||||||
*/10 * * * * $ROOT/run-cron.py reddit.cron ProcessValidations > $ROOT/logs/reddit-validations.log 2>&1
|
*/10 * * * * $ROOT/run-cron.py reddit.cron ProcessValidations > $ROOT/logs/reddit-validations.log 2>&1
|
||||||
*/5 * * * * $ROOT/run-cron.py eve_api.cron UpdateAPIs > $ROOT/logs/eveapi-update.log 2>&1
|
*/5 * * * * $ROOT/run-cron.py eve_api.cron UpdateAPIs > $ROOT/logs/eveapi-update.log 2>&1
|
||||||
@hourly $ROOT/run-cron.py sso.cron RemoveInvalidUsers > $ROOT/logs/auth-update.log 2>&1
|
|
||||||
0 */6 * * * $ROOT/run-cron.py eve_api.cron AllianceUpdate > $ROOT/logs/alliance-update.log 2>&1
|
0 */6 * * * $ROOT/run-cron.py eve_api.cron AllianceUpdate > $ROOT/logs/alliance-update.log 2>&1
|
||||||
@daily $ROOT/run-cron.py eve_proxy.cron ClearStaleCache > $ROOT/logs/cache-clear.log 2>&1
|
@daily $ROOT/run-cron.py eve_proxy.cron ClearStaleCache > $ROOT/logs/cache-clear.log 2>&1
|
||||||
|
|||||||
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 eve_api.models import EVEAccount
|
||||||
from sso.models import ServiceAccount, Service
|
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():
|
class UpdateServiceGroups():
|
||||||
"""
|
"""
|
||||||
Cycles through all service accounts and updates group access.
|
Cycles through all service accounts and updates group access.
|
||||||
|
|||||||
Reference in New Issue
Block a user