Before you read: I don't want to do malicious things, but setup a tool chain to overcome the flaws of go get
.
I want to have a setup that allows the following:
The git commands must be used as normal. Git configuration may be changed.
The idea is to have all development computers of a team configured this way, so that any external repository is in fact a clone on the proxy. That clone could be managed in a centralized way (special changes, merges will upstream etc.) without affecting the import paths.
How would I setup the DNS faking? How must the proxy be built in order to properly work with git?
Starting with git 1.8.5, you can setup directly in git global settings proxy for specific urls:
[http "http://github.com" ]
proxy = http://my.proxy:8080
[https "https://github.com" ]
proxy = http://my.proxy:8080
See "Only use a proxy for certain git urls/domains?"
That helps when you want to use a proxy only for certain urls.