skip to Main Content

I have Deployed Jenkins On a Server. The Server runs a CentOS Linux 8 as Operating system. I Wanted to access the Jenkins from another Device (laptop/PC) which is already in same network. but firewall restricts me in doing this. whenever i disable firewall I’m able to access the Jenkins but disabling firewall isn’t option for me what else can i do to resolve this problem.

2

Answers


  1. Well you need to open the ports used by Jenkins in the Centos Firewall. As I understand Jenkins uses ports 8080 and 8443 by default. See this guide on how to open and close ports in Centos 8

    Login or Signup to reply.
  2. You can open the ports used by Jenkins/Tomcat using this command:

    firewall-cmd --perm --add-port=your-port/your-protocol for example, to open port 8080 in tcp use this
    firewall-cmd --perm --add-port=8080/tcp
    

    After doing that, you have to reload the FirewallD tables using:

    firewall-cmd --reload
    

    The --perm option makes your rule permanent upon reboot.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search