Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix clevis-hook.sh installation #23

Closed
cbiedl opened this issue Nov 11, 2017 · 1 comment
Closed

Fix clevis-hook.sh installation #23

cbiedl opened this issue Nov 11, 2017 · 1 comment

Comments

@cbiedl
Copy link

cbiedl commented Nov 11, 2017

As I learned from my first alpha tester, substitution in clevis-hook.sh does not happen. Suggested fix below.

--- a/src/dracut/Makefile.am
+++ b/src/dracut/Makefile.am
@@ -8,5 +8,5 @@ EXTRA_DIST=clevis-hook.sh.in
%: %.in
$(AM_V_GEN)mkdir -p $(dir $@)
$(AM_V_GEN)$(SED) \

  •           -e 's,@libexedir\@,$(libexecdir),g' \
    
  •           -e 's,@libexecdir\@,$(libexecdir),g' \
              $(srcdir)/$@.in > $@
    

--- a/src/dracut/clevis-hook.sh.in
+++ b/src/dracut/clevis-hook.sh.in
@@ -1,2 +1,2 @@
#!/bin/bash
-@libexec@/clevis-luks-askpass
+@libexecdir@/clevis-luks-askpass

@martinezjavier
Copy link
Contributor

@cbiedl I found the same issue, but I also needed the following change:

diff --git a/src/dracut/module-setup.sh b/src/dracut/module-setup.sh.in
similarity index 97%
rename from src/dracut/module-setup.sh
rename to src/dracut/module-setup.sh.in
index efd69ec46f4e..9831b9dead5a 100755
--- a/src/dracut/module-setup.sh
+++ b/src/dracut/module-setup.sh.in
@@ -38,7 +38,7 @@ install() {
         clevis-decrypt-tang \
         clevis-decrypt-tpm2 \
         clevis-decrypt-sss \
-        clevis-luks-askpass \
+        @libexecdir@/clevis-luks-askpass \
         clevis-decrypt \
         tpm2_createprimary \
         tpm2_unseal \

Do you think that you could propose a proper pull request fixing these?

npmccallum added a commit to npmccallum/clevis that referenced this issue Nov 13, 2017
We weren't generating the path to clevis-luks-askpass correctly in the
dracut module.

Fixes latchset#23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants