diff --git a/README.md b/README.md index 75caea7..46f2898 100644 --- a/README.md +++ b/README.md @@ -13,16 +13,7 @@ $ unzip linux-daemon.zip $ cd linux-daemon -#edit `unlocker-daemon.service` so that the absolute path to unlocker-daemon.py is correct - -$ mv unlocker-daemon.service /etc/systemd/system/unlocker-daemon - -$ sudo systemctl daemon-reload - -$ sudo systemctl enable unlocker-daemon - -$ sudo systemctl start unlocker-daemon - -$ ./remote-linux-pair +$ bash ./init ``` +Don't move/delete this directory even after running the script. \ No newline at end of file diff --git a/linux-daemon/init.sh b/linux-daemon/init.sh new file mode 100644 index 0000000..8410533 --- /dev/null +++ b/linux-daemon/init.sh @@ -0,0 +1,8 @@ +sudo apt install python +sed -i 's@--edit--@'"$PWD"'@' unlocker-daemon.service +mv unlocker-daemon.service /etc/systemd/system/unlocker-daemon.service + +sudo systemctl daemon-reload +sudo systemctl enable unlocker-daemon +sudo systemctl start unlocker-daemon +./remote-linux-pair \ No newline at end of file diff --git a/linux-daemon/linux-daemon.zip b/linux-daemon/linux-daemon.zip index 9db92ff..3564d7d 100644 Binary files a/linux-daemon/linux-daemon.zip and b/linux-daemon/linux-daemon.zip differ diff --git a/linux-daemon/unlocker-deamon.service b/linux-daemon/unlocker-daemon.service similarity index 59% rename from linux-daemon/unlocker-deamon.service rename to linux-daemon/unlocker-daemon.service index a53b6dd..c237ac6 100644 --- a/linux-daemon/unlocker-deamon.service +++ b/linux-daemon/unlocker-daemon.service @@ -6,7 +6,7 @@ Description=unlocker-daemon [Service] -ExecStart=/usr/bin/python /home/maxchehab/Projects/remote-linux-unlocker/linux-daemon/unlocker-daemon.py +ExecStart=/usr/bin/python --edit--/unlocker-daemon.py [Install] WantedBy=multi-user.target