Python - Placing a string that looks like json on a remote server but quotes are being stripped
<p>I am placing a file on a remote machine using paramiko ssh as follows.</p>

<pre><code>rl = str(""" {"run_list":["role[monitor_server]"]}""")
cmd = """sudo touch /etc/chef/first-boot.json;sudo su - -c 'echo "%s" &gt;&gt; /etc/chef/first-boot.json'""" % (rl)
ssh.exec_command(cmd)
</code></pre>

<p>However, when I look at the file it looks like this.</p>

<pre><code>{run_list:[role[monitor_server]]}
</code></pre>

<p>I need it to to look this this:
   {"run_list":["role[monitor_server]"]}</p>

<p>How to I keep the quotes?</p>
