diff options
10 files changed, 122 insertions, 0 deletions
diff --git a/debian/taler-auditor.taler-auditor-httpd.service b/debian/taler-auditor.taler-auditor-httpd.service index ac68e41c8..97116a8de 100644 --- a/debian/taler-auditor.taler-auditor-httpd.service +++ b/debian/taler-auditor.taler-auditor-httpd.service @@ -1,13 +1,29 @@ [Unit] Description=GNU Taler payment system auditor REST API After=postgres.service network.target +PartOf=taler-auditor.target [Service] User=taler-auditor-httpd Type=simple Restart=on-failure RestartPreventExitStatus=9 + +# Disable the service if more than 5 restarts are encountered within 5s. +# These are usually the systemd defaults, but can be overwritten, thus we set +# them here explicitly, as the exchange code assumes StartLimitInterval +# to be >=5s. +StartLimitBurst=5 +StartLimitInterval=5s + ExecStart=/usr/bin/taler-auditor-httpd -c /etc/taler/taler.conf -L INFO +StandardOutput=journal +StandardError=journal +PrivateTmp=yes +PrivateDevices=yes +ProtectSystem=full +Slice=taler-auditor.slice + [Install] WantedBy=multi-user.target diff --git a/debian/taler-auditor.taler-auditor.slice b/debian/taler-auditor.taler-auditor.slice new file mode 100644 index 000000000..6293e8ab1 --- /dev/null +++ b/debian/taler-auditor.taler-auditor.slice @@ -0,0 +1,7 @@ +[Unit] +Description=Slice for GNU taler auditor processes +Before=slices.target + +[Slice] +# Add settings that should affect all GNU Taler auditor +# components here. diff --git a/debian/taler-auditor.taler-auditor.target b/debian/taler-auditor.taler-auditor.target new file mode 100644 index 000000000..e2e370fdf --- /dev/null +++ b/debian/taler-auditor.taler-auditor.target @@ -0,0 +1,15 @@ +[Unit] +Description=GNU Taler auditor +After=postgres.service network.target + +Wants=taler-auditor-httpd.service +Wants=taler-helper-auditor-aggregation.service +Wants=taler-helper-auditor-coins.service +Wants=taler-helper-auditor-deposits.service +Wants=taler-helper-auditor-purses.service +Wants=taler-helper-auditor-reserves.service +Wants=taler-helper-auditor-wire-credit.service +Wants=taler-helper-auditor-wire-debit.service + +[Install] +WantedBy=multi-user.target diff --git a/debian/taler-auditor.taler-helper-auditor-aggregation.service b/debian/taler-auditor.taler-helper-auditor-aggregation.service index f8617d4f1..d226d7236 100644 --- a/debian/taler-auditor.taler-helper-auditor-aggregation.service +++ b/debian/taler-auditor.taler-helper-auditor-aggregation.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking aggregations
After=postgres.service
+PartOf=taler-auditor.target
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
\ No newline at end of file diff --git a/debian/taler-auditor.taler-helper-auditor-coins.service b/debian/taler-auditor.taler-helper-auditor-coins.service index 86fbb364b..1c6f02de2 100644 --- a/debian/taler-auditor.taler-helper-auditor-coins.service +++ b/debian/taler-auditor.taler-helper-auditor-coins.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking coin histories
After=postgres.service
+PartOf=taler-auditor.target
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
\ No newline at end of file diff --git a/debian/taler-auditor.taler-helper-auditor-deposits.service b/debian/taler-auditor.taler-helper-auditor-deposits.service index d95512feb..e474314cf 100644 --- a/debian/taler-auditor.taler-helper-auditor-deposits.service +++ b/debian/taler-auditor.taler-helper-auditor-deposits.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking confirmation deposits
After=postgres.service
+PartOf=taler-auditor.target
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
\ No newline at end of file diff --git a/debian/taler-auditor.taler-helper-auditor-purses.service b/debian/taler-auditor.taler-helper-auditor-purses.service index 89f04b874..8429a8c8f 100644 --- a/debian/taler-auditor.taler-helper-auditor-purses.service +++ b/debian/taler-auditor.taler-helper-auditor-purses.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking purses
After=postgres.service
+Slice=taler-auditor.slice
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
diff --git a/debian/taler-auditor.taler-helper-auditor-reserves.service b/debian/taler-auditor.taler-helper-auditor-reserves.service index d1f007dd5..388ae5f1a 100644 --- a/debian/taler-auditor.taler-helper-auditor-reserves.service +++ b/debian/taler-auditor.taler-helper-auditor-reserves.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking reserves
After=postgres.service
+PartOf=taler-auditor.target
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
\ No newline at end of file diff --git a/debian/taler-auditor.taler-helper-auditor-wire-credit.service b/debian/taler-auditor.taler-helper-auditor-wire-credit.service index d810227a0..c6cdfc5de 100644 --- a/debian/taler-auditor.taler-helper-auditor-wire-credit.service +++ b/debian/taler-auditor.taler-helper-auditor-wire-credit.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking for missing wire credit transfers
After=postgres.service
+PartOf=taler-auditor.target
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
\ No newline at end of file diff --git a/debian/taler-auditor.taler-helper-auditor-wire-debit.service b/debian/taler-auditor.taler-helper-auditor-wire-debit.service index 179f29aa8..524756da6 100644 --- a/debian/taler-auditor.taler-helper-auditor-wire-debit.service +++ b/debian/taler-auditor.taler-helper-auditor-wire-debit.service @@ -1,6 +1,7 @@ [Unit]
Description=GNU Taler auditor helper checking outgoing wire debit operations
After=postgres.service
+PartOf=taler-auditor.target
[Service]
User=taler-auditor-httpd
@@ -13,3 +14,14 @@ PrivateTmp=yes PrivateDevices=yes
ProtectSystem=full
RuntimeMaxSec=3600s
+
+StandardOutput=journal
+StandardError=journal
+Slice=taler-auditor.slice
+
+# Disable the service if more than 5 restarts are encountered within 5s.
+# These are usually the systemd defaults, but can be overwritten, thus we set
+# them here explicitly, as the exchange code assumes StartLimitInterval
+# to be >=5s.
+StartLimitBurst=5
+StartLimitInterval=5s
\ No newline at end of file |