title: Spring roo Cannot invoke Tomcat manager: Connection refused: connect
body: <p>I have a problem deploying my <strong>Spring Roo</strong> application with Maven, using <strong>Spring Tools Suite 3.5.1</strong> . I've been reading posts like this <a href="https://stackoverflow.com/questions/5410479/tomcat-maven-plugin-403-error">tomcat-maven-plugin 403 error</a> but I continue with the following error:</p>
  
  <pre><code>Failed to execute goal org.apache.tomcat.maven:tomcat7-maven-plugin:2.2:redeploy (default-cli) on project prueba: Cannot invoke Tomcat manager: Connection refused: connect -&gt; [Help 1]
  </code></pre>
  
  <p>I'm running the maven doing this:</p>
  
  <p>Right click over the project => Run as => Run configurations => New Maven Build => Goals: tomcat7:deploy</p>
  
  <p>I've set my config files like this:</p>
  
  <p><strong>pom.xml</strong></p>
  
  <pre><code>        &lt;plugin&gt;
              &lt;groupId&gt;org.apache.tomcat.maven&lt;/groupId&gt;
              &lt;artifactId&gt;tomcat7-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.2&lt;/version&gt;
              &lt;configuration&gt;
                  &lt;url&gt;http://127.0.0.1:8080/manager/text&lt;/url&gt;
                  &lt;server&gt;tomcat&lt;/server&gt;
                  &lt;path&gt;/prueba&lt;/path&gt;
              &lt;/configuration&gt;
          &lt;/plugin&gt;
  </code></pre>
  
  <p><strong>tomcat-users.xml</strong></p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;tomcat-users&gt;
      &lt;role rolename="manager-gui"/&gt;
      &lt;role rolename="manager-script"/&gt;
      &lt;user username="tomcat" password="s3cret" roles="manager-script,manager-gui"/&gt;
  &lt;/tomcat-users&gt;
  </code></pre>
  
  <p><strong>settings.xml</strong></p>
  
  <pre><code>&lt;settings&gt;
    &lt;servers&gt;
      &lt;server&gt;
        &lt;id&gt;myserver&lt;/id&gt;
        &lt;username&gt;tomcat&lt;/username&gt;
        &lt;password&gt;s3cret&lt;/password&gt;
      &lt;/server&gt;
    &lt;/servers&gt;
  &lt;/settings&gt;
  </code></pre>
  
  <p>Some posts are in controversy because of this line </p>
  
  <pre><code>&lt;url&gt;http://127.0.0.1:8080/manager/text&lt;/url&gt;
  </code></pre>
  
  <p>They say I have to put <strong>html</strong> instead of <strong>text</strong> but It doesn't works and I can't rid of this error.</p>
  
  <p>Thanks in advance</p>