question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Could not read username for enterprise github

See original GitHub issue

Hi team, Thank you for building this awesome library. I’m trying to use it for enterprise github by using the github api token in jenkins pipeline. I’ve set up the user name in package.json

"storybook-deployer": {
    "gitUsername": "testName",
    "gitEmail": "testEmail",
    "commitMessage": "Deploy Storybook [skip ci]"
  }

And I got error below

> storybook-to-ghpages "--ci" "--host-token-env-variable=****"

=> Getting the git remote URL
   executing: git config --get remote.origin.url
=> Building storybook
   executing: node ./node_modules/.bin/build-storybook -o out2263
   executing: git init
   executing: git config user.name "testName"
   executing: git config user.email "testEmail"
   executing: git config commit.gpgsign false
   executing: git add .
   executing: git commit -m "Deploy Storybook [skip ci]"
=> Deploying storybook
   executing: git push --force --quiet https://github.enterprisename.com/testName/XXX-repo master:gh-pages
exec: fatal: could not read Username for 'https://github.enterprisename.com': No such device or address

Is there a way I can fix it?

Thank you!

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
insidecommented, Mar 28, 2019

I noticed storybook-deployer doesn’t play well with github entreprise and tokens: https://github.com/storybooks/storybook-deployer/blob/fe6c77621ec0aa033de569e54bc10e9a6499d811/bin/storybook_to_ghpages#L63

It adds the token only if your origin’s host is github.com. As in your case it’s github.enterprisename.com, the token is ignored.

@hipstersmoothie would you be interested in a PR solving this github enterprise case?

(I’m on github enterprise too).

1reaction
wuweiweiwucommented, May 21, 2018

@daituzhang I think you need to set a valid gitUsername and gitEmail

Hope that helps!

Read more comments on GitHub >

github_iconTop Results From Across the Web

fatal: could not read Username for 'https://github.com': No such ...
This is an issue with your stored credentials in the system credential cache. You probably have the config variable 'credential.helper' set to ...
Read more >
Fatal: Could not read Username for "https://github.com", No ...
Hello! Today I was doing the setup of a git automation inside a Docker container using hub and I ran into something that...
Read more >
Fatal: could not read Username for 'https://XXXXXX': No such ...
I do have the needed access to drupal's project repo and I'm using the same credentials for this github actions. The github actions...
Read more >
Could not read username error. · Issue #279 · actions/checkout
My github action is giving me the error. name: CI on: push: branches: [ master ] pull_request: branches: [ master ] jobs: build:...
Read more >
Error: fatal: could not read Username for 'https://github.com ...
Hello, I'm attempting a rollback flow using actions/checkout@v2. The problem is that I need to use a PAT in order to rollback commits...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found