home · contact · privacy
Add plomlombot to public server.
authorChristian Heller <c.heller@plomlompom.de>
Wed, 30 Mar 2016 22:33:07 +0000 (00:33 +0200)
committerChristian Heller <c.heller@plomlompom.de>
Wed, 30 Mar 2016 22:33:07 +0000 (00:33 +0200)
jessie_postinstall.sh
systemfiles/plomlombot.service [new file with mode: 0644]

index 5305c14b78fb08879615d668077cef2586df03f9..654e7acc0aac513fff02c0a2ad76787be3ecf83d 100755 (executable)
@@ -218,6 +218,7 @@ if [ "$1" = "server" ]; then
         config/bin/simplemail.sh config/mails/server_postinstall_finished
 
     elif [ "$2" = "public" ]; then
         config/bin/simplemail.sh config/mails/server_postinstall_finished
 
     elif [ "$2" = "public" ]; then
+
         # Set up twtxt environment.
         apt-get -y install screen
         apt-get -y -t jessie-backports install golang
         # Set up twtxt environment.
         apt-get -y install screen
         apt-get -y -t jessie-backports install golang
@@ -230,6 +231,14 @@ if [ "$1" = "server" ]; then
         cp config/systemfiles/htwtxt_restart_reminder.service \
             /etc/systemd/system/htwtxt_restart_reminder.service
         systemctl enable /etc/systemd/system/htwtxt_restart_reminder.service
         cp config/systemfiles/htwtxt_restart_reminder.service \
             /etc/systemd/system/htwtxt_restart_reminder.service
         systemctl enable /etc/systemd/system/htwtxt_restart_reminder.service
+
+        # Set up plomlombot.
+        apt-get -y python3 python3-venv python3-pip
+        su - plom -c 'cd && git clone http://github.com/plomlompom/plomlombot-irc'
+        su - plom -c 'mkdir -p ~/plomlombot_db'
+        cp config/systemfiles/plomlombot.service \
+            /etc/systemd/system/plomlombot.service
+        systemctl enable /etc/systemd/system/plomlombot.service
     fi
 
 elif [ "$1" = "thinkpad" ]; then
     fi
 
 elif [ "$1" = "thinkpad" ]; then
diff --git a/systemfiles/plomlombot.service b/systemfiles/plomlombot.service
new file mode 100644 (file)
index 0000000..c9028bd
--- /dev/null
@@ -0,0 +1,12 @@
+# /etc/systemd/system/weechat.service
+
+[Unit]
+Description=plomlombot screen
+
+[Service]
+Type=forking
+User=plom
+ExecStart=/bin/sh -c 'screen -d -m ~/plomlombot-irc/run.sh "#zrolaps"'
+
+[Install]
+WantedBy=multi-user.target