We have 5 people working on a project in our company. Everyone syncs their respective code to Gitlab. Every time we are copying and pasting the contents from local machine/Gitlab to production server to make our application work. We wish to sync Gitlab code to our cPanel server without installing Git on cPanel server.
Is this possible?
What we want is that as soon as we wish to sync our Gitlab code with cPanel server code, some script or some privilege should be given so that the updated Gitlab code updates the code on the cPanel server.
2
Answers
Git is automatically provided by the cPanel system to end users. They should already be able to use git.
You can do only two commands in cPanel such as
git pull
andgit push
Based on this documentation cPanel
Create the .cpanel.yml file with following code
Add the cPanel-managed repository as a remote.
Push changes to the cPanel-managed repository.