Our current setup is:
Client -> ALB -> Target Group -> auto-scaled instances
We have some urls that we would like to "hide" behind VPN access such as:
Client -> VPN -> ALB -> Target Group -> auto-scaled instances
For instances with static IP address it is possible to configure security group access to ports from the security group of the VPN instance. But our VPN is set to route only internal traffic and not internet traffic and so it does not route the necessary url.
URL would be for example: "https://www.something.com/admin"
One idea we have is to use custom port: "https://www.something:8099/admin", then in ALB security group configure that port to be accessible only from security group of the VPN instance. That still does not work though as VPN will not route internet traffic.
I have tried to change VPN (openVPN access server) configuration but with no success. Even when I configured the VPN to route all internet traffic, it still didn't work.
Every piece of material I found online about this topic suggests to alter VPN config to route domain to specific IP.
Is there any way of achieving this without having to hardcode IP addresses? Obviously I cannot hardcode the internal ALB IP as it is changing all the time, and I cannot hardcode the final instance traffic as it is auto-scaled and also changing all the time.