1
GC97
8y

My vServer setted Up recently is working.. nearly.. git isn't working.. cant Push to the server.. permission denied, Can not read.. Shit! Any suggestions?
I can login to my Server with my Public Key, but for some reason not with git. Maybe I will Dream from a Solution. Good night ;)

Comments
  • 0
    Does git use the right folder?
  • 1
    @stop Sorry, I've never set Up a Server before. Actually I'm logged in as root, its the Default. Tried to add User git, but with the User I cant to anything, No permission. Damn.
  • 3
    This is what I would do for a simple setup (I assume that git is installed on the server):
    1. Login as user git
    2. Create a folder with <PROJECTNAME>
    3. type: git --init
    4. logout
    5. Open a shell in your Project folder
    6. type: git remote add <PROJECTNAME> git@<SERVERURL>:<PROJECTNAME>/.git
    7. type: git pull
    8. type: git push

    <PROJECTNAME> is your Projectname and <SERVERURL> the url or IP-address.
    If there is a warning in step 7 follow the comands. All ither should work and if the folder exists from step 2, there should be nothing.
    I hope this helps you.
  • 0
    How are you connecting to the remote repo? Is it a private repo from a third party? (GitHub)

    If it's SSH you'll need to set up a new key pair so the user account on the server has access to the repo.
  • 0
    @stop yesterday I tried to do exactly this. But it didn't worked. Today I tried it again. It worked!! Wuhuu! I'm so happy. Even when I actually don't really know why its working now. It was the User. Now Set everything correctly. Thats cool!

    Thank you so much
  • 1
    Im glad it worked
Add Comment