1

I have an iptables command I run on Ubuntu 22.04.3 that forwards 443 to 8443. However I have to keep running it every reboot.

sudo iptables -A PREROUTING -t nat -p tcp --dport 443 -j REDIRECT --to-ports 8443

Only thing I was able to find was adding it to /etc/network/interfaces from 7 years ago which obviously is a bit outdated. Not sure it would work the same way with a netplan yaml.

2
  • 1
    I installed iptables-persistent and it grabbed my rules and saved them on install.
    – Mike L.
    Commented Jan 27 at 15:26
  • Please move your solution from your comment into an answer
    – Daniel T
    Commented Jan 27 at 22:09

1 Answer 1

1

I installed iptables-persistent and it grabbed my rules and saved them on install.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .