title: Running maven command remotely using ssh
body: <p>Trying to execute a script on the remote aws centos machine using the command mentioned below</p>
  
  <pre><code>ssh root@hostname script
  </code></pre>
  
  <p>Everything works fine until the script comes to a maven command. For example "mvn package" in the script. Getting the error below.
      bash: mvn: command not found</p>