Try running knife solo cook with a -i parameter that has characters in it that need shell escaping.
For example:
knife solo cook -i "$HOME/Projects - Current/private_key.pem" user@example.com. Even though the path gets passed properly into the invocation of knife solo cook, it does not get escaped when knife solo then passes it to rsync:
Uploading the kitchen...
Warning: Identity file /home/user/Projects not accessible: No such file or directory.
bash: - : invalid option
Usage: bash [GNU long option] [option] ...
bash [GNU long option] [option] script-file ...
GNU long options:
--debug
--debugger
--dump-po-strings
--dump-strings
--help
--init-file
--login
--noediting
--noprofile
--norc
--posix
--protected
--rcfile
--rpm-requires
--restricted
--verbose
--version
Shell options:
-irsD or -c command or -O shopt_option (invocation only)
-abefhkmnptuvxBCHP or -o option
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(226) [sender=3.1.1]
ERROR: RuntimeError: Failed to launch command ["rsync", "-rL", "--rsh=ssh user@example.com -i /home/user/Projects - Current/private_key.pem"```
Try running
knife solo cook
with a-i
parameter that has characters in it that need shell escaping.For example:
knife solo cook -i "$HOME/Projects - Current/private_key.pem" user@example.com
. Even though the path gets passed properly into the invocation ofknife solo cook
, it does not get escaped when knife solo then passes it torsync
: