Post date: Sep 17, 2016 5:40:46 AM
Running tomcat on 80 port is not easy as 8080 port (default). But why should we make tomcat running on 80 port? There are some scenarios where customers do not allow other than 80 port for http and 443 port https URLs of outside, so in these scenarios customer network can't access URLs which are running on other than 80 and 443 ports. Only root user has privileges to run any process on <= 1024 port. Starting Tomcat as root is generally a bad idea - security wise.
Here are the steps to follow to run the tomcat on 80 port by non-root user.
In server.xml, change port 8080 to 80 and 8443 to 442
Install the recommended (not required) authbind package, with a command like:
sudo apt-get install authbind
Enable authbind in the server.xml file (in either /etc/tomcat6 or /etc/tomcat7) by uncommenting and setting the line like:
AUTHBIND=yes
Start and Stop the tomcat with authbind command by changing the tomcat startup and shutdown scripts
Comment the last line exec "$PGDIR"/"$EXECUTABLE" start "$@" in startup.sh and add exec authbind --deep "$PGDIR"/"$EXECUTABLE" start "$@"
Comment the last line exec "$PGDIR"/"$EXECUTABLE" stop "$@" in shutdown.sh and add exec authbind --deep "$PGDIR"/"$EXECUTABLE" stop "$@"
Reference : http://unix.stackexchange.com/questions/129256/authbind-unable-to-authbind-with-tomcat-6-on-redhat-host
NOTE: Triniti Products URLs and Triniti Service URLs should not have port number in the URLs.
http://<domain>:80/tabimpl/logon.html - WRONG
http://<domain>/tabimpl/logon.html - CORRECT
http://<domain>:80/tabimpl/StateGpsServlet - WRONG
http://<domain>/tabimpl/StateGpsServlet - CORRECT
http://<domain>:80/etk/jsp/InstanceRunnerServlet - WRONG
http://<domain>/etk/jsp/InstanceRunnerServlet - CORRECT