Cannot Track public websites. Matomo Behind VPN

Hi.
I deployed Matomo in EKS and the server console is accessible through VPN.I configured a website deployed in Amplify to be tracked in Matomo.When VPN is connected everything works fine,but when VPN is off Website in Amplify cannot reach Matomo server. How can i track web sites if public websites don’t have access to Matomo because it is behind the VPN. Is there any solution?

Hi @Turgut
Matomo must be accessible from users who visit the website you want to have analytics.
Or else track thanks to server logs analytics: