Ahsanul Hoque

Registered
Aug 1, 2018
1
0
1
Bangladesh
cPanel Access Level
Website Owner
Can any One Help me? How to Use CPanel Git Version Control? After Creating the New Repository, I can not connect the Remote Cpanel Repository from Git Bash. Some Fatal Error came with invalid Path
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,913
2,202
363
Hello @Ahsanul Hoque,

The following document is a good place to start when using Git on cPanel & WHM:

Guide to Git - cPanel Knowledge Base - cPanel Documentation

After Creating the New Repository, I can not connect the Remote Cpanel Repository from Git Bash. Some Fatal Error came with invalid Path
Can you let us know the specific steps (with commands) you are using when reproducing this issue? Also, can you verify if shell access is enabled for the cPanel account?

Thank you.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,913
2,202
363
I'm experiencing the same problem; I thought I was doing something wrong but all signs point to I can't push to the repository ?
Hello,

I've been unable to reproduce any issues with pushing changes via the "git push" command from a remote server to a Git repo hosted on a cPanel server. Can you let us know the full steps you are taking along with the specific error message you receive?

Thank you.
 

Mr_Roboto

Active Member
Feb 26, 2016
39
0
6
Toronto
cPanel Access Level
Website Owner
The file which I want to push is committed, then I'm using `git push <absolute URL to repository path>`
I get an error `fatal <absolute URL to repository path> not found` ?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,913
2,202
363
The file which I want to push is committed, then I'm using `git push <absolute URL to repository path>`
I get an error `fatal <absolute URL to repository path> not found` ?
Hello @Mr_Roboto,

I've been unable to reproduce any problems when testing a push from a remote server to a Git repo hosted on a cPanel server. Can you confirm that SSH access is enabled on the cPanel account? If so, are you using the SSH URL that's provided upon clicking on the Manage button for the repo within the Git Version Control interface? Here's an example of how to use the push command with that URL:

Code:
git push ssh://[email protected]/home/username/repositories/testing
Thank you.
 

Mr_Roboto

Active Member
Feb 26, 2016
39
0
6
Toronto
cPanel Access Level
Website Owner
From what I know SSH is not permitted; I can't use HTTP ? I will have to verify otherwise.
When running the command git push ssh, the password I use to login to cPanel is the same password I assumed require to connect with SSH to the repository, if that is the case, I'm getting the error; bad line length character Shel ?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,913
2,202
363
From what I know SSH is not permitted; I can't use HTTP ? I will have to verify otherwise.
Hello @Mr_Roboto,

Yes, SSH access is one of the requirements noted on the Host Git Repositories on a cPanel Account document:

To perform the steps in this tutorial, you must ensure that the following statements are true:
  • You must possess an active cPanel account with available disk space.
  • Your system administrator must enable the Shell Access setting for your cPanel account.
  • You must register your public key in cPanel's SSH Access interface (cPanel >> Home >> Security >> SSH Access) and authorize it for SSH access.
Thank you.