mystic/mrc/install.sh
2023-01-07 18:31:25 +01:00

12 lines
362 B
Bash

#!/bin/bash
MYSTIC_DIR="$1"
sed -e "s!@MYSTIC_DIR@!${MYSTIC_DIR}!g" mrc-start.sh > ${MYSTIC_DIR}/mrc-start
chmod +x ${MYSTIC_DIR}/mrc-start
sed -e "s!@MYSTIC_DIR@!${MYSTIC_DIR}!g" mrc-stop.sh > ${MYSTIC_DIR}/mrc-stop
chmod +x ${MYSTIC_DIR}/mrc-stop
sed -e "s!@MYSTIC_DIR@!${MYSTIC_DIR}!g" mrc.service > /etc/systemd/system/mrc.service
systemctl daemon-reload