'Cluster Domain and IP not reachable from ArgoCD pods, works in other pods

I am trying to setup ArgoCD on my laptop. It only connects with repo urls so I created a simple nodeport service "git-nginx", with nginx deployment that has a nodepath volume to the git repo on my host machine. This works great I can git clone http://localhost:nodeport on my host and git clone http://git-nginx in any pod in the cluster. In ArgoCD I can add http://git-nginx repo and it connects with it fine, however later when I try to "sync" it says that it cannot find such host, I also tried with the cluster ip and that times out. It seems to me that some of the ArgoCD's pods cannot access in-cluster networking. How can I make sure all ArgoCD pods can access in-cluster ips and dns?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source