summaryrefslogtreecommitdiff
path: root/src/cryptsetup-generator.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-11-12 00:39:17 +0100
committerLennart Poettering <lennart@poettering.net>2010-11-12 00:40:27 +0100
commit7f4e08056de0184b205a20632e62db73d299937e (patch)
tree09633a6d941c08d6c17797425f3b592742fe7c4e /src/cryptsetup-generator.c
parent5a1e99375d03bc88795d68c66bf3933dd04c1015 (diff)
cryptsetup: hook up tool with ask-password
Diffstat (limited to 'src/cryptsetup-generator.c')
-rw-r--r--src/cryptsetup-generator.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cryptsetup-generator.c b/src/cryptsetup-generator.c
index 792c1f52d7..73c367935f 100644
--- a/src/cryptsetup-generator.c
+++ b/src/cryptsetup-generator.c
@@ -102,7 +102,7 @@ static int create_disk(
"DefaultDependencies=no\n"
"BindTo=%s\n"
"After=systemd-readahead-collect.service systemd-readahead-replay.service %s\n"
- "Before=dev-mapper-%%f.device shutdown.target\n",
+ "Before=dev-mapper-%%i.device shutdown.target\n",
d, d);
if (password && (streq(password, "/dev/urandom") ||
@@ -116,8 +116,8 @@ static int create_disk(
"Type=oneshot\n"
"RemainAfterExit=yes\n"
"ExecStart=" SYSTEMD_CRYPTSETUP_PATH " %s '%s' '%s' '%s' '%s'\n"
- "ExecStop=" SYSTEMD_CRYPTSETUP_PATH " remove '%s'\n",
- options && has_option(options, "swap") ? "format" : "create",
+ "ExecStop=" SYSTEMD_CRYPTSETUP_PATH " detach '%s'\n",
+ options && has_option(options, "swap") ? "format-and-attach" : "attach",
name, u, strempty(password), strempty(options),
name);