There are few steps you need to follow when you are trying to run On-Premise Identity Server On Another Port rather than default port 8080. Firstly, you need to check whether ports are free to use by using specific commands. Secondly, you need to make changes in some files to run On-Premise Identity Server on another port.Finally, with the help of Firewall rule you will be allowing your port to accept packets.
These are the files names where you need to do changes:-
1. Change the "startup,shutdown port" located in (mo-idp-server/conf/server.xml file).
2. You also need to change the port in "application.properties" file located in (mo-idp-server/moas/WEB-INF/classes/ location).
Commands to check what ports are free to use:-
1. For Windows
2. For Linux
Commands to open a port on the server to access the IdP from outside
Add Firewall rule to allow the port to accept packets.
# firewall-cmd --zone=public --add-port=55555/tcp --permanent
# firewall-cmd --reload
# iptables-save | grep 55555
By performing the following steps you will be able to run On-Premise Identity Server On Another Port.