remilapeyre / vault-acme

Mozilla Public License 2.0
94 stars 24 forks source link

The plugin doesn't work on Vault in Docker-based on Alpine Linux #11

Closed binlab closed 4 years ago

binlab commented 4 years ago

Tested on release v0.0.1

# ls -la /etc/vault/plugins/vault-plugin-secrets-acme
-rwxr-xr-x    1 root     root      45055347 May  6 08:10 /etc/vault/plugins/vault-plugin-secrets-acme
# /etc/vault/plugins/vault-plugin-secrets-acme
sh: /etc/vault/plugins/vault-plugin-secrets-acme: not found

Seems to plugin compiled without the support of Alpine Linux images. Can you fix it? Thanks

remilapeyre commented 4 years ago

Hi @binlab, can you please give more information regarding how you compiled the plugin and what Docker image you are using? Do the files at https://github.com/remilapeyre/vault-acme/releases work?

I've tried on Alpine and it seems to work correctly:

➜  vault-acme git:(master) make clean
rm -rf build/*
➜  vault-acme git:(master) GOOS=linux GOARCH=amd64 make                             
go build -o build ./...
➜  vault-acme git:(master) docker run --rm -it -v $PWD/build:/build alpine:latest sh
/ # /build/acme 
This binary is a plugin. These are not meant to be executed directly.
Please execute the program that consumes these plugins, which will
load any plugins automatically
remilapeyre commented 4 years ago

Nevermind, I just saw that the CI builds dynamically linked binaries which cannot work with Alpine.

remilapeyre commented 4 years ago

Thanks for reporting this issue @binlab, the binaries at https://github.com/remilapeyre/vault-acme/releases/tag/v0.0.2 should work now.

binlab commented 4 years ago

Now it works fine. Thanks, @remilapeyre!