youngmon/atlassian-qna huggingface dataset:
SSL Connection Timeout When Cloning Repo with Runner Autoscaler for Kubernetes in GKE
Asked by Hafeez Ghanchi:

We are utilizing the Runner Autoscaler for Kubernetes in GKE to execute our pipelines. However, we encounter an issue when the runners attempt to clone the repository:  
*`fatal: unable to access '`<https://bitbucket.org/xxx/xxx/>`': SSL connection timeout `*

When I access the DinD container running on the runner-xxx pod, I can connect to `bitbucket.org`. However, running `docker ps` reveals several containers active for pipelines.

![Screenshot from 2024-08-12 22-07-34.png](https://community.atlassian.com/t5/image/serverpage/image-id/341323i9C42A446270FF9D2/image-size/large?v=v2&px=999 "Screenshot from 2024-08-12 22-07-34.png")

Interestingly, when I enter one of these containers from within the DinD and try to access `bitbucket.org`, the connection fails, even though other public domains are accessible.  

![Screenshot from 2024-08-12 23-34-58.png](https://community.atlassian.com/t5/image/serverpage/image-id/341337iE816DCAAD46FCC71/image-size/large?v=v2&px=999 "Screenshot from 2024-08-12 23-34-58.png")  

Has anyone experienced similar issues or have suggestions on how to resolve the SSL connection timeout?


Answers:
author: Hafeez Ghanchi
body: After some serious sleuthing (and a few cups of coffee), I realized the culprit was the node's image type. As soon as I switched the cluster from a Container-Optimized OS image to an Ubuntu image, it was like magic---everything started working smoothly!


author: Syahrul
body: G'day, [@Hafeez Ghanchi](/t5/user/viewprofilepage/user-id/5564098)

Welcome to the community.

When you mean the runner failing to clone, does this happen during the build setup, or was it during your build steps?

Have you checked the runner logs to see if any specific error might've given you more insight? You can check our troubleshooting runner page below to locate your runner logs:

[Troubleshooting runners](https://confluence.atlassian.com/bbkb/troubleshooting-runners-1167819666.html)

Regards,  
Syahrul


Tags: autoscaler

bitbucket-cloud

cloud

gke

k8s

kubernetes

pipelines

pipes

runner
cant change email
Asked by Pavan Chintapalli:

I would like to change the email but its not allowing me to change it says email id is already associated with bitbucket. i tried to delete that but its dosent work for me. and itried to change with newly created mail id but it asks me to login. without creating how can i login into the newly created mail address.   

i want to change to the mail which is already associated. help me the proper procedure  

this will be highly appriciated in future


Answers:
author: Theodora Boudale
body: Hi Pavan and welcome to the community!

The email address you want to change to must not already be associated with an Atlassian account. If you try to delete the account, it will take up to 30 days for the account to be deleted, so you won't be able to make the change within these 30 days.

What you can do:

* Let's assume the email address of your account is **myemail1@example.com**   

* You want to change that to **myemail2@example.com** , but this is already in use by another Atlassian account  

* Instead of deleting the account with **myemail2@example.com** , change its email address to a different one, e.g. **myemail3@example.com**   

* Now, the email address **myemail2@example.com** is no longer in use. You can go back to the account with **myemail1@example.com** and change its email address to **myemail2@example.com**

The above applies to an unmanaged Atlassian accounts that give you the option to change the email in <https://id.atlassian.com/manage-profile/email>.

Please feel free to reach out if you have any questions.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
The bridge server used for analyzing JavaScript/TypeScript files is unresponsive.
Asked by Dhruvin Gabani:

image: node:lts # Choose an image matching your project needs

clone:  
depth: full # SonarCloud scanner needs the full history to assign issues properly

definitions:  
caches:  
sonar: \~/.sonar/cache # Caching SonarCloud artifacts will speed up your build  
services:  
docker:  
memory: 1024  
docker-with-large-memory:  
memory: 7168  
type: docker #For large file line code  
steps:  
- step:  
name: Install dependencies  
caches:  
- node  
script:  
- npm install  
- npm install -g increase-memory-limit  
- step: \&build-test-sonarcloud  
name: Build, test and analyze on SonarCloud  
caches:  
- node # See <https://confluence.atlassian.com/bitbucket/caching-dependencies-895552876.html>  
- sonar  
script: # Build your project and run  
- pipe: sonarsource/sonarcloud-scan:2.0.0  
variables:  
EXTRA_ARGS: "--exclude=src/@fuse/\* -X"  
- step: \&check-quality-gate-sonarcloud  
name: Check the Quality Gate on SonarCloud  
script:  
- pipe: sonarsource/sonarcloud-quality-gate:0.1.6  
variables:  
EXTRA_ARGS: "--exclude=src/@fuse/\*"

pipelines: # More info here: <https://confluence.atlassian.com/bitbucket/configure-bitbucket-pipelines-yml-792298910.html>  
default:  
- step: \*build-test-sonarcloud  
- step: \*check-quality-gate-sonarcloud  

above is code of my bitbucket-pipeline.yml file for my react.js project but i still faced below issue as show in image  

![Screenshot from 2024-08-12 19-24-51.png](https://community.atlassian.com/t5/image/serverpage/image-id/341268iC8B6AFF7588E5E38/image-size/large?v=v2&px=999 "Screenshot from 2024-08-12 19-24-51.png")


Answers:
author: Syahrul
body: G'day, [@Dhruvin Gabani](/t5/user/viewprofilepage/user-id/5566392)

Welcome to the community!

I can see that you are using a pipe. Can you enable the debug option in the pipe to generate a more verbose log?

```
DEBUG: "true"
```

Once done, please create a support ticket on our [Support portal](https://support.atlassian.com/contact/) with the pipeline build URL enabled by the verbose option.

Regards,  
Syahrul


Tags: bitbucket-cloud

cloud
This endpoint does not support token-based authentication | Update Build status for commit
Asked by Rahul:

Hello guys,

I'm trying to update the build status for commit using a service account username and app password which has repository:read scope

I was able to create build status for a commit using it, but getting 403 error when trying to update build status "This endpoint does not support token-based authentication"  
<https://developer.atlassian.com/cloud/bitbucket/rest/api-group-commit-statuses/#api-repositories-workspace-repo-slug-commit-commit-statuses-build-key-put>  
has only repository:read as permission required. What am I missing?


Answers:
author: Theodora Boudale
body: Hi Rahul, and welcome to the community!

I cannot reproduce the issue you are reporting. I can update a commit's build status using an app password with Repositories - Read permissions and a call like the following:

```
curl https://api.bitbucket.org/2.0/repositories/workspace-id/repo/commit/fbf0386/statuses/build/MY-BUILD -X PUT \
-u username:app_password \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
-d '{
"key": "MY-BUILD",
"state": "SUCCESSFUL",
"description": "42 tests passed",
"url": "https://www.example.org/my-build-result"
}'
```

Can you run such a call successfully? Are there differences between the call I shared and the call you are using?

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
Application Passwords randomly stop working
Asked by indextwo:

I've suffered with this problem for literal *years* and it's driving me bonkers.

Every so often - usually within 3-4 months, but sometimes within only a few weeks - my Application Password on my BitBucket account stops working.

I use the app password exclusively for SourceTree, and what happens is I open up the program, attempt to do a push, and it asks me for my login credentials (which are already saved). I re-enter them, and they fail. So, I have to go and create a new app password. It's the only solution that ever works (and I've learned this the long, hard way after spending *hours* trying to debug the issue previously). I enter my new app password, and it works again... for anywhere from a few weeks to a few months, then the cycle begins again.

I'm assuming this isn't *supposed* to happen - I never get any kind of warning, and as mentioned, the timing is completely random. I've had one app password that lasted for 6 months, and another that barely lasted 2 weeks.

Does anyone know why this is happening, or is it just *a thing*?


Answers:
author: Theodora Boudale
body: Hi,

App passwords do not expire unless they are manually revoked by a user or they are invalidated by our security team after a security incident (in this case affected users are notified and it's been a long time since we last did this). I believe this is more likely related to either SourceTree or the credential manager rather than the app password itself.

To confirm this, you can record somewhere the app password you generate. The next time this issue happens, open Git Bash or another terminal application on your computer (not from SourceTree), remove any saved credentials for bitbucket.org from your computer's credential manager, then try to clone a Bitbucket repo. You can also include the app password in the URL to test if it works:

```
git clone https://{bitbucket_username}:{app_password}@bitbucket.org/{workspace}/{repository}.git
```

Please keep in mind that this will save the app password in the repo's .git/config file, so make sure to remove it afterwards.

If this is SourceTree related, you can post in the SourceTree collection here:

* <https://community.atlassian.com/t5/Sourcetree/ct-p/sourcetree>

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
Is there an API endpoint to generate a repository's security access token?
Asked by Dean Christian Armada:

Hello,

I tried the python snippet below however, it returned **'This endpoint does not support token-based authentication'**.

```
import json

import requests




access_token = "sample_token"

workspace = "sample_workspace"

repo_name = "sample_repo"

url = f"https://api.bitbucket.org/internal/repositories/{workspace}/{repo_name}/access-tokens"

headers = { "Accept": "application/json", "Content-Type": "application/json", "Authorization": f"Bearer {access_token}" }

payload = json.dumps({ "name": "Test2", "scopes": ["webhook", "pipeline", "pipeline:write", "pipeline:variable", "runner:write"] })

response = requests.request( "POST", url, data=payload, headers=headers )
```

My general intention is for automation. I would like to avoid doing manual work for setting-up a bitbucket pipeline workflow where in the process it will trigger another pipeline on another repo from a particular bitbucket pipeline using \`pipe: atlassian/trigger-pipeline\` where the authorization that will be used is \`BITBUCKET_ACCESS_TOKEN\`.

Regards,


Answers:
author: Theodora Boudale
body: Hi and welcome to the community!

As Aron said, this is not possible at the moment. We have a feature request for the ability to manage access tokens via API:

* <https://jira.atlassian.com/browse/BCLOUD-23192>

You can add your vote (by selecting the **Vote for this issue** link) to express your interest and you can also add yourself as a watcher (by selecting the **Start watching this issue** link) if you'd like to be notified via email on updates.

Kind regards,  
Theodora

comments: author: Dean Christian Armada
body: Okay thanks!


author: Aron Gombas _Midori_
body: [@Dean Christian Armada](/t5/user/viewprofilepage/user-id/5566171) I think, similarly to the Atlassian API tokens, these cannot be created through the API, because that would reduce their level of security.


Tags: bitbucket-cloud

cloud
Create Workspace button is absent
Asked by TechSolutions_admin:

Under my login, I unable to create new workspace.

Please look into it.


Answers:
author: TechSolutions_admin
body: <https://bitbucket.org/workspace/create/> gives error message -   

Resource not found {#toc-hId--349761183}
----------------------------------------

Return to the previous page or go back to your [dashboard](https://bitbucket.org/).

comments: author: Saxea _Flowie_
body: The way you create workspaces has changed recently. Now you need to do it via [http://admin.atlassian.com/.](http://admin.atlassian.com/) The docs at have more details [https://support.atlassian.com/bitbucket-cloud/docs/create-your-workspace/](https://support.atlassian.com/bitbucket-cloud/docs/create-your-workspace/?)


Tags: bitbucket-cloud

cloud
localhost bind
Asked by Jason Kim:

Hi

I have a node.js code that runs in the bitbucket pipeline. I called curl <http://localhost:3000> but it didn't work. I found some links saying bitbucket pipeline doesn't allow to connection to localhost.  
Is there a way to find the IP address of where the server was binded to so I can connect to the server to run some tests

Thanks


Answers:
author: Theodora Boudale
body: Hi Jason and welcome to the community!

Have you started an application at localhost port 3000 or are you using a Docker [service](https://support.atlassian.com/bitbucket-cloud/docs/databases-and-service-containers/) container that listens on port 3000, on the same step where you do curl <http://localhost:3000>? There is no issue with using localhost as long as you have an application running on localhost on this port or a service container. For certain service containers you may need to use 127.0.0.1 instead of localhost. It is also not clear for which server you are looking the IP.

I suggest debugging this build locally with Docker as per the following guide:

* <https://confluence.atlassian.com/bbkb/troubleshoot-failed-bitbucket-pipelines-locally-with-docker-1318882094.html>

Then check if you get the same error or if the build succeeds. If the build succeeds when troubleshooting locally as per our guide, you can create a ticket with the support team and share (1) the output from your local troubleshooting and (2) the URL of the failed Pipelines build, for further investigation. You can create a ticket via <https://support.atlassian.com/contact/#/>, in "What can we help you with?" select "Technical issues and bugs" and then Bitbucket Cloud as product. When you are asked to provide the workspace URL, please make sure you enter the URL of the workspace that is on a paid billing plan to proceed with ticket creation.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
Bug Report: Comments are blank when file changes are reverted.
Asked by Alan Burns:

Severity: Minor

Existing comments are not visible in the "Files Changed" tab of the pull request if a previous changed file has all of its changed reverted / rolled back.

1. Create a pull request where multiple files are changed.

2. Add a comment on one of the files. Do not add a comment within the file.

3. Revert the changes to the file and push.

4. The comment will still be visible in the "overview" section of the PR.

5. The comment will still be counted in the "Comments" dropdown on the "Files Changed" tab of the pull request.

6. When you click on the specific comment in the "Comments" dropdown you will be given a blank screen with the words "Comments on other versions" at the top. From this screen you are unable to resolve the comment in question.


Answers:
author: Ben
body: Hi Alan,

Thank you for raising this to our attention. Just to clarify - when you say "revert the changes to the file" - do you mean via a git revert command?

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud
Issue with Autoscaled Runners on Kubernetes ? Online/Offline Status and Resource Cleanup
Asked by POLU ANIL KUMAR REDDY:

**Hi Team,**

We are currently running our runners on Kubernetes using the Autoscaler, with deployments under different names across separate clusters.

Although both runners consistently show as "Online," we've encountered an issue when triggering multiple pipelines with specific labels. In these instances, one runner remains online while the other switches to offline status.

Additionally, we've noticed that multiple jobs and pods are continuously running, but they are not being deleted automatically as expected. As a result, we are manually deleting these jobs and pods each time and reapplying the values.

Could you please assist us in resolving these issues?

Thank you for your support.

Best regards,  
Anil Reddy


Answers:
author: Theodora Boudale
body: Hi Anil,

I replied to the other post you created here:

* <https://community.atlassian.com/t5/Bitbucket-questions/Bitbucket-Kubernetes-runners/qaq-p/2780347>

Please check my reply to this other post and let me know if you have any questions.

Kind regards,  
Theodora


Tags: autoscaler

bitbucket-cloud

cloud

pipelines

pipes

runner
Non-existent next url of pagination (List variables for an environment)
Asked by Egor Pyshnov:

<https://developer.atlassian.com/cloud/bitbucket/rest/api-group-pipelines/#api-repositories-workspace-repo-slug-deployments-config-environments-environment-uuid-variables-get>

When calling this endpoint, I get next url like this : "[https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}/variables?page=2\&pagelen=10](https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}/variables?page=2&pagelen=10)" but this url doesn't exist and error 404 is returned and I don't see any mention of this endpoint in the doc either.

What could be the problem?

I thought the next url should be curl '<https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deployments_config/environments/{environment_uuid}/variables>'.


Answers:
author: Ben
body: Hi Egor,

I have been able to reproduce the issue - the next URL is indeed incorrect in the returned API results. Thank you for raising this to our attention.

I have raised a bug ticket accordingly - please **Watch** this for future updates and click **This Affects My Team**to improve its visibility with regard to gauging the number of affected customers:

* <https://jira.atlassian.com/browse/BCLOUD-23356>

Until this is fixed, I'd suggest increasing the pagelen parameter to it's maximum of 100 - this should display all of your variables on a single page:

```
https://api.bitbucket.org/2.0/repositories/{workspaceID}/{RepositorySlug}/deployments_config/environments/{EnvironmentUUID}/variables?pagelen=100
```

Cheers!

- Ben (Bitbucket Cloud Support)

comments: author: Egor Pyshnov
body: Thanks for the reply, I'll do as you said


Tags: bitbucket-api

bitbucket-cloud

cloud
Bitbucker Pipelines, Docker and Caching
Asked by LI:

Greetings, I'm having problems getting my pipelines to effectively make use of Docker layer caches in order to reduce build times.  

This is a snippet of the image build step in my pipeline definition:

```
image: atlassian/default-image:latest


pipelines:
  branches:
    test:
      - step:
          name: Build Image
          script:
            - IMAGE_NAME=${DOCKERHUB_USER}/${TAG}:TEST
            - docker build --secret id=REPO_USERNAME,env=REPO_USERNAME --secret id=REPO_PASSWORD,env=REPO_PASSWORD . --file Dockerfile --tag ${IMAGE_NAME}
            - docker save ${IMAGE_NAME} --output "docker-image.tar"
          services:
            - docker
          artifacts:
            - "docker-image.tar"
          caches:
            - docker

```

The idea is, when this step gets re-executed, to re-use docker layers that did not change, and only update those that did. Then get this updated image to become the new cache. Just like it would happen running locally on any machine.  

What is happening right now is no cache is being used. The \`docker build ...\` step constantly executes anew.


Answers:
author: Syahrul
body: G'day, [@LI](/t5/user/viewprofilepage/user-id/5565024)

Welcome to the community!

We'll need to observe your pipeline build to understand why it isn't using the cache. This issue often arises if the Docker cache is within the 1GB limit, preventing new cache entries from being created or if there's a problem with the cache itself. You can verify this by checking your build teardown.

If you wish to further investigate, please submit a support ticket through our [support portal](https://support.atlassian.com/contact/).

Regards,  
Syahrul


Tags: bitbucket-cloud

cloud
Is there any way to auto generate a Project with 2 Repositorys without needing to create one by one
Asked by hanthamike:

Is there any way to auto generate a Project with 2 Repositorys without needing to create one by one  
Example

Projekt: test.com  
Repository: test.com, test.com_nuxt  


Answers:
author: Saxea _Flowie_
body: Hi [@hanthamike](/t5/user/viewprofilepage/user-id/5564825) , you could try automating using the [Bitbucket Rest API](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-repositories/#api-repositories-workspace-repo-slug-post)s.


Tags: bitbucket-cloud

cloud
Move existing workspace to bitbucket under atlassian
Asked by Menouar Bendaoui:

Hi,

We would like to move our Bitbucket workspace (bitbucket.org/cl\*\*) under the umbrella of Atlassian, as it was initially created separately from our Atlassian account.

Currently, the workspace is just linked to Atlassian, but we would like to manage it fully through Atlassian, including using Atlassian's security and management features.

Could you please assist us with this integration?

Thank you.


Answers:
author: Ben
body: Hi Menouar,

The reason you can't manage your Bitbucket Cloud workspace in Atlassian Admin is that this is an older workspace that is not a part of the new [unified user management](https://bitbucket.org/blog/unified-user-management-is-generally-available-for-new-bitbucket-cloud-workspaces) experience that was released earlier this year:

* At this stage, only newly created workspaces are enabled with the unified user management experience - these workspaces are able to be managed in Atlassian Admin alongside your other Atlassian products - we have a roadmap entry to expand this out to all existing workspaces sometime in 2025:  
  [Bitbucket Cloud Roadmap](https://www.atlassian.com/wac/roadmap/cloud/Unified-user-management-for-existing-customers?selectedProduct=bitbucket&search=unified&p=38d41238-67)
* If you wish to manage your workspace in Atlassian Admin now, you will need to create a new Bitbucket Cloud workspace through the Atlassian Admin portal by adding Bitbucket Cloud as a product, and then transfer all repositories/data across to the new workspace:  
  [Create a workspace](https://support.atlassian.com/bitbucket-cloud/docs/create-your-workspace/)  
  [Transfer repositories](http://|https://support.atlassian.com/bitbucket-cloud/docs/transfer-repository-ownership/)
* **NOTE:** If you wish to use the same workspaceID for the new workspace, you will need to change the workspaceID for the old workspace first so that it is free for usage by the new workspace:  
  [Change a workspace ID](https://support.atlassian.com/bitbucket-cloud/docs/change-a-workspace-id/)

I hope this helps, if you need further assistance - please raise a support ticket using the Bitbucket URL you've mentioned in this community post, as discussing sensitive information is not appropriate for a public forum such as community. As you are a Premium customer and are therefore entitled to Premium support:

* <https://support.atlassian.com/contact/>

If you have issues raising a ticket, please let me know what time zone you are in so I can raise one on your behalf with the appropriate team located in your area.

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud