From f9e7c605d79d9f7089682d61e12f3a22429fe4d6 Mon Sep 17 00:00:00 2001 From: Ivan Davydov Date: Wed, 18 Dec 2024 21:58:52 +0300 Subject: Add environment file --- .env | 0 README.md | 2 +- libretranslate.service | 1 + 3 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 .env diff --git a/.env b/.env new file mode 100644 index 0000000..e69de29 diff --git a/README.md b/README.md index e5d032e..3535967 100644 --- a/README.md +++ b/README.md @@ -49,4 +49,4 @@ sudo systemctl status libretranslate #### Configuration 1. Find the setting you would like to change in the [LibreTranslate settings](https://github.com/LibreTranslate/LibreTranslate#arguments) -2. Add the setting to the environment of your libretranslate.service SystemD file +2. Add the setting to the `.env` file diff --git a/libretranslate.service b/libretranslate.service index d422ccb..1e28adf 100644 --- a/libretranslate.service +++ b/libretranslate.service @@ -8,6 +8,7 @@ Group=www-data WorkingDirectory=/home/libretranslate/LibreTranslate Environment="PATH=/home/libretranslate/LibreTranslate/env/bin" ExecStart=/home/libretranslate/LibreTranslate/env/bin/gunicorn --workers 3 --bind unix:libretranslate.sock -m 007 wsgi:app +EnvironmentFile=/home/libretranslate/LibreTranslate-init/.env Restart=always ExecReload=/bin/kill -s HUP $MAINPID KillMode=mixed -- cgit v1.2.3