I have a https jenkins server running on https on port 1444. I set the iptable rules but it does not work as expected.
I set the following iptable rules:
- iptables -A INPUT -p tcp –dport 22 -m conntrack –ctstate NEW,ESTABLISHED -j ACCEPT # Since I want to allow ssh from anywhere into the host that hosts the jenkins server
- iptables -A INPUT -p tcp –dport 1444 -m conntrack –ctstate NEW,ESTABLISHED -j ACCEPT #Since the jenkins server runs on port 1444. Note: The server is https
- iptables -A INPUT -j DROP #I want all other traffic other than ssh and https to be dropped
Is there something wrong I am doing while setting the rules? Please help
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.×