# Node-RED Project SSH authentication

**URL:** <https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905>\
**Category:** General\
**Created:** [12 February 2021 23:39 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905 "2021-02-12T23:39:08Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cjkeenan](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cjkeenan/32/38780_2.png) [@Cjkeenan](https://discourse.nodered.org/u/Cjkeenan)\
**Post date:** [12 February 2021 23:39 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/1 "2021-02-12T23:39:08Z")

</div>

So recently I have been getting emails from Github about them phasing out _Basic authentication using a password to Git_ in favor of SSH and token-based keys. This is where the problem is starting.

I was able to create a new remote from the _Hamburger Menu \> Projects \> Project Settings \> Settings \> Git Remotes \> add remote_, but was unsure exactly what format to URL should be, I assumed it was "ssh://git@github.com:User/RepoName.git".

Then I generated an SSH key from _Hamburger Menu \> Settings \> Git config \> SSH Keys \> add key_ which I proceeded to copy into my Github account under the SSH and GPG keys section of the settings. I tried with and without a passphrase.

When I try to select a remote under commit via _Project History \> Commit History \> Remote_ this dialog pops up with or without a passphrase provided when the SSH key was generated. When the passphrase was provided, entering it again did not work BTW.  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/1/a100bc08ee3b280645afc30b60d6193cb97b2403.png)

Any ideas about what I am doing wrong? Do the names for the SSH keys have to match between NR and Github?

Update: Same name did not change anything.

---

<div class="post-metadata">

**Author:** ![quentinP](https://avatars.discourse-cdn.com/v4/letter/q/ba9def/32.png) [@quentinP](https://discourse.nodered.org/u/quentinP)\
**Post date:** [12 February 2021 23:53 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/2 "2021-02-12T23:53:56Z")

</div>

My remote doesn't contain the ssh:// part, maybe try without? Did you copy the remote from your github repository?

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/c/5/c5cab705a8b8e958333429883f7a940bce6d143d.png)

---

<div class="post-metadata">

**Author:** ![Cjkeenan](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cjkeenan/32/38780_2.png) [@Cjkeenan](https://discourse.nodered.org/u/Cjkeenan)\
**Post date:** [12 February 2021 23:56 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/3 "2021-02-12T23:56:49Z")

</div>

> [@quentinP](#):
>
> My remote doesn't contain the ssh:// part, maybe try without? Did you copy the remote from your github repo?

I tried that as well, and then it gives this dialog, also yes I copied directly from my repo's page on Github  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/f/2/f26a3a84744bbfee1c5073619580ef1b6ee4c34e.png)

The reason I added the ssh:// was because of this:  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/c/c/cc5702880fb6f011ae90a0fe3f818d1849eabb65.png)  
I also tried removing the git@ part and it results in the same dialog, so I surmised that that is the default dialog when something with the URL goes wrong.

---

<div class="post-metadata">

**Author:** ![quentinP](https://avatars.discourse-cdn.com/v4/letter/q/ba9def/32.png) [@quentinP](https://discourse.nodered.org/u/quentinP)\
**Post date:** [13 February 2021 00:01 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/4 "2021-02-13T00:01:26Z")

</div>

I see, I don't have the ssh:// and it works fine. Do you use the exact same username and email for Node-RED and GitHub? (in settings \> git config)

---

<div class="post-metadata">

**Author:** ![Cjkeenan](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cjkeenan/32/38780_2.png) [@Cjkeenan](https://discourse.nodered.org/u/Cjkeenan)\
**Post date:** [13 February 2021 00:03 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/5 "2021-02-13T00:03:51Z")

</div>

Yeah it is the same including case sensitivity. If you have it working are the steps I listed correct or?

---

<div class="post-metadata">

**Author:** ![quentinP](https://avatars.discourse-cdn.com/v4/letter/q/ba9def/32.png) [@quentinP](https://discourse.nodered.org/u/quentinP)\
**Post date:** [13 February 2021 00:09 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/6 "2021-02-13T00:09:44Z")

</div>

As far as I can tell yes, although I create the ssh key before the remote and didn't use ssh://... If you are running this on windows it might be that you didn't configure Git correctly (username and email)? I'm not entirely sure tbh

---

<div class="post-metadata">

**Author:** ![Cjkeenan](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cjkeenan/32/38780_2.png) [@Cjkeenan](https://discourse.nodered.org/u/Cjkeenan)\
**Post date:** [13 February 2021 00:10 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/7 "2021-02-13T00:10:52Z")

</div>

> [@quentinP](#):
>
> If you are running this on windows it might be that you didn't configure Git correctly (username and email)?

RPi 3B setup and I checked the globals and they seem to be correct, but I thought the settings \> git config details override that anyway.

---

<div class="post-metadata">

**Author:** ![Cjkeenan](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cjkeenan/32/38780_2.png) [@Cjkeenan](https://discourse.nodered.org/u/Cjkeenan)\
**Post date:** [13 February 2021 00:33 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/8 "2021-02-13T00:33:01Z")

</div>

Update: I just added 2FA and then made an access token and am using HTTPS again now, but I still want to get this SSH authentication working.

BTW @quentinP did you initially clone using SSH or did you change an existing project to use SSH?

---

<div class="post-metadata">

**Author:** ![quentinP](https://avatars.discourse-cdn.com/v4/letter/q/ba9def/32.png) [@quentinP](https://discourse.nodered.org/u/quentinP)\
**Post date:** [15 February 2021 14:26 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/9 "2021-02-15T14:26:20Z")

</div>

So I remember also having problems with SSH. My solution was to basically upload my Node-RED files to GitHub manually and then clone the project through SHH. This seems to work best. I was having some issues with a project recently and basicically deleted it, then re-cloned it and it worked

---

<div class="post-metadata">

**Author:** ![Cjkeenan](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cjkeenan/32/38780_2.png) [@Cjkeenan](https://discourse.nodered.org/u/Cjkeenan)\
**Post date:** [15 February 2021 22:51 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/10 "2021-02-15T22:51:47Z")

</div>

Yeah I was wondering about that, I will give that a try when I reset my RPi installation as it has been giving me issues and report back. Either way though, I think it should be working as I did it and I think this is a bug that needs to be fixed.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [16 April 2021 22:52 UTC](https://discourse.nodered.org/t/node-red-project-ssh-authentication/40905/11 "2021-04-16T22:52:25Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
