resize2fs

19 Feb 2021

LibreTranslate

Recently a friend told me about LibreTranslate.

I immediatly liked the project and spinned up the new url translate.resize2fs.de and requested a new letsencrypt certificate via acme.sh.

I choose pip to install the software.

apt install python3-pip
pip3 install --upgrade pip
pip3 install libretranslate
useradd -m -s /sbin/nologin libretranslate

And I also create a systemd unit file for the service.

cat /etc/systemd/system/libretranslate.service


[Unit]
Description=libretranslate
Documentation=https://github.com/uav4geo/LibreTranslate
After=network.target

[Service]
ExecStart=/usr/local/bin/libretranslate --frontend-language-target de
ExecReload=/bin/kill -HUP $MAINPID
Restart=on-failure
User=libretranslate

[Install]
WantedBy=multi-user.target

Now reload systemd and enable/start the service.

systemctl daemon-reload
systemctl enable --now libretranslate

Now LibreTranslate runs on http://localhost:5000

Choose your favorit webserver, create a vhost and forward request to that.

I choosed apache for that.

Have a nice weekend!