You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
490 B
21 lines
490 B
#!/bin/sh
|
|
|
|
mkdir -p /srv/data/etc
|
|
|
|
for file_path in /srv/atheme/etc/*.example; do
|
|
file_name="$(basename "$file_path")"
|
|
cp -n -p "$file_path" "/srv/data/etc/${file_name%%.example}"
|
|
done
|
|
|
|
cp -n -p -r /srv/atheme/var /srv/data/
|
|
|
|
# Reset crontab
|
|
crontab -r
|
|
# Add healthcheck cronjob
|
|
echo "*/5 * * * * /srv/data/etc/atheme.cron >/dev/null 2>&1" | crontab -
|
|
|
|
rm -f /srv/data/var/run/atheme/atheme.pid
|
|
su atheme \
|
|
-c "/srv/atheme/bin/atheme-services \
|
|
-n \
|
|
$*"
|
|
|