How to configure Jenkins to run on port 80

后端 未结 13 2130
走了就别回头了
走了就别回头了 2020-12-12 21:45

I\'m running Ubuntu 11.10 and have run sudo apt-get install jenkins to install Jenkins on this system.

I\'ve seen some tutorials on how to setup a rever

相关标签:
13条回答
  • 2020-12-12 22:48

    Run these lines of code individually:

    sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-ports 8080
    sudo iptables -t nat -I OUTPUT -p tcp -d 127.0.0.1 --dport 80 -j REDIRECT --to-ports 8080
    

    If your system is Debian-based, run:

    sudo sh -c "iptables-save > /etc/iptables.rules"
    

    If your system is RedHat-based:

    sudo iptables-save > /etc/sysconfig/iptables
    

    This process will change your default Jenkins port from 8080 to 80.

    0 讨论(0)
提交回复
热议问题