aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo Chatzimichos <tampakrap@gentoo.org>2011-06-13 18:23:35 +0300
committerTheo Chatzimichos <tampakrap@gentoo.org>2011-06-13 18:23:35 +0300
commita838bb7239b87d852dda9fbf534e00f321ed4ce7 (patch)
tree2c7125e2e9790867d3d18388553b22d2388b9237 /settings
parentMove backends -> accounts (diff)
downloadidentity.gentoo.org-a838bb7239b87d852dda9fbf534e00f321ed4ce7.tar.gz
identity.gentoo.org-a838bb7239b87d852dda9fbf534e00f321ed4ce7.tar.bz2
identity.gentoo.org-a838bb7239b87d852dda9fbf534e00f321ed4ce7.zip
Update settings with more ldap vars
Diffstat (limited to 'settings')
-rw-r--r--settings/10-base.conf4
-rw-r--r--settings/90-development.sample2
-rw-r--r--settings/90-production.sample26
3 files changed, 26 insertions, 6 deletions
diff --git a/settings/10-base.conf b/settings/10-base.conf
index 1e0eb39..6c9d09e 100644
--- a/settings/10-base.conf
+++ b/settings/10-base.conf
@@ -75,6 +75,6 @@ LOGOUT_URL = '/logout/'
SESSION_EXPIRE_AT_BROWSER_CLOSE = True
AUTHENTICATION_BACKENDS = (
- 'okupy.backends.ldapbackend.LDAPBackend',
+ 'okupy.accounts.backends.LDAPBackend',
'django.contrib.auth.backends.ModelBackend',
-)
+) \ No newline at end of file
diff --git a/settings/90-development.sample b/settings/90-development.sample
index 5629c90..f0ee0aa 100644
--- a/settings/90-development.sample
+++ b/settings/90-development.sample
@@ -94,7 +94,7 @@ LDAP_ADMIN_USER_DN = 'cn=Manager,dc=example,dc=com'
LDAP_ADMIN_USER_PW = 'password'
# Multiple OU's are supported
-LDAP_BASE_DN = ['ou=users,dc=example,dc=com']
+LDAP_BASE_DN = ['ou=users,dc=example,dc=com', 'ou=developers,dc=example,dc=com']
# The prefix of the attrs, such as cn or uid
LDAP_BASE_ATTR = 'uid'
diff --git a/settings/90-production.sample b/settings/90-production.sample
index 924861d..42519f3 100644
--- a/settings/90-production.sample
+++ b/settings/90-production.sample
@@ -78,6 +78,8 @@ LOGGING = {
}
}
+AUTH_PROFILE_MODULE = 'accounts.UserProfile'
+
# LDAP specific variables
# The URI of the LDAP server
@@ -94,13 +96,14 @@ LDAP_ADMIN_USER_DN = 'cn=Manager,dc=example,dc=com'
LDAP_ADMIN_USER_PW = 'password'
# Multiple OU's are supported
-LDAP_BASE_DN = ['ou=users,dc=example,dc=com']
+LDAP_BASE_DN = ['ou=users,dc=example,dc=com', 'ou=developers,dc=example,dc=com']
# The prefix of the attrs, such as cn or uid
LDAP_BASE_ATTR = 'uid'
# The basic LDAP data, also required by the Django DB
LDAP_USER_ATTR_MAP = {
+ 'username': 'uid',
'first_name': 'givenName',
'last_name': 'sn',
'email': 'mail',
@@ -108,5 +111,22 @@ LDAP_USER_ATTR_MAP = {
# Additional data, that can be mapped by the Django
# user profile
-#LDAP_PROFILE_ATTR_MAP = {
-#} \ No newline at end of file
+# LDAP_PROFILE_ATTR_MAP = {
+# 'cn': 'cn',
+# 'all_mails': 'mail',
+# 'gecos': 'gecos',
+# 'ssh_public_key': 'sshPublicKey',
+# 'gpg_fingerprint': 'gpgfingerprint',
+# 'gpg_key': 'gpgkey',
+# 'lat': 'lat',
+# 'lon': 'lon',
+# 'gentoo_roles': 'gentooRoles',
+# 'gentoo_access': 'gentooAccess',
+# 'gentoo_location': 'gentooLocation',
+# 'gentoo_status': 'gentooStatus',
+# }
+
+# The attribute which has the groups that the user is part of
+# LDAP_ACL_ATTR = 'gentooAccess'
+
+# LDAP_ACL_GROUPS = ['infra', 'devrel', 'recruiters', 'trustee', 'docs', 'security'] \ No newline at end of file