Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
hpc-factory
Manage
Activity
Members
Labels
Plan
Issues
63
Issue boards
Milestones
Wiki
Code
Merge requests
12
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
rc
hpc-factory
Commits
a98048c5
Commit
a98048c5
authored
5 months ago
by
Eesaan Atluri
Browse files
Options
Downloads
Patches
Plain Diff
feat: Enable TLS in ldap only for non-proxy nodes
parent
6368a3e6
No related branches found
Branches containing commit
No related tags found
1 merge request
!92
refactor: Modify roles in cheaha.yml to enable a proxy
Pipeline
#11418
failed with stages
in 2 hours, 3 minutes, and 4 seconds
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
ansible/roles/ldap_config/tasks/main.yml
+3
-2
3 additions, 2 deletions
ansible/roles/ldap_config/tasks/main.yml
ansible/roles/ldap_config/templates/nslcd.conf.j2
+148
-0
148 additions, 0 deletions
ansible/roles/ldap_config/templates/nslcd.conf.j2
with
151 additions
and
2 deletions
ansible/roles/ldap_config/tasks/main.yml
+
3
−
2
View file @
a98048c5
...
...
@@ -33,10 +33,11 @@
-
{
src
:
ca.pem
}
-
{
src
:
ldap.key
}
-
{
src
:
ldap.pem
}
when
:
ldap_uri | regex_search('^ldaps://')
-
name
:
Copy ldap config into place
ansible.builtin.
copy
:
src
:
nslcd.conf
ansible.builtin.
template
:
src
:
nslcd.conf
.j2
dest
:
/etc/nslcd.conf
owner
:
root
group
:
root
...
...
This diff is collapsed.
Click to expand it.
ansible/roles/ldap_config/templates/nslcd.conf.j2
0 → 100644
+
148
−
0
View file @
a98048c5
# This is the configuration file for the LDAP nameservice
# switch library's nslcd daemon. It configures the mapping
# between NSS names (see /etc/nsswitch.conf) and LDAP
# information in the directory.
# See the manual page nslcd.conf(5) for more information.
# The user and group nslcd should run as.
uid nslcd
gid ldap
# The uri pointing to the LDAP server to use for name lookups.
# Multiple entries may be specified. The address that is used
# here should be resolvable without using LDAP (obviously).
#uri ldap://127.0.0.1/
#uri ldaps://127.0.0.1/
#uri ldapi://%2fvar%2frun%2fldapi_sock/
# Note: %2f encodes the '/' used as directory separator
uri {{ ldap_uri }}
# The LDAP version to use (defaults to 3
# if supported by client library)
#ldap_version 3
# The distinguished name of the search base.
base dc=cm,dc=cluster
# The distinguished name to bind to the server with.
# Optional: default is to bind anonymously.
#binddn cn=proxyuser,dc=example,dc=com
# The credentials to bind with.
# Optional: default is no credentials.
# Note that if you set a bindpw you should check the permissions of this file.
#bindpw secret
# The distinguished name to perform password modifications by root by.
#rootpwmoddn cn=admin,dc=example,dc=com
# The default search scope.
#scope sub
#scope one
#scope base
# Customize certain database lookups.
#base group ou=Groups,dc=example,dc=com
#base passwd ou=People,dc=example,dc=com
#base shadow ou=People,dc=example,dc=com
#scope group onelevel
#scope hosts sub
# Bind/connect timelimit.
#bind_timelimit 30
# Search timelimit.
#timelimit 30
# Idle timelimit. nslcd will close connections if the
# server has not been contacted for the number of seconds.
idle_timelimit 240
# Use StartTLS without verifying the server certificate.
#ssl start_tls
#tls_reqcert never
{% if ldap_uri | regex_search('^ldaps://') %}
ssl on
tls_reqcert demand
# CA certificates for server certificate verification
#tls_cacertdir /etc/ssl/certs
tls_cacertfile /cm/local/apps/openldap/etc/certs/ca.pem
tls_cert /cm/local/apps/openldap/etc/certs/ldap.pem
tls_key /cm/local/apps/openldap/etc/certs/ldap.key
{% endif %}
# Seed the PRNG if /dev/urandom is not provided
#tls_randfile /var/run/egd-pool
# SSL cipher suite
# See man ciphers for syntax
#tls_ciphers TLSv1
# Client certificate and key
# Use these, if your server requires client authentication.
# Mappings for Services for UNIX 3.5
#filter passwd (objectClass=User)
#map passwd uid msSFU30Name
#map passwd userPassword msSFU30Password
#map passwd homeDirectory msSFU30HomeDirectory
#map passwd homeDirectory msSFUHomeDirectory
#filter shadow (objectClass=User)
#map shadow uid msSFU30Name
#map shadow userPassword msSFU30Password
#filter group (objectClass=Group)
#map group member msSFU30PosixMember
# Mappings for Services for UNIX 2.0
#filter passwd (objectClass=User)
#map passwd uid msSFUName
#map passwd userPassword msSFUPassword
#map passwd homeDirectory msSFUHomeDirectory
#map passwd gecos msSFUName
#filter shadow (objectClass=User)
#map shadow uid msSFUName
#map shadow userPassword msSFUPassword
#map shadow shadowLastChange pwdLastSet
#filter group (objectClass=Group)
#map group member posixMember
# Mappings for Active Directory
#pagesize 1000
#referrals off
#idle_timelimit 800
#filter passwd (&(objectClass=user)(!(objectClass=computer))(uidNumber=*)(unixHomeDirectory=*))
#map passwd uid sAMAccountName
#map passwd homeDirectory unixHomeDirectory
#map passwd gecos displayName
#filter shadow (&(objectClass=user)(!(objectClass=computer))(uidNumber=*)(unixHomeDirectory=*))
#map shadow uid sAMAccountName
#map shadow shadowLastChange pwdLastSet
#filter group (objectClass=group)
# Alternative mappings for Active Directory
# (replace the SIDs in the objectSid mappings with the value for your domain)
#pagesize 1000
#referrals off
#idle_timelimit 800
#filter passwd (&(objectClass=user)(objectClass=person)(!(objectClass=computer)))
#map passwd uid cn
#map passwd uidNumber objectSid:S-1-5-21-3623811015-3361044348-30300820
#map passwd gidNumber objectSid:S-1-5-21-3623811015-3361044348-30300820
#map passwd homeDirectory "/home/$cn"
#map passwd gecos displayName
#map passwd loginShell "/bin/bash"
#filter group (|(objectClass=group)(objectClass=person))
#map group gidNumber objectSid:S-1-5-21-3623811015-3361044348-30300820
# Mappings for AIX SecureWay
#filter passwd (objectClass=aixAccount)
#map passwd uid userName
#map passwd userPassword passwordChar
#map passwd uidNumber uid
#map passwd gidNumber gid
#filter group (objectClass=aixAccessGroup)
#map group cn groupName
#map group gidNumber gid
# This comment prevents repeated auto-migration of settings.
This diff is collapsed.
Click to expand it.
Bo-Chun Chen
@louistw
mentioned in issue
#125
·
5 months ago
mentioned in issue
#125
mentioned in issue #125
Toggle commit list
Eesaan Atluri
@atlurie
mentioned in issue
#122 (closed)
·
5 months ago
mentioned in issue
#122 (closed)
mentioned in issue #122
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment