We have a website that has all its PHP/HTML/JS/CSS/etc files stored in a Git repository.
We currently have 3 types of computers (or use cases) for the repository.
- Local developer: pull latest changes, make changes, commit to local repo, push to master server
- Master server: central repository, all changes get pushed to the master server
- Web server: changes are pulled down from the master server when deploying the website
So currently we:
local: git push origin master
local: password: ********
local: ssh admin@webserver.com
webserver: password: ********
webserver: cd ~/domain.com/
webserver: git pull origin master
So my question is: is there a way that from my local computer I can push straight to the web server?
ie.
local: git push origin master
local: password: ********
local: git push webserver master
local: password: ********
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…