From 4e80ff0f6dd62be1c6e1c1327c06f4a189289307 Mon Sep 17 00:00:00 2001 From: dado Date: Sun, 5 Jan 2025 14:27:04 +0100 Subject: [PATCH] aggiunto servizio mollysocket --- mollysocket/mollysocket.service | 31 +++++++++++++++++++++++++++++++ mollysocket/prod.toml | 5 +++++ 2 files changed, 36 insertions(+) create mode 100644 mollysocket/mollysocket.service create mode 100644 mollysocket/prod.toml diff --git a/mollysocket/mollysocket.service b/mollysocket/mollysocket.service new file mode 100644 index 0000000..46bf366 --- /dev/null +++ b/mollysocket/mollysocket.service @@ -0,0 +1,31 @@ +# /etc/systemd/system/mollysocket.service +[Unit] +Description=MollySocket +After=network-online.target + +[Service] +Type=simple +Environment="RUST_LOG=info" +Environment="MOLLY_CONF=/opt/mollysocket/prod.toml" +WorkingDirectory=/opt/mollysocket/ + +SetCredentialEncrypted=ms_vapid: \ + ********************************************************************* \ + ********************************************************************* \ + ************************************** +Environment=MOLLY_VAPID_KEY_FILE=%d/ms_vapid + +User=mollysocket +Group=mollysocket +UMask=0007 + +ExecStart=/opt/mollysocket/ms server +KillSignal=SIGINT + +Restart=on-failure + +# Configures the time to wait before service is stopped forcefully. +TimeoutStopSec=5 + +[Install] +WantedBy=multi-user.target \ No newline at end of file diff --git a/mollysocket/prod.toml b/mollysocket/prod.toml new file mode 100644 index 0000000..bf81393 --- /dev/null +++ b/mollysocket/prod.toml @@ -0,0 +1,5 @@ +db = '/opt/mollysocket/mollysocket.db' +allowed_endpoints = ['https://ntfy.ilnostropianetaselvaggio.it', 'https://up.conversations.im'] +allowed_uuids = ['*'] +webserver = true +port = 8020 \ No newline at end of file