From e136d3edbdb6749d4559939dc9fcbc11d166e34c Mon Sep 17 00:00:00 2001 From: Guilhem Moulin Date: Wed, 31 May 2017 17:39:57 +0200 Subject: =?UTF-8?q?/lib/systemd/system=20=E2=86=92=20/etc/systemd/system?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../lists/files/etc/systemd/system/wwsympa.service | 25 ++++++++++++++++++++++ .../lists/files/etc/systemd/system/wwsympa.socket | 11 ++++++++++ .../lists/files/lib/systemd/system/wwsympa.service | 25 ---------------------- .../lists/files/lib/systemd/system/wwsympa.socket | 11 ---------- roles/lists/tasks/sympa.yml | 4 ++-- 5 files changed, 38 insertions(+), 38 deletions(-) create mode 100644 roles/lists/files/etc/systemd/system/wwsympa.service create mode 100644 roles/lists/files/etc/systemd/system/wwsympa.socket delete mode 100644 roles/lists/files/lib/systemd/system/wwsympa.service delete mode 100644 roles/lists/files/lib/systemd/system/wwsympa.socket (limited to 'roles/lists') diff --git a/roles/lists/files/etc/systemd/system/wwsympa.service b/roles/lists/files/etc/systemd/system/wwsympa.service new file mode 100644 index 0000000..4e3d94b --- /dev/null +++ b/roles/lists/files/etc/systemd/system/wwsympa.service @@ -0,0 +1,25 @@ +[Unit] +Description=WWSympa Service +After=network.target +PartOf=sympa.service +Requires=wwsympa.socket + +[Service] +StandardInput=socket +User=sympa +Group=sympa +ExecStart=/usr/lib/cgi-bin/sympa/wwsympa.fcgi + +# Hardening +NoNewPrivileges=yes +PrivateDevices=yes +ProtectHome=yes +ProtectSystem=full +PrivateTmp=yes +ReadOnlyDirectories=/ +ReadWriteDirectories=-/var/lib/sympa +ReadWriteDirectories=-/var/run/sympa +ReadWriteDirectories=-/var/spool/sympa + +[Install] +WantedBy=multi-user.target diff --git a/roles/lists/files/etc/systemd/system/wwsympa.socket b/roles/lists/files/etc/systemd/system/wwsympa.socket new file mode 100644 index 0000000..10fe721 --- /dev/null +++ b/roles/lists/files/etc/systemd/system/wwsympa.socket @@ -0,0 +1,11 @@ +[Unit] +Description=WWSympa Listen Socket + +[Socket] +SocketUser=www-data +SocketGroup=www-data +SocketMode=0600 +ListenStream=/run/wwsympa.socket + +[Install] +WantedBy=sockets.target diff --git a/roles/lists/files/lib/systemd/system/wwsympa.service b/roles/lists/files/lib/systemd/system/wwsympa.service deleted file mode 100644 index 4e3d94b..0000000 --- a/roles/lists/files/lib/systemd/system/wwsympa.service +++ /dev/null @@ -1,25 +0,0 @@ -[Unit] -Description=WWSympa Service -After=network.target -PartOf=sympa.service -Requires=wwsympa.socket - -[Service] -StandardInput=socket -User=sympa -Group=sympa -ExecStart=/usr/lib/cgi-bin/sympa/wwsympa.fcgi - -# Hardening -NoNewPrivileges=yes -PrivateDevices=yes -ProtectHome=yes -ProtectSystem=full -PrivateTmp=yes -ReadOnlyDirectories=/ -ReadWriteDirectories=-/var/lib/sympa -ReadWriteDirectories=-/var/run/sympa -ReadWriteDirectories=-/var/spool/sympa - -[Install] -WantedBy=multi-user.target diff --git a/roles/lists/files/lib/systemd/system/wwsympa.socket b/roles/lists/files/lib/systemd/system/wwsympa.socket deleted file mode 100644 index 10fe721..0000000 --- a/roles/lists/files/lib/systemd/system/wwsympa.socket +++ /dev/null @@ -1,11 +0,0 @@ -[Unit] -Description=WWSympa Listen Socket - -[Socket] -SocketUser=www-data -SocketGroup=www-data -SocketMode=0600 -ListenStream=/run/wwsympa.socket - -[Install] -WantedBy=sockets.target diff --git a/roles/lists/tasks/sympa.yml b/roles/lists/tasks/sympa.yml index 981de8a..4aaa2c9 100644 --- a/roles/lists/tasks/sympa.yml +++ b/roles/lists/tasks/sympa.yml @@ -75,8 +75,8 @@ - meta: flush_handlers - name: Copy wwsympa.{service,socket} - copy: src=lib/systemd/system/{{ item }} - dest=/lib/systemd/system/{{ item }} + copy: src=etc/systemd/system/{{ item }} + dest=/etc/systemd/system/{{ item }} owner=root group=root mode=0644 notify: -- cgit v1.2.3