aboutsummaryrefslogtreecommitdiff
path: root/modules/base_installation/templates/puppet/host_ldap_mod_top.info.erb
blob: d7a1294829a6232fef82ba1b9a9996ab1376979a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#### Or modify an existing entry:
ldapmodify -D "cn=root,<%= @ldap_base %>" -W << 'EOF'
dn: <%= @ldap_dn %>
changetype: modify
replace: userPassword
userpassword: {SSHA}<%= Base64.encode64(Digest::SHA1.digest(@ldap_password+@ssha_ldap_seed)+@ssha_ldap_seed).chomp! %>
-
replace: environment
environment: <%= @environment %>
<%- unless @ips.empty? -%>
-
delete: ipHostNumber
<%- unless @ips["v4"].nil? -%>
-
add: ipHostNumber
ipHostNumber: <%= @ips["v4"]["ipAddress"] %>
<%- end -%>
<%- unless @ips["v6"].nil? -%>
-
add: ipHostNumber
ipHostNumber: <%= @ips["v6"]["ipAddress"] %>/<%= @ips["v6"]["mask"] %>
<%- end -%>
<%- end -%>