It is possible to enable temporary URL for tomcat enabled site.
If you want to enable tomcat for temporary/testing URL then refer below steps :
1) Login to the server as root
2) Open the server.xml file.
[ root@server~]# vi /usr/local/jakarata/tomcat/conf/server.xml
3) Add the following code to virtual host entry below the Alias tag.

<Host name=”test.com” appBase=”/usr/local/apache/htdocs”>
<Alias>www.test.com</Alias>
—->> Add the following code
<Listener className=”org.apache.catalina.startup.UserConfig”
directoryName=”public_html” homeBase=”/home”
userClass=”org.apache.catalina.startup.HomesUserDatabase”/>
—->>
docBase=”/usr/local/apache/htdocs” debug=”1″/>
<Context path=”/manager” debug=”0″ privileged=”true”
docBase=”/usr/local/jakarta/tomcat/server/webapps/manager”>
</Context>
</Host>
Save and quit.

4) Now open the apache configuration file and locate the entry for the respective domain name. Add the respective code depending on apache version to the file
[root@server~]# vi /etc/httpd/conf/httpd.conf
The configuration will be somewhat similar as follows:
<VirtualHost serversIP:80>
ServerName test.com
DocumentRoot /usr/local/apache/htdocs
ServerAdmin test@test.com
<IfModule mod_suphp.c>
suPHP_UserGroup nobody nobody
</IfModule >
——->> Considering apache version is 1 insert the following line.
Include “/usr/local/apache/conf/userdata/std/1/nobody/hostname/*.conf”
——–>>
</VirtualHost>
Similar code to be added for the https virtualhost entry.
<VirtualHost serversIP:443>
ServerName test.com
DocumentRoot /usr/local/apache/htdocs
ServerAdmin test@test.com
<IfModule mod_suphp.c>
suPHP_UserGroup nobody nobody
</IfModule >
Include “/usr/local/apache/conf/userdata/std/1/nobody/hostname/*.conf”
</VirtualHost>
save and quit.
5) Create the directory /usr/local/apache/conf/userdata/std/1/nobody/test.com/
[root@server~]# mkdir -p /usr/local/apache/conf/userdata/std/1/nobody/test.com/
6) Create a file cp_jkmount.conf in the above path and insert following code in it.
[root@server~]# vi /usr/local/apache/conf/userdata/std/1/nobody/test.com/cp_jkmount.conf
<IfModule mod_jk.c>
JkMount /*.jsp ajp13
JkMount /servlet/* ajp13
JkMount /servlets/* ajp13
JkMount /*.* ajp13
JkMount /* ajp13
JkMount /*.jspx ajp13
</IfModule>
Save and Quit.

7) Now restart the tomcat and apache service.
8 ) Now Try Accessing http://test.com/~username
***********************************************************
When you getting a default page of tomcat for any domain,please follow the below step
Our server has a /usr/local/jakarta/tomcat/conf/server.conf has set the chattr aui please remove that using chattr -aui server.xml
after that install servlet from whm for that domain
Main >> Account Functions >> Install Servlets
Select the domain name on which you want to nstall
[root@server~]# shutdown tomcat using
[root@server~]# ps aux | grep tomcat
kill all the processes
again [root@server~]#ps aux | grep tomcat
restart apache
check the bt accessing serverIP:8080