On Thu, Oct 26, 2023 at 09:54:22AM +0700, Max Nikulin wrote: > On 26/10/2023 02:20, Martin wrote: > > On Wed, Oct 25, 2023 at 07:33:52PM +0700, Max Nikulin wrote: > > > should have something like > > > > > > table ip sharedconnection { > > > chain postrouting { > > > type nat hook postrouting priority srcnat; policy accept; > > > ip saddr 192.168.231.3/24 ip daddr != 192.168.231.3/24 masquerade > > > } > > > } > > "sharedconnection" is an arbitrary name. It should be chosen to not conflict > with other applications. Actually you have nat masquerading rules created by > docker for other interfaces. Read /usr/share/doc/nftables/README.Debian and > choose a convenient for you way to add rules. You may add the following > heading and may save rules to a file that may be read by either "nft -f > FILE.conf" or just executing it. > > #!/usr/sbin/nft -f > table inet sharedconnection {} > flush table inet sharedconnection > # table ip shared connection { ... } from above
I did create FILE.conf and after executing it I can connect to internet from my phone. THANK YOU! Now where do I put this FILE.conf? I would like for it to run everytime I turn on my computer. Is there some standard place for it - perhaps in /etc directory? Maybe i should create some script in /etc/init.d/ directory? Martin