On Linux you can do this with full control via network namespaces. I use vopono to automate it - https://github.com/jamesmcm/vopono
But if you can afford it I’d recommend paying for Proton’s services as they offer a lot together, or a low-end VPS (where you could do it yourself, although be careful to find ones that don’t ban hosting Wireguard, etc. for example). Both are really useful if you want to test making something local available on the Internet e.g. ports for multiplayer games or a webserver prototype.
American culture warriors have decided that their ideology is more important - you see this a lot where their ideology’s goal becomes the “greater cause” worth sacrificing the mission: e.g. in journalism.