Adding first working templates
- manager-nginx.conf - portal-nginx.conf - handler-nginx.conf - lmConf-1.js (Any configuration modification in LemonLDAP Manager prevail over this configuration) Adding diagnose script - HTTP Ping the manager, the handler and the portal Adding posttempalte script - Enable nginx configuration if necessary - Add an entry ton /etc/hosts with the 3 web names
This commit is contained in:
19
posttemplate/70-lemon-hosts
Executable file
19
posttemplate/70-lemon-hosts
Executable file
@ -0,0 +1,19 @@
|
||||
#!/bin/bash
|
||||
|
||||
ENABLE=$(CreoleGet activerLemon 'non')
|
||||
HOSTS="/etc/hosts"
|
||||
|
||||
if [ "${ENABLE}" = 'oui' ];then
|
||||
manager=$(CreoleGet managerWebName)
|
||||
handler=$(CreoleGet reloadWebName)
|
||||
portal=$(CreoleGet authWebName)
|
||||
ipaddr=$(CreoleGet adresse_ip_eth0)
|
||||
line="${ipaddr} ${manager} ${handler} ${portal}"
|
||||
grep -q "${line}" ${HOSTS}
|
||||
if [[ ${?} -eq 0 ]]
|
||||
then
|
||||
exit 0
|
||||
else
|
||||
echo ${line} >> ${HOSTS}
|
||||
fi
|
||||
fi
|
Reference in New Issue
Block a user