Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to use Git Push feature #12

Closed
SiliconAvatar opened this issue Mar 29, 2019 · 9 comments
Closed

Unable to use Git Push feature #12

SiliconAvatar opened this issue Mar 29, 2019 · 9 comments

Comments

@SiliconAvatar
Copy link

Problem/Motivation

I'm unsure if this is expected behaviour (and there's a configuration step I missed) or an issue with the addon.

When using git inside VSCode, I can commit changes using the GUI, but when I use the push command I get an error that I cannot find the askpass.sh file.

Expected behavior

It should ask for a username and password for the git repository.

Actual behavior

The command fails with an error message. (screenshot)
If I open the git log, this is the error I see:

> git push origin master
fatal: cannot run /home/travis/build/codercom/code-server/packages/server/build/extensions/git/dist/askpass.sh: No such file or directory
fatal: could not read Username for 'https://github.com': No such device or address

If I go directly to the terminal and type in the same command (git push origin master) it correctly asks for my authentication and the push succeeds.

@frenck
Copy link
Member

frenck commented Mar 29, 2019

This is an upstream coder/code-server#208

For a workaround in the comment of the upstream issue:

run git config --global credential.helper cache and manually do a git pull/clone/etc (from the CLI) where you'll have to enter your password. Once you do that, git operations in the GUI should work.

To be honest, please use a public/private key pair instead of username/passwords... 😉

@raulvasquez
Copy link

To be honest, please use a public/private key pair instead of username/passwords... 😉

I have hass.io installed on my ubuntu server with docker.

How do you get the keys to persist? They are removed when the container is restarted. I tried symlinking the hosts keys folder to my homeassistant config folder, but they didn't work. Appeared to be permission related.

@frenck
Copy link
Member

frenck commented Jun 18, 2019

@raulvasquez The .ssh folder (where your keys should go), persists across restarts.

@rogersmj
Copy link

The .ssh folder (where your keys should go), persists across restarts.

What .ssh folder are you referring to? I have the SSH add-on too, so I tried adding my key in my user's .ssh folder, but VScode showed no change. I know very little about docker.

I tried googling around for how to setup an SSH key between this add-on and GitHub, and I wind up at this thread :)

@sverleysen
Copy link

I also have this issue. I created a key in the .ssh folder, added the key into my github account. But how do I say to vscode to use this key instead of the username/password?

@sverleysen
Copy link

The .ssh folder (where your keys should go), persists across restarts.

What .ssh folder are you referring to? I have the SSH add-on too, so I tried adding my key in my user's .ssh folder, but VScode showed no change. I know very little about docker.

I tried googling around for how to setup an SSH key between this add-on and GitHub, and I wind up at this thread :)

I found my .ssh folder in the hassio root /addons/data/xxxx_vscode/.ssh

@rockinglama
Copy link

I also have this issue. I created a key in the .ssh folder, added the key into my github account. But how do I say to vscode to use this key instead of the username/password?

it should use the key by default but you have to accept the github hostkey
open a shell in your vscode container and do a ssh [email protected] and accept the host key fingerprint

@frenck
Copy link
Member

frenck commented Feb 16, 2020

I'm closing this issue.

While it is still present, there is nothing the add-on can do about it.
At this point, it is just cluttering up the overview of issues on the project.

I hope it will be resolved Upstream, however, it is recommended to use private/public keypairs.

@frenck frenck closed this as completed Feb 16, 2020
@addons-assistant
Copy link

This thread has been automatically locked because it has not had recent activity. Please open a new issue for related bugs and link to relevant comments in this thread.

@addons-assistant addons-assistant bot locked as resolved and limited conversation to collaborators Mar 17, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants