To enable a "git push" over http, you have to enable WebDAV on the webserver. To do that for Apache Webserver, simply edit the configuration file:
vim /etc/httpd/conf/httpd.conf
Then search for the line starting with:
<Directory "/var/www/html">
Add the following line just after it:
Dav On
Make sure you have the following line also in httpd.conf uncommented:
LoadModule dav_fs_module modules/mod_dav_fs.so
After that you are ready. Restart Apache Webserver using:
service httpd restart
Also make sure to make all the git repository files on the server be writable by the pache:apache user and group using:
chown -R apache:apache /var/www/html/your_git_repository
Otherwise, failing to set correct permissions will result in "PUT error: curl result=22, HTTP code=403" when performing a "git push".
Now simply do a "git push" from your client machine and all should work.
1
Please, read this manual here and notice the point about
– hhh – 2012-06-12T03:00:38.523http.receivepack
.