How to clone a private Git repository without cPanel Terminal access?
Hi there! I have created a small-ish web application that I want to host on my website. I've already got a well-established website that is being hosted through GoDaddy, this application will just be for my company's internal use in a hidden-away directory.
Anyway, I want to be able to keep persistent changes between the web application's files on my website and the ones I am working on that I push to my GitHub repository. I have tried following the steps in Error: "/usr/local/cpanel/3rdparty/bin/git" reported error code "128" when it ended: fatal: could not read Username for 'https://github.com': No such device or address
I believe this is because my repository is private and not public. So I tried following the steps in to set up access to the private Git repository using an SSH key, but the tutorial requires access to cPanel's Terminal which I do not have access to on my website. I tried giving myself access to the Terminal using WHM (via some said [QUOTE] Now if what you require is the "Terminal" functionality (Attached screenshot) of WHM and you cannot find it, it is possible that your hosting provider has deactivated as indicated below. Server administrators can create the touch file / var / cpanel / disable_whm_terminal_ui to disable the terminal application for WHM users. This includes resellers with root access and the root user. The system does not create this file by default.
I think that this may be the case for me, because I do not know how to log into WHM and I see no way to do it from my GoDaddy dashboard. (I was not the one who originally purchased and set up the server, this was done by someone else.) So assuming that I am not able to turn on the Terminal for my cPanel account, how can I link a private Git repository? Thanks for any help!
I believe this is because my repository is private and not public. So I tried following the steps in to set up access to the private Git repository using an SSH key, but the tutorial requires access to cPanel's Terminal which I do not have access to on my website. I tried giving myself access to the Terminal using WHM (via some said [QUOTE] Now if what you require is the "Terminal" functionality (Attached screenshot) of WHM and you cannot find it, it is possible that your hosting provider has deactivated as indicated below. Server administrators can create the touch file / var / cpanel / disable_whm_terminal_ui to disable the terminal application for WHM users. This includes resellers with root access and the root user. The system does not create this file by default.
I think that this may be the case for me, because I do not know how to log into WHM and I see no way to do it from my GoDaddy dashboard. (I was not the one who originally purchased and set up the server, this was done by someone else.) So assuming that I am not able to turn on the Terminal for my cPanel account, how can I link a private Git repository? Thanks for any help!
-
Hello @2Flow2 Thank you for contacting cPanel! It is indeed necessary to have SSH access in order to access a Git private repository. The "disable_whm_terminal_ui" touch file you referenced is specifically for disabling the embedded terminal emulator inside the WHM or cPanel interfaces. However, even if this is disabled in the interface, it may be possible to login via another standalone SSH client, for example Terminal.app on Mac OS or Putty on Windows. With that said, hosting providers also have the option to disable SSH access altogether for cPanel users. I do not know exactly what policies Godaddy has for SSH access, and it's possible they vary depending upon the hosting package. I did find the following Godaddy documentation, though. This provides instructions for enabling SSH on a Godaddy hosting account: 0 -
Hello @2Flow2 Thank you for contacting cPanel! It is indeed necessary to have SSH access in order to access a Git private repository. The "disable_whm_terminal_ui" touch file you referenced is specifically for disabling the embedded terminal emulator inside the WHM or cPanel interfaces. However, even if this is disabled in the interface, it may be possible to login via another standalone SSH client, for example Terminal.app on Mac OS or Putty on Windows. With that said, hosting providers also have the option to disable SSH access altogether for cPanel users. I do not know exactly what policies Godaddy has for SSH access, and it's possible they vary depending upon the hosting package. I did find the following Godaddy documentation, though. This provides instructions for enabling SSH on a Godaddy hosting account:
0 -
If you are using the exact same username and password that were provided in your Godaddy account and you receive the "Access denied" error message, then you likely need to contact Godaddy to ask why you receive the error message. With root access, an administrator at Godaddy should be able to check the SSH access log. If you let them know the time you attempted to login, as well as the username you used and the IP address from which you are connecting, they should be able to easily identify the exact errors logged with these failed login attempts. You can find the IP address you are connecting from by visiting the following URL: 0 -
Alright, I contacted GoDaddy customer support and figured out that you have to use the cPanel username and password (seperate from the GoDaddy username and password) for the SSH to work correctly. After understanding that and successfully logging in, I was able to successfully clone my private repository into my web server using PuTTY! thanks for all your help @cPSamuel ! The one final thing I had a question about is that I noticed even though my site's directory contains a .git folder and can successfully clone from my private Git repository using SSH, the repository still does not show up in cPanel's "Git" Version Control" interface. How do I set it set it so that the cPanel system detects there is a repository in my files? (I want to be able to easily manage my repository/site linkage, like pushing and pulling, from any computer later without having to use an SSH client.) Is it possible to have my Git repository show up in this list, even though it is private? 0 -
Alright, I contacted GoDaddy customer support and figured out that you have to use the cPanel username and password (seperate from the GoDaddy username and password) for the SSH to work correctly. After understanding that and successfully logging in, I was able to successfully clone my private repository into my web server using PuTTY! thanks for all your help @cPSamuel ! The one final thing I had a question about is that I noticed even though my site's directory contains a .git folder and can successfully clone from my private Git repository using SSH, the repository still does not show up in cPanel's "Git" Version Control" interface. How do I set it set it so that the cPanel system detects there is a repository in my files? (I want to be able to easily manage my repository/site linkage, like pushing and pulling, from any computer later without having to use an SSH client.) Is it possible to have my Git repository show up in this list, even though it is private?
Any word on this, @cPSamuel ? :)0 -
The repository as far as I am aware should show up unless it is in one of the directories listed here: Guide to Git" - Host Git Repositories on a cPanel Account | cPanel & WHM Documentation If you use the command line to create the repository in one of these restricted paths the interface will not display the repository 0 -
The repository as far as I am aware should show up unless it is in one of the directories listed here: If you use the command line to create the repository in one of these restricted paths the interface will not display the repository
This is extremely odd. My path name does not seem to violate any of the stipulations laid out in that Documentation page. The full path to the.git/
folder is/home/myUsername/public_html/order
. I can navigate to it in the Terminal and successfully run all the git commands from there (pull, push, etc.) but it doesn't show up in the "Git" Version Control"? Any other ideas?0 -
That is odd and maybe it's best if one of our analysts can view the configuration to assist you with it. Can you please open a ticket using the link in my signature? Once open please reply with the Ticket ID here so that we can update this thread with the resolution once the ticket is resolved. Thanks! 0 -
That is odd and maybe it's best if one of our analysts can view the configuration to assist you with it. Can you please open a ticket using the link in my signature? Once open please reply with the Ticket ID here so that we can update this thread with the resolution once the ticket is resolved. Thanks!
Okay, will do! Thanks!0 -
That is odd and maybe it's best if one of our analysts can view the configuration to assist you with it. Can you please open a ticket using the link in my signature? Once open please reply with the Ticket ID here so that we can update this thread with the resolution once the ticket is resolved.
Hi @cPanelLauren ! Sorry about the late response, but I had some issues when trying to create a cPanel support ticket. On the first support ticket page it asks for my "Support Access ID." The two ways it gives to find the Support Access ID are to log in to WHM or to log in to your server from a shell. I tried logging into WHM for my server (by going to /usr/local/cpanel/cpanel -S
just resulted in the outputbash: /usr/local/cpanel/cpanel: No such file or directory
. Also,/usr/local/cpanel/cpanel -S
doesn't actually look like a valid command anyway? Is there a command named "cpanel" built-in? Should the hint mistakenly have said/usr/local/cpanel/etc
? Either way, it is not helping me find the Support Access ID that I need. What should I do to find my Support Access ID? Thanks!0 -
I apologize, I didn't realize you did not have root access to the server. In order to look further into this your hosting provider would need to assist you in this case. There may be some configuration that is present on the server preventing your ability to utilize git properly. 0 -
I apologize, I didn't realize you did not have root access to the server. In order to look further into this your hosting provider would need to assist you in this case. There may be some configuration that is present on the server preventing your ability to utilize git properly.
Oh, okay. So it may be some configuration by my hosting provider that is causing the cPanel interface to not recognize the git repository present? Because pushing/pulling is working correctly (when I do it manually from the shell), it just is not showing up in cPanel's "Git" Version Control" interface. Thank you!0 -
Hi, im new in this forum and im not able to create new topic, that's why im in here posting my question here. im facing difficulties in cloning private repo in cPanel. i've follow the instruction here Guide to Git" - How to Set Up Deployment | cPanel & WHM Documentation but its still failed. below are the steps that i've done, 1. generate SSH key in my local machine. (because cPanel's SSH key generator doesn't allow me to generate key without password) 2. login to my cPanel account & go to SSH Access and import my key into cPanel. 3. change the public key authorization into authorized. 4. deploy public key into my github repo. 5. go to Git" Version Control and insert the details require to clone my private repo. Clone URL: git@github.com/username/repo_name.git (im sure that my username & repo_name is correct) 6. click on the create button. outcome: Error:(XID 6xpzp3) "/usr/local/cpanel/3rdparty/bin/git" reported error code "128" when it ended: fatal: 'git@github.com/username/repo_name.git' does not appear to be a git repository fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. please help. 0 -
anybody home? 0 -
Hey there! I searched for other users with this error in our system and in all the ones I found this was related to an issue with the key setup. Can you double-check the key access between GitHub and your server? If that doesn't end up being the issue, troubleshooting Git over a forum can often be messy so this might be a good one to submit a support ticket to our team to have them take a look. 0
Please sign in to leave a comment.
Comments
15 comments