user831413
user831413

Reputation: 141

Restrict Git Push/Pull

Is there any way to restrict git access from outside my office? For deployment on the server, I am using git cloud. I don't want to give code ( push/pull) access to deployment guy for their home.

Please let me know if there is any way we can restrict.

Upvotes: 1

Views: 1480

Answers (2)

whoosis
whoosis

Reputation: 454

May be you can get some help from here about this issue. thie main idea behind this is "Limit access to visitors who are logged in or allowed by IP addresses. Includes many options for handling blocked visitors".

Upvotes: 0

kgui
kgui

Reputation: 4165

I'm not sure you can restrict based on IP address but, you could implement hooks to restrict writing to a branch. More information here: How to write a git hook to restrict writing to branch?

If you're really interested in using this feature, you can switch to Bitbucket. More information is here: IP Whitelisting on Bitbucket

Upvotes: 1

Related Questions