-
Notifications
You must be signed in to change notification settings - Fork 0
/
installer.sh
executable file
·44 lines (31 loc) · 1.02 KB
/
installer.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#! /bin/bash
if [[ $# -eq 1 ]]
then
case $1 in
-i|--install)
./generate_service.py
sudo mv ./meetings-assistant.service /etc/systemd/system/.
sudo systemctl daemon-reload
sudo systemctl enable meetings-assistant
sudo systemctl start meetings-assistant
systemctl status meetings-assistant --no-pager
;;
-u|--uninstall)
sudo systemctl stop meetings-assistant
sudo systemctl disable meetings-assistant
sudo rm -vf /etc/systemd/system/meetings-assistant.service
sudo systemctl daemon-reload
;;
-h|--help)
printf "\nAvailable Options
-i | --install Installs Meetings Assistant service
-u | --uninstall Unsinstalls Meetings Assistant service
-h | --help Show help\n\n"
;;
*)
printf "\nInvalid option, use '-h' to show help\n\n"
;;
esac
else
printf "\nNo options specified, use '-h' to show help\n\n"
fi