Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Next challenges

Recent achievements

  • Global
  • Personal


  • Give kudos
  • Received
  • Given


  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How to clone a bitbucket repo in pipeline

I have a script running in a pipeline in a repository A and when it finished it clones another bitbucket private repo B and commits to it. I have access to both repos.

git clone --depth 1

Now the git clone get a "Permission denied(public key)" error every time.

I guess I should add the SSH key of A to repo B. But I don't know how.

I tried with

1. Access key. Didn't work since it is a read-only permission.

2. Use key-gen. Didn't work since all my repos are on bitbucket cloud.

3. Use personal key. It's not recommended and the script used to be working.

4. Add user. I don't know what user should be added. Can I add bitbucket-pipeline as a user?

That's all I can think of.


1 answer

1 accepted

0 votes
Answer accepted

It's been solved. I added SSH keys to my profile.

Hi Hao? 

Would you please describe your solution in more details. As I am struggling with same issue. 

Kind Regards, 

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket Pipelines

What We Learned When We Researched Open Source Vulnerabilities in 7 Popular Coding Languages

...hey are a part of us, shaping how we interact with the world around us. The same holds true for programming languages when we think about how different kinds of vulnerabilities raise their heads in t...

1,237 views 0 3
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you