push代码到git后如何同步到服务器
高洛峰
高洛峰 2017-04-25 09:04:18
0
4
722

push到git后还需要把git的文件上传到服务器才能在浏览器看效果,除了用scp手动上传有什么简便的办法?

高洛峰
高洛峰

拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...

reply all(4)
迷茫

Use Hook. After the git push is completed, the hook is executed and the code is cloned to the server. https://developer.github.com/webhooks/#events

仅有的幸福

Using Git to deploy a web site notes
Using Git to manage a web site

刘奇

I can understand your problem as a project (resource) deployment problem.

Static resources

If it’s just some pictures, HTML, js, CSS, etc., feel free to use Git Hook. Here is an introductory article.

Project backend

For example, if you write scripting languages ​​such as PHP, Node.js, Python or Ruby, and include database resources, and want to find a tool in addition to scp to upload source code to the server and deploy and run it, I recommend Capistrano. Here is a deployment article so you can get a feel for it. Now Capistrano has been released to the third edition, which is quite different from the second edition. Capistrano 2

phpcn_u1582

I usually make the upgrade package through git patch and put it on the update server, and then update it in the background

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template