I am creating git repositories on my server. My requirement is that I have to create multiple git repositories on server and i have to secure them with username and password.
As there are multiple git repositories getting created i am putting .htpasswd and .htaceess in every git repository folders to secure them.
Below is the whole flow which i am doing.
a) Created the git repository with git -bare.
b) created the .htpasswd and .htaccess in that folder for authentication
c) I am now able to clone that repo any where with the username and password.
but when i try to push from the cloned repo it throwing me an error: error: Cannot access URL http://192.168.1.2/projects/gitcreation/gitrepos/6/project6/, return code 22 fatal: git-http-push failed
Any help will be highly appreciated.