Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

fail to import github repository into hosted bitbucket server

lin yuan
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 31, 2019

I am trying to import one of my github repository into my hosted bitbucket server with github "Personal access token". But after I input my username/token, and click "Connect", the UI show "Unable to reach server". And the log shows

 

2019-05-31 07:03:56,401 WARN [http-nio-7990-exec-8] linyuan @42BM1Sx423x152x0 1pevt1n 192.168.255.248,192.168.11.13 "POST /rest/importer/latest/external-source/missing-oauth-scopes HTTP/1.1" c.a.b.i.i.r.ExternalRepositoryResource Error making external request: Request to the external repository source failed. Response status was 404, message 'Not Found'

 

I found this link https://confluence.atlassian.com/bitbucketserverkb/importing-a-repository-from-an-external-source-fails-due-to-java-net-connectexception-848962786.html seems related. However, I am not using outbound proxy for the bitbucket server. And the bitbucket server is behind a reverse proxy.

 

Please help me with this issue. Thanks!

 

 

 

 

1 answer

0 votes
Stephen Sifers
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 3, 2019

Hello Lin,

Thank you for sending over your log with errors you’re running into when attempting to migrate a GitHub repo into Bitbucket. The error is pointing to a URL not being present, which is causing your import to fail. I would be interested to know what steps you’re taking to clone your GitHub repo into Bitbucket?

You should be able to follow this guide in order to import content from GitHub into Bitbucket; Importing code from an existing project. If you’re using Bitbucket cloud you can use the following; Import a repository from GitHub or GitLab.

Once you’ve attempted a clone of your GitHub repo and you’re still running into issues, please let us know.

Regards,
Stephen Sifers

Christopher Bayliss
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 30, 2019

Hi,

I'm having what appears to be the same problem. From the project page:

  1. Select "Import Repository"
  2. Select "GitHub"
  3. Leave on "GitHub (github.com)"
  4. Enter my username
  5. Enter a personal access token with all repo permissions and read:org
  6. Select "Import"
  7. <Nothing Happens>
  8. Receive "The server didn't respond. You may retry your request when the server comes back up."

 

I'm seeing a POST to ${BITBUCKET_URL}/rest/importer/latest/external-source/missing-oauth-scopes that never returns.

If I use the generic git HTTPS import with the same credentials it works fine.

Stephen Sifers
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 5, 2019

Hello Christopher,

To understand a bit more about the issue you’re facing, while similar, we need to see what could be causing this issue. With this said, the best place to find the cause of the issue would be your Bitbucket server logs. Could you please re-attempt an import and then review your logs and report back any “warnings”, “errors” or “caused by” within your logs?

Additionally, could you also let us know which version of Bitbucket server you’re currently using?

We look forward to hearing back to help find the cause of your import issues.

Regards,
Stephen Sifers

Like Dave Liao likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events