diff --git a/flightctl/apps/broken/etc/flightctl/hooks.d/afterupdating/30-broken.yaml b/flightctl/apps/broken/etc/flightctl/hooks.d/afterupdating/30-broken.yaml new file mode 100644 index 0000000..603ebdc --- /dev/null +++ b/flightctl/apps/broken/etc/flightctl/hooks.d/afterupdating/30-broken.yaml @@ -0,0 +1,5 @@ +- if: + - path: /etc/systemd/system/broken.service + op: [created, updated] + run: /bin/sh -Eeuo pipefail -c 'systemctl enable broken.service ; systemctl restart --no-block broken.service' + timeout: 5m diff --git a/flightctl/apps/broken/etc/systemd/system/broken.service b/flightctl/apps/broken/etc/systemd/system/broken.service new file mode 100644 index 0000000..39fece2 --- /dev/null +++ b/flightctl/apps/broken/etc/systemd/system/broken.service @@ -0,0 +1,11 @@ +[Unit] +Description=Broken service +After=network-online.target +Wants=network-online.target + +[Service] +Type=oneshot +ExecStart=/bin/sh -c 'echo "I am DEAD !!!" ; exit 1' + +[Install] +WantedBy=multi-user.target