0

I have a server where I have a bare repo with a node.js application. I pushed the code without the node_modules and installed them directly on the Server. Heres my problem: The changes (node_modules) on the server now need to be pushed to the repo in order to make the app work. The problem, however, ist that I don't have the private and public keys that I used on my laptop on the server.

The Files to run the server are in a directory called webbapp, which then includes a directory called website.git (see below), where the bare repo is located.

When I push from the work-tree into the repo it gives me this error message:

/opt/bitnami/apps/webapp/website.git$ git --work-tree=/opt/bitnami/apps/webapp/ push origin master
/usr/bin/ssh: /opt/bitnami/common/lib/libcrypto.so.1.0.0: no version information available (required by /usr/bin/ssh)
/usr/bin/ssh: /opt/bitnami/common/lib/libcrypto.so.1.0.0: no version information available (required by /usr/bin/ssh)
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I used this as a giude and got stuck after restarting the apache server.
Thanks for the help.

1 Answers1

0

How did you push them to the server? You must have used some kind of authentication unless you can download stuff from repo without auth.

If you do not have those keys, how about if you create a new keypair for the server and then feed it to github? A workaround would be to use your github login/password.

The next level down into the rabbit hole is taking a look at your .git/config. The lines you want to look into are

[remote "origin"]
        url = localgit:docker
        fetch = +refs/heads/*:refs/remotes/origin/*

Note they are specific to my setup. In fact, the above is using my local git server. The localgit is the ssh nickname/alias for the server; it is associated with the address, user, and in this case a ssh key. docker is the repo. Now, if I was using github, the url line might look like this

        url = https://github.com/raubvogel/some-repo.git

This one will require me to authenticate to upload something to github.

Hope the above might help you get started.

raubvogel
  • 46
  • 1