UbuntuIRC / 2015 /09 /10 /#cloud-init.txt
niansa
Initial commit
4aa5fce
[15:21] <arkin> http://pastie.org/private/aedriwyhrntvtylnf0txgg
[15:21] <arkin> can anyone help me clean this up? I'm getting some errors atm
[15:34] <smoser> arkin, you're probably facing shell quote issues
[15:34] <smoser> avoid shell quote
[15:35] <smoser> instead of 'runcmd' having a bunch of strings, populate it with a bunch of arrays
[15:35] <smoser> not this
[15:35] <smoser> runcmd:
[15:35] <smoser> - mysql -e 'CREATE DATABASE \`{{ mysql_db }}\`;'
[15:35] <smoser> but this
[15:35] <smoser> runcmd:
[15:35] <smoser> - [mysql, -e 'CREATE DATABASE "{{ mysql_db }}";'
[15:36] <smoser> or whatever would be the right syntax there.
[15:36] <smoser> but basically then you can avoid shell getting in the way.
[17:08] <arkin> yea I am smoser
[17:09] <arkin> I fixed it messing around with " ' ` variations
[17:09] <arkin> thanks for your reply
[17:14] <smoser> arkin, really, though. get rid of the shell interpretation
[17:14] <smoser> its much more sane.