By default, the tomcat plugin uses admin as a user name and no password. If you don't specify them in your POM, your use modify your tomcat-users.xmlfile as follows: <?xml version='1.0' encoding='utf-8'?> <tomcat-users> <role rolename="tomcat"/> <role rolename="role1"/> <role rolename="manager"/> <role rolename="admin"/> <user username="tomcat" password="tomcat" roles="tomcat"/> <user username="both" password="tomcat" roles="tomcat,role1"/> <user username="role1" password="tomcat" roles="role1"/> <user username="manager" password="manager" roles="manager"/> *<user username="admin" password="" roles="admin,manager"/>* </tomcat-users>
Jeff On Jan 11, 2008 2:36 PM, Thomas Chang <[EMAIL PROTECTED]> wrote: > Now I change the "tomcat-users.xml" as follow, but it's the same. > > <?xml version='1.0' encoding='utf-8'?> > <tomcat-users> > <role rolename="tomcat"/> > <role rolename="role1"/> > <role rolename="manager"/> > <role rolename="admin"/> > <user username="tomcat" password="tomcat" roles="tomcat"/> > <user username="both" password="tomcat" roles="tomcat,role1"/> > <user username="role1" password="tomcat" roles="role1"/> > <user username="manager" password="manager" roles="manager"/> > <user username="admin" password="admin" roles="admin"/> > </tomcat-users> > > > > Jeff MAURY <[EMAIL PROTECTED]> schrieb: You must have the manager > role so supply tomcat as user and password. > > Regards > Jeff > > > On Jan 11, 2008 2:03 PM, Thomas Chang wrote: > > > Sure. My "tomcat-users.xml" looks as follow. Is it OK? > > > > > > > > > > > > > > > > > > > > > > > > > > > > Jeff MAURY schrieb: You must specify user and > > password because the manager application is > > protected by default. > > > > Jeff > > > > > > On Jan 11, 2008 1:27 PM, Thomas Chang wrote: > > > > > Hi all, > > > > > > I try to deploy a WAR to Tomcat using " > > > mvn tomcat:deploy -Dmaven.tomcat.url=http://localhost:8585/manager". > But > > I > > > got error as follow. What's wrong? > > > > > > [ERROR] BUILD ERROR > > > [INFO] > > > > ------------------------------------------------------------------------ > > > [INFO] Cannot invoke Tomcat manager > > > > > > Embedded error: Server returned HTTP response code: 401 for URL: > > > http://localhos > > > t:8585/manager/deploy?path=%2FTestWeb&war= > > > [INFO] > > > > ------------------------------------------------------------------------ > > > [INFO] For more information, run Maven with the -e switch > > > [INFO] > > > > ------------------------------------------------------------------------ > > > [INFO] Total time: 10 seconds > > > [INFO] Finished at: Fri Jan 11 13:19:55 CET 2008 > > > [INFO] Final Memory: 6M/11M > > > [INFO] > > > > ------------------------------------------------------------------------ > > > > > > C:\Projects\eclipse_workspace\TestWeb> > > > > > > > > > --------------------------------- > > > Heute schon einen Blick in die Zukunft von E-Mails wagen? Versuchen > > Sie´s > > > mit dem neuen Yahoo! Mail. > > > > > > > > > > > -- > > La mélancolie c'est communiste > > Tout le monde y a droit de temps en temps > > La mélancolie n'est pas capitaliste > > C'est même gratuit pour les perdants > > La mélancolie c'est pacifiste > > On ne lui rentre jamais dedans > > La mélancolie oh tu sais ça existe > > Elle se prend même avec des gants > > La mélancolie c'est pour les syndicalistes > > Il faut juste sa carte de permanent > > > > Miossec (2006) > > > > http://www.jeffmaury.com > > http://riadiscuss.jeffmaury.com > > > > > > > > --------------------------------- > > Beginnen Sie den Tag mit den neuesten Nachrichten. Machen Sie Yahoo! zu > > Ihrer Startseite! > > > > > > -- > La mélancolie c'est communiste > Tout le monde y a droit de temps en temps > La mélancolie n'est pas capitaliste > C'est même gratuit pour les perdants > La mélancolie c'est pacifiste > On ne lui rentre jamais dedans > La mélancolie oh tu sais ça existe > Elle se prend même avec des gants > La mélancolie c'est pour les syndicalistes > Il faut juste sa carte de permanent > > Miossec (2006) > > http://www.jeffmaury.com > http://riadiscuss.jeffmaury.com > > > > --------------------------------- > Heute schon einen Blick in die Zukunft von E-Mails wagen? Versuchen Sie´s > mit dem neuen Yahoo! Mail. > -- La mélancolie c'est communiste Tout le monde y a droit de temps en temps La mélancolie n'est pas capitaliste C'est même gratuit pour les perdants La mélancolie c'est pacifiste On ne lui rentre jamais dedans La mélancolie oh tu sais ça existe Elle se prend même avec des gants La mélancolie c'est pour les syndicalistes Il faut juste sa carte de permanent Miossec (2006) http://www.jeffmaury.com http://riadiscuss.jeffmaury.com
