title: Why does an SSH remote command get fewer environment variables then when run manually?
body: <p>I have a command that runs fine if I ssh to a machine and run it, but fails when I try to run it using a remote ssh command like : </p>
  
  <pre><code>ssh user@IP &lt;command&gt;
  </code></pre>
  
  <p>Comparing the output of "env" using both methods resutls in different environments. When I manually login to the machine and run env, I get much more environment variables then when I run :</p>
  
  <pre><code>ssh user@IP "env"
  </code></pre>
  
  <p>Any idea why ?</p>