From b60ccb0a61697b449e57fa91a6f2d12d6debcae8 Mon Sep 17 00:00:00 2001 From: Evan Chen Date: Thu, 21 Oct 2021 01:23:54 +0800 Subject: [PATCH] docs: update install script and unit file --- README.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/README.md b/README.md index 37b5b41..f2c1af2 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,13 @@ Usage: configui [options] -v show version ``` +## Install + +```sh +sudo rm -f /usr/local/bin/configui +sudo sh -c "curl -fsSL RELEASE_URL | tar -C /usr/local/bin/ -xz" +``` + ## Config ```json @@ -41,6 +48,22 @@ Usage: configui [options] `configui -f PATH/TO/CONFIG` +## Systemd + +```ini +; /etc/systemd/system/configui.service +[Unit] +Description=CoonfigUI Server + +[Service] +WorkingDirectory=/home/ubuntu/ConfigUI +ExecStart=configui -log access.log -f conf.json -bind 0.0.0.0:80 +Restart=always + +[Install] +WantedBy=multi-user.target +``` + ## Api ### Files