How to realize the automatic clone to the online server when git push goes to the warehouse at the same time?

I recently built a GitLab repository with my own server
. Every time I write it locally by clone, then push it to this warehouse, and then clone the contents of this warehouse on the online server (the same server), but I think it"s very cumbersome.
but I figure out how to implement
I write locally, push to the repository, and at the same time, automatically clone to the online server

Mar.09,2021

GitLab's Webhook: https://www.jianshu.com/p/00b.


2 ideas: let the online server access the warehouse path directly, or submit it directly to the server.


webhooker


git hook

Menu