From 3a572cb5d896c2e4e972dca2f84e531e90bec4c8 Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Fri, 13 Oct 2017 16:01:04 +0300 Subject: Add: start_ick script to start ick Can't see why the command in ick2.service doesn't work, and I'm tired of debugging this. --- ick2.service | 5 ++--- setup.py | 2 +- start_ick | 11 +++++++++++ 3 files changed, 14 insertions(+), 4 deletions(-) create mode 100644 start_ick diff --git a/ick2.service b/ick2.service index 423e26c..9e2f4c1 100644 --- a/ick2.service +++ b/ick2.service @@ -20,9 +20,8 @@ After=network.target Type=simple User=www-data Group=www-data -WorkingDirectory=/var/lib/ick2 -Environment=ICK_CONTROLLER_CONFIG=/etc/ick/controller.conf -ExecStart=/usr/bin/gunicorn3 --daemon --bind 127.0.0.1:12765 --log-file /tmp/gunicorn3.log --log-level debug ick_controller:app +WorkingDirectory=/var/lib/ick +ExecStart=/usr/bin/start_ick KillSignal=QUIT [Install] diff --git a/setup.py b/setup.py index 151dfb6..ac5ec63 100644 --- a/setup.py +++ b/setup.py @@ -28,6 +28,6 @@ setup( url='http://liw.fi/ick/', py_modules=['ick_controller'], packages=['ick2', 'ick2version'], - scripts=['create-token'], + scripts=['create-token', 'start_ick'], data_files=[], ) diff --git a/start_ick b/start_ick new file mode 100644 index 0000000..10a25f6 --- /dev/null +++ b/start_ick @@ -0,0 +1,11 @@ +#!/bin/sh + +set -eux + +export ICK_CONTROLLER_CONFIG=/etc/ick/controller.conf +gunicorn3 \ + --daemon \ + --bind 127.0.0.1:12765 \ + --log-file /tmp/gunicorn3.log \ + --log-level debug \ + ick_controller:app -- cgit v1.2.1