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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,460,492
Community Members
 
Community Events
176
Community Groups

How does two-factor authentication affect authentication for scripts running in pipelines?

Edited

Hello, 

We have a question about how turning on two-factor authentication in Bitbucket accounts will affect our pipeline scripts. 

First, in the Build Setup section (which is BitBucket's code) there is a line that runs git clone with "https://x-token-auth:..." access. 

git clone --branch="master" --depth 50 https://x-token-auth:$REPOSITORY_OAUTH_ACCESS_TOKEN@bitbucket.org/$BITBUCKET_REPO_FULL_NAME.git $BUILD_DIR

In the documentation for turning on two-step verification (2FA), it says "Enabling two-step verification will disable all remote HTTPS actions for Git and the Bitbucket API. Any applications which use HTTPS to access Bitbucket will be impacted." 

I'm imagining that the above clone action will not be impacted, but want to be sure I understand why. 

And, I have the same question about scripts that we run in our pipelines. Do we have initiate an SSH session before running git clone in our scripts, or are we already running in SSH?

Thanks and Best Regards,
Josh

1 answer

1 accepted

2 votes
Answer accepted
Syahrul Atlassian Team Jan 16, 2022

Hey @BSYF 

G'DAy!

The pipeline build setup uses internal authentication and not your personal authentication, so any changes on your account will not affect the build setup.

As for your script, you don't need to initiate SSH sessions before running the git clone. Git clone will automatically look for what your git config is before cloning via HTTPS or SSH.

Please check our guide below on how to clone/push back to your repositories via HTTPS or SSH at:

I hope this helps, please let me know if you have any additional questions.

Cheers,
Syahrul

Thank you Syahrul, very helpful to know this. 

With Best Regards,
Josh

Like Syahrul likes this

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events