2023-02-14 21:47:28 +01:00
|
|
|
PWD_DIR=$(pwd)
|
2022-01-17 11:49:16 +01:00
|
|
|
REL_DIR=$PWD_DIR/_build/relive/
|
|
|
|
CON_DIR=$REL_DIR/conf/
|
|
|
|
|
|
|
|
[ -z "$REL_DIR_TEMP" ] && REL_DIR_TEMP=$REL_DIR
|
|
|
|
CON_DIR_TEMP=$REL_DIR_TEMP/conf/
|
|
|
|
|
|
|
|
make ejabberdctl.relive
|
|
|
|
chmod +x ejabberdctl.relive
|
|
|
|
mv ejabberdctl.relive $REL_DIR/ejabberdctl
|
|
|
|
|
|
|
|
cp inetrc $CON_DIR/
|
|
|
|
cp ejabberdctl.cfg.example $CON_DIR/ejabberdctl.cfg.example
|
|
|
|
cp ejabberd.yml.example $CON_DIR/ejabberd.yml.example
|
|
|
|
cp test/ejabberd_SUITE_data/ca.pem $CON_DIR
|
|
|
|
cp test/ejabberd_SUITE_data/cert.pem $CON_DIR
|
|
|
|
|
2023-02-14 21:47:28 +01:00
|
|
|
cd $CON_DIR_TEMP || exit
|
2022-01-17 11:49:16 +01:00
|
|
|
|
|
|
|
sed -i "s|# certfiles:|certfiles:\n - $CON_DIR/cert.pem|g" ejabberd.yml.example
|
|
|
|
sed -i "s|certfiles:|ca_file: $CON_DIR/ca.pem\ncertfiles:|g" ejabberd.yml.example
|
|
|
|
sed -i 's|^acl:$|acl:\n admin: [user: admin]|g' ejabberd.yml.example
|
|
|
|
[ ! -f "$CON_DIR/ejabberd.yml" ] \
|
2023-02-14 21:47:28 +01:00
|
|
|
&& printf "ejabberd.yml " \
|
2022-01-17 11:49:16 +01:00
|
|
|
&& mv ejabberd.yml.example ejabberd.yml
|
|
|
|
|
|
|
|
sed -i "s|#' POLL|EJABBERD_BYPASS_WARNINGS=true\n\n#' POLL|g" ejabberdctl.cfg.example
|
|
|
|
[ ! -f "$CON_DIR/ejabberdctl.cfg" ] \
|
2023-02-14 21:47:28 +01:00
|
|
|
&& printf "ejabberdctl.cfg " \
|
2022-11-30 22:03:50 +01:00
|
|
|
&& mv ejabberdctl.cfg.example ejabberdctl.cfg \
|
2023-02-14 21:47:28 +01:00
|
|
|
|| printf
|