I have mounted a binary (tini init) to the /executables mountPath. The docker image is busybox:latest
Mounting:
- name: executables
mountPath: /executablesVolume creation:
- name: executables
emptyDir: {}I ran a sidecar container that adds the tini binary to this volume.
inside the /executables directory after attaching to the container:
/executables # ls
tini
/executables # pwd
/executables
/executables # ls
tini
/executables # ./tini
sh: ./tini: not found
/executables # Everything's alright but when I try executing it, it shows not found when the file is right there! driving me nuts. Please help!
If you just download the binary you have change the permission and do a chmod +x tini before try to launch it.
Solved this using a static build for the binary, turns out it's very relevant to this: https://unix.stackexchange.com/questions/18061/why-does-sh-say-not-found-when-its-definitely-there