Mobile app version of vmapp.org
Login or Join
Tiffany637

: Deploy website with Git pull I have a website server with git to which I have ssh access. I can pull to any folder above the public_html but the provider does not want to host git repositories

@Tiffany637

Posted in: #Git #SharedHosting

I have a website server with git to which I have ssh access.
I can pull to any folder above the public_html but the provider does not want to host git repositories so I cannot push to it.

The question is: what is the most convenient way of deploying and managing a website with git in this situation?

I do not think that an init in public_html is a good idea?

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Tiffany637

1 Comments

Sorted by latest first Latest Oldest Best

 

@Angie530

You do this via git hooks. You can configure your git hosting service (bitbucket or github) to call a url everytime you do a git push. In essence you commit them push your changes to github/bitbucket and then those services do a request on a specific filename on your webserver.

In my scenario I have bitbucket always call www.mydomain.com/git-update.asp and then git-update.asp actually runs a cmd prompt and does a git pull.

If you are on linux based server its a little bit easier via php.
Check out this gist for more information: gist.github.com/oodavid/1809044
If you are on a windows IIS server let me know and I will see if its cool for us to share our git deployment for windows code publicly.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme