Browse Source

90crypt: call systemd commands only if systemd binaries are there

master
Amadeusz Żołnowski 13 years ago committed by Harald Hoyer
parent
commit
585b3b37c0
  1. 7
      modules.d/90crypt/crypt-run-generator.sh

7
modules.d/90crypt/crypt-run-generator.sh

@ -23,6 +23,9 @@ if strstr "$(cryptsetup --help)" "allow-discards"; then @@ -23,6 +23,9 @@ if strstr "$(cryptsetup --help)" "allow-discards"; then
fi

echo "$luks $dev none $allowdiscards" >> /etc/crypttab
systemctl daemon-reload
systemctl start cryptsetup.target

if command -v systemctl >/dev/null; then
systemctl daemon-reload
systemctl start cryptsetup.target
fi
exit 0

Loading…
Cancel
Save