This repository has been archived on 2019-03-27. You can view files and clone it, but cannot push or open issues or pull requests.
prosody/entrypoint.sh
Simon Bruder 363737a2b8
All checks were successful
continuous-integration/drone/push Build is passing
init
2019-03-27 23:28:19 +01:00

19 lines
561 B
Bash
Executable file

#!/bin/bash
# certs
rm -rf /etc/prosody/fixed-certs
cp -r /etc/prosody/certs /etc/prosody/fixed-certs
find /etc/prosody/fixed-certs -type f -print0 | xargs --null -I{} mv {} {}.pem
chown -R prosody:prosody /etc/prosody/fixed-certs
# “templating”
sed -i \
-e "s/@@DOMAIN@@/${DOMAIN}/" \
-e "s/@@ADMIN_USER@@/${ADMIN_USER}/" \
-e "s/@@LDAP_SERVER@@/${LDAP_SERVER}/" \
-e "s/@@LDAP_BASE@@/${LDAP_BASE}/" \
-e "s/@@LDAP_USER@@/${LDAP_USER}/" \
-e "s/@@LDAP_PASSWORD@@/${LDAP_PASSWORD}/" \
/etc/prosody/prosody.cfg.lua
exec prosody