py-kms/docker/docker-py3-kms/start.sh

21 lines
1.3 KiB
Bash
Raw Normal View History

2019-03-29 14:46:17 +01:00
#!/bin/bash
# EN: Start daemons
# RU: Запуск демонов
cd /home/py-kms/py-kms
2019-03-29 14:46:17 +01:00
if [ "$SQLITE" == false ];
then
if [ "$EPID" == "" ];
then
/usr/bin/python3 pykms_Server.py ${IP} ${PORT} -l ${LCID} -c ${CLIENT_COUNT} -a ${ACTIVATION_INTERVAL} -r ${RENEWAL_INTERVAL} -w ${HWID} -v ${LOGLEVEL} -f ${LOGFILE}
2019-03-29 14:46:17 +01:00
else
/usr/bin/python3 pykms_Server.py ${IP} ${PORT} -e ${EPID} -l ${LCID} -c ${CLIENT_COUNT} -a ${ACTIVATION_INTERVAL} -r ${RENEWAL_INTERVAL} -s ${SQLITE} -w ${HWID} -v ${LOGLEVEL} -f ${LOGFILE}
2019-03-29 14:46:17 +01:00
fi
else
if [ "$EPID" == "" ];
then
/bin/bash -c "/usr/bin/python3 pykms_Server.py ${IP} ${PORT} -l ${LCID} -c ${CLIENT_COUNT} -a ${ACTIVATION_INTERVAL} -r ${RENEWAL_INTERVAL} -s -w ${HWID} -v ${LOGLEVEL} -f ${LOGFILE} &" && /usr/bin/python3 pykms_Client.py ${IP} ${PORT} -m Windows10 && /usr/bin/python3 /home/sqlite_web/sqlite_web.py -H ${IP} -x ${PWD}/clients.db --read-only
2019-03-29 14:46:17 +01:00
else
/bin/bash -c "/usr/bin/python3 pykms_Server.py ${IP} ${PORT} -e ${EPID} -l ${LCID} -c ${CLIENT_COUNT} -a ${ACTIVATION_INTERVAL} -r ${RENEWAL_INTERVAL} -s -w ${HWID} -v ${LOGLEVEL} -f ${LOGFILE} &" && /usr/bin/python3 pykms_Client.py ${IP} ${PORT} -m Windows10 && /usr/bin/python3 /home/sqlite_web/sqlite_web.py -H ${IP} -x ${PWD}/clients.db --read-only
2019-03-29 14:46:17 +01:00
fi
fi