Kumi
0a4061b499
This commit introduces the `lobechat-updater` script to update a local LobeChat instance automatically. |
||
---|---|---|
contrib | ||
LICENSE | ||
lobechat-updater | ||
README.md |
LobeChat Updater
This is a simple script that updates the LobeChat application. It is designed to be run on a server, and will automatically update the application when a new version is tagged.
The script assumes that you use a systemd service to run LobeChat. If you do not, you will need to modify the script to suit your needs.
Installation
-
Clone this repository to your server.
git clone https://git.private.coffee/kumi/lobechat-updater.git cd lobechat-updater
-
Install the
lobechat-updater
to/usr/local/bin/
:sudo install lobechat-updater /usr/local/bin/
-
Install the systemd service and timer:
sudo cp contrib/lobechat-updater.service /etc/systemd/system/ sudo cp contrib/lobechat-updater.timer /etc/systemd/system/ sudo systemctl enable --now lobechat-updater.timer
This will install the updater script to /usr/local/bin/lobechat-updater
, and will set up a systemd timer to run the updater every 5 minutes.
Configuration
Modify the LOBECHAT_DIR
variable in /usr/local/bin/lobechat-updater
to point to the directory where LobeChat is installed. By default, this is /opt/lobechat
. If the user running LobeChat is not lobechat
, you will also need to modify the LOBECHAT_USER
variable.
To change the update interval, edit the OnBootSec
and OnUnitActiveSec
lines in /etc/systemd/system/lobechat-updater.timer
.
License
This project is licensed under the MIT License. See the LICENSE file for details.