Skip to content

Instantly share code, notes, and snippets.

@joepreludian
Created November 27, 2013 17:37
Show Gist options
  • Save joepreludian/7679866 to your computer and use it in GitHub Desktop.
Save joepreludian/7679866 to your computer and use it in GitHub Desktop.
USERS = {'admin@admin': '123',
'user': '123'}
GROUPS = {'admin': ['group:sysadmin'],
'user': ['group:users']}
def groupfinder(userid, request):
if userid in USERS:
return GROUPS.get(userid, [])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment