From 0d59c7a8c2801d67dcb29702186663f3a81ab0bf Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 30 Jan 2022 16:38:06 +0100 Subject: [PATCH] Fix --- conf/.env | 2 +- conf/systemd.service | 22 ++++++++++++++++++---- 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/conf/.env b/conf/.env index 0f72d24..1121786 100644 --- a/conf/.env +++ b/conf/.env @@ -1,6 +1,6 @@ MINIO_ROOT_USER=__APP__ MINIO_VOLUMES="__DATADIR__/" -MINIO_OPTS="-C __FINAL_PATH__/ --address 127.0.0.1:__PORT__ --console-address :__CONSOLE_PORT__" +MINIO_OPTS="-C __FINAL_PATH__/minio --address 127.0.0.1:__PORT__ --console-address :__CONSOLE_PORT__" MINIO_ROOT_PASSWORD=__MINIO_KEY__ MINIO_ETCD_CLIENT_CERT="/etc/yunohost/certs/__DOMAIN__/crt.pem" diff --git a/conf/systemd.service b/conf/systemd.service index 65b39ab..a349b45 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -1,16 +1,30 @@ [Unit] -Description=A High Performance, Kubernetes Native Object Storage -After=network.target +Description=MinIO +Documentation=https://docs.min.io +Wants=network-online.target +After=network-online.target +AssertFileIsExecutable=__FINALPATH__/minio [Service] Type=simple User=__APP__ Group=__APP__ +ProtectProc=invisible WorkingDirectory=__FINAL_PATH__/ EnvironmentFile=__FINAL_PATH__/.env ExecStart=__FINALPATH__/minio server $MINIO_OPTS $MINIO_VOLUMES -StandardOutput=append:/var/log/__APP__/__APP__.log -StandardError=inherit +# Let systemd restart this service always +Restart=always + +# Specifies the maximum file descriptor number that can be opened by this process +LimitNOFILE=1048576 + +# Specifies the maximum number of threads this process can create +TasksMax=infinity + +# Disable timeout logic and wait until process is stopped +TimeoutStopSec=infinity +SendSIGKILL=no [Install] WantedBy=multi-user.target