# Jenkins not picking up my context root with tomcat 9 deployment

**URL:** <https://community.jenkins.io/t/jenkins-not-picking-up-my-context-root-with-tomcat-9-deployment/823>\
**Category:** Using Jenkins\
**Created:** [November 16, 2021, 9:26pm UTC](https://community.jenkins.io/t/jenkins-not-picking-up-my-context-root-with-tomcat-9-deployment/823 "2021-11-16T21:26:30Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kenkins](https://avatars.discourse-cdn.com/v4/letter/k/59ef9b/32.png) [@kenkins](https://community.jenkins.io/u/kenkins)\
**Post date:** [November 16, 2021, 9:26pm UTC](https://community.jenkins.io/t/jenkins-not-picking-up-my-context-root-with-tomcat-9-deployment/823/1 "2021-11-16T21:26:31Z")

</div>

Hi i deployed my first job successfully to tomcat 9.x but instead of it going to the specified context root /test instead it used the war filename as the context root can you help at all here please?

[DeployPublisher][INFO] Attempting to deploy 1 war file(s)  
[DeployPublisher][INFO] Deploying /var/jenkins\_home/workspace/Test-deploy-from-jenkins-tomcat-test/SampleWebApp.war to container Tomcat 9.x Remote with context /test  
[/var/jenkins\_home/workspace/Test-deploy-from-jenkins-tomcat-test/SampleWebApp.war] is not deployed. Doing a fresh deployment.  
Deploying [/var/jenkins\_home/workspace/Test-deploy-from-jenkins-tomcat-test/SampleWebApp.war]  
Finished: SUCCESS

Looking on Tomcat manager logs i see no mention of context root

16-Nov-2021 21:07:23.213 INFO [http-nio-8080-exec-256] org.apache.catalina.core.ApplicationContext.log Manager: deploy: Deploying web application ‘/SampleWebApp’  
16-Nov-2021 21:07:23.213 INFO [http-nio-8080-exec-256] org.apache.catalina.core.ApplicationContext.log Manager: Uploading WAR file to /opt/tomcat/webapps/SampleWebApp.war

---

<div class="post-metadata">

**Author:** ![mtughan](https://dub1.discourse-cdn.com/flex013/user_avatar/community.jenkins.io/mtughan/32/91_2.png) [@mtughan](https://community.jenkins.io/u/mtughan)\
**Post date:** [November 17, 2021, 2:55pm UTC](https://community.jenkins.io/t/jenkins-not-picking-up-my-context-root-with-tomcat-9-deployment/823/2 "2021-11-17T14:55:13Z")

</div>

Hi Ken,

I think you’re using the [Deploy to container plugin](https://plugins.jenkins.io/deploy/), right?

Can you post the snippet of your pipeline that calls the plugin or a screenshot of the configuration if you’re using a freestyle job?

---

<div class="post-metadata">

**Author:** ![kenkins](https://avatars.discourse-cdn.com/v4/letter/k/59ef9b/32.png) [@kenkins](https://community.jenkins.io/u/kenkins)\
**Post date:** [November 18, 2021, 8:40pm UTC](https://community.jenkins.io/t/jenkins-not-picking-up-my-context-root-with-tomcat-9-deployment/823/3 "2021-11-18T20:40:02Z")

</div>

Hi yes correct i am using this configuration not much here though…

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/jenkins/original/1X/ccc8caddd319043806926d8c832da5c9204958df.png)
