youngmon/atlassian-qna huggingface dataset:
See all the repositories as an admin
Asked by Rodion Alukhanov:

I am a member of the ADMIN group. I can see all the projects in the workspace, but not the repositories as long I am not explicitly granted for.

Is it a way for the admin to see all the repositories?


Answers:
author: Patrik S
body: Hello [@Rodion Alukhanov](/t5/user/viewprofilepage/user-id/4511002) ,

This is probably because the Admin group you are part of was not granted permission to the repositories in question.

As a workspace admin, you can give the Administrator group access to any repository by going to **Workspace Settings** \> **User groups** \> Select the **Administrators** group \> on the top right corner select **Add Repository**. You will then see a list of repositories that you can select and give this group access to.

Additionally, by clicking on **Edit** on the **Administrators** group page, you can configure this group to be automatically assigned permissions for new repositories :

![Screenshot 2023-03-30 at 5.12.00 PM.png](https://community.atlassian.com/t5/image/serverpage/image-id/248891i76A71BE5C6709A51/image-dimensions/530x494?v=v2 "Screenshot 2023-03-30 at 5.12.00 PM.png")

This means that for any future repo that you or your team creates, that group will be automatically granted the level of permission you have selected in that setting.

Hope that helps! Let me know in case you have any questions.

Thank you, [@Rodion Alukhanov](/t5/user/viewprofilepage/user-id/4511002) !

Patrik S


Tags: administration

bitbucket-cloud

cloud

permission
How can I disable notifications for my Workspace?
Asked by Saar Avishai:

I'm aware of the ability to disable personal notifications from my Bitbucket personal settings, but was wondering if there's any way for me to be able to disable ALL notifications from the BitBucket Cloud global settings?


Answers:
author: Ben
body: Hey Saar,

There is no "global settings" as such for Bitbucket Cloud. You can however, disable notifications as you stated in Personal Settings - if you press the "Disable notifications" button you can prevent emails from any repository/PR/issue/snippet you are watching.

You can further prevent emails by unticking the following from this same screen:

* Someone mentioning me
* My access to a repository or a workspace changing
* Occasional updates from Bitbucket and Atlassian

By combining the above - I believe you can effectively prevent all notifications from Bitbucket Cloud.

Cheers!

- Ben (Bitbucket Cloud Support)

comments: author: Saar Avishai
body: Hey Ben, really appreciate the quick response and the informative answer.

I'd like to express that in my view, this could be problematic from an enterprise perspective; there could potentially be several notifications across the entire workspace sent for just a single PR comment made to a resource of which a large portion of the organization members are subscribed to by default.

I think it makes sense to add an enhancement to Bitbucket cloud to configure notifications from a Workspace (or other centralized) perspective.

Leaving this in hands of the individual users adds more noise to an already swamped dev team.

I'll be happy to provide further insights, if needed :)

Thanks and have a great rest of your day!


author: Ben
body: Hey Saar,

Thank you for your suggestion! We welcome and value feedback from our customers to improve our products.

I have raised a feature request on your behalf, feel free to "Watch" it to receive updates related to it and "Vote" on it to increase its visibility - you may also wish to comment on it to add further context:  
<https://jira.atlassian.com/browse/BCLOUD-22589>

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud
OIDC and boto3: InvalidIdentityToken
Asked by Georg Duemlein:

I have an OIDC provider configured in my AWS account.

It works nicely for the pipelines so far.

I am now trying to run a python boto3 script in the pipeline and I get this error:

```
botocore.errorfactory.InvalidIdentityTokenException: An error occurred (InvalidIdentityToken) when calling the AssumeRoleWithWebIdentity operation: No OpenIDConnect provider found in your account for
```

The IdentityProvider mentioned in the message exists.  
I even created a second one with trailing slashes - I read that might be the issue.

Are the any extra steps I need to take to have boto3 scripts run in the pipeline with OIDC?


Answers:
author: Georg Duemlein
body: Looks like the [documented](https://support.atlassian.com/bitbucket-cloud/docs/deploy-on-aws-using-bitbucket-pipelines-openid-connect/) snippet is not working for this use case.

Instead of this:  

```
- export AWS_ROLE_ARN=arn:aws:iam::<redacted>:role/<redacted>
- export AWS_WEB_IDENTITY_TOKEN_FILE=$(pwd)/web-identity-token
- echo $BITBUCKET_STEP_OIDC_TOKEN > $(pwd)/web-identity-token
```

I need to use something like this:  

```
- export AWS_ROLE_ARN=arn:aws:iam::<redacted>:role/<redacted>
- export AWS_WEB_IDENTITY_TOKEN_FILE=~/.aws/web-identity-token
- mkdir -p ~/.aws
- echo "${BITBUCKET_STEP_OIDC_TOKEN}" >> ${AWS_WEB_IDENTITY_TOKEN_FILE}
- chmod 400 ${AWS_WEB_IDENTITY_TOKEN_FILE}
```

I assume that boto3 is a bit more strict when it comes to finding the files - compared to terraform - which doesn't seem to have an issue with the documented bitbucket way.


Tags: bitbucket-cloud

cloud
How we back up zero downtime for repos in Windows OS.
Asked by Ruby:

Hi was trying to back up repos from Bitbucket cloud. To back it up, we need to install Bitbucket server? I couldn't find the installer for bitbucket server on Windows OS (<https://www.atlassian.com/software/bitbucket/download-archives>) .  

Community back up discussion was last 5 years ago (<https://community.atlassian.com/t5/Bitbucket-questions/Best-way-to-back-up-all-BitBucket-repositories/qaq-p/833630>). Couldn't find the latest discussion?  

Found bitbucket up from <https://gitprotect.io/> but it's a paid version. Can we backup the repos without using the third party app?


Answers:
author: Patrik S
body: Hello [@Ruby](/t5/user/viewprofilepage/user-id/2344989) ,

Thank you for reaching out to Atlassian Community!

You don't need to install Bitbucket Server in order to backup your repositories from Bitbucket Cloud. Actually, the Bitbucket Server and Cloud are two different products with regard to where they are hosted.

Bitbucket Server is a self-hosted version of bitbucket that is setup and operates in the user's company infrastructure/servers, while Bitbucket Cloud is a cloud-based product meaning that it is hosted and operated by Atlassian itself, so you don't have to worry about managing the infrastructure behind it.

As for doing a backup of your Bitbucket Cloud repositories, given the fact that git is a distributed version control system, this means that a clone of a repository can be considered as a backup of it. So in this case, I would suggest doing a mirror clone of the repositories you want a backup, using the following command :

```
git clone --mirror <repository URL>
```

You could build a script that gets the list of all repositories within a workspace from Bitbucket Cloud API (see [List repositories in a workspace](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-repositories/#api-repositories-workspace-get)), and then iterate over those repos executing a git mirror clone of each of them.

Hope that helps! Let me know in case you have any questions.

Thank you, [@Ruby](/t5/user/viewprofilepage/user-id/2344989) !

Patrik S

comments: author: Ruby
body: Thank you [@Patrik S](/t5/user/viewprofilepage/user-id/4603309) . It relieves me a lot instead of going to the wrong direction.


author: Ruby
body: Found "bitbucket backup client" to used but the marketplace at atlassian said it will no longer support in future. ([https://marketplace.atlassian.com/apps/1211500/bitbucket-server-backup-client?tab=overview\&hosting=server](https://marketplace.atlassian.com/apps/1211500/bitbucket-server-backup-client?tab=overview&hosting=server)) What should we use if so?


Tags: bitbucket-cloud

cloud
Unable to login Bitbucket - We couldn?t log you in EDITED
Asked by Ferenc Kovacs:

I'm getting this error after I log in on bitbucket.org, I think my issue is the same as this one:  
<https://community.atlassian.com/t5/Bitbucket-questions/Unable-to-login-Bitbucket-We-couldn-t-log-you-in-EDITED/qaq-p/2220801>  
as I also signed up a while ago (back in 2011) and was dormant for years.


Answers:
author: Ben
body: Hey Ferenc,

I've just re-activated your account for you - please let me know if you encounter any issues with logging in :)

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud
Rest API - Update a repository deploy key - return 403
Asked by vickos:

Hi,

I am trying to use rest-API to update repository access key.

When calling this <https://developer.atlassian.com/cloud/bitbucket/rest/api-group-deployments/#api-repositories-workspace-repo-slug-deploy-keys-key-id-put>

The response is:

Response: 403 Forbidden  
{"type": "error", "error": {"message": "This API is not accessible by this authentication mechanism"}}

Calling GET list deploy keys works fine

<https://developer.atlassian.com/cloud/bitbucket/rest/api-group-deployments/#api-repositories-workspace-repo-slug-deploy-keys-get>

for both calls I am using access token with all available permissions

Access token permissions:

**Scopes**

* `pipeline`
* `pipeline:variable`
* `pipeline:write`
* `pullrequest`
* `pullrequest:write`
* `repository`
* `repository:admin`
* `repository:delete`
* `repository:write`
* `runner`
* `runner:write`
* `webhook`


Answers:
author: Patrik S
body: Hello [@vickos](/t5/user/viewprofilepage/user-id/2634678) ,

Thank you for reaching out to Atlassian Community!

I'm afraid that currently Repository/project/workspace access tokens can't be used to authenticate API calls for POST/PUT/DELETE operation in the [deploy-keys endpoint](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-deployments/#api-repositories-workspace-repo-slug-deploy-keys-post). I went ahead and created a feature request to add the ability to use this authentication mechanism :

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

I would suggest you to add your vote there, since this helps both developers and product managers to understand the interest. Also, make sure you add yourself as a watcher in case you want to receive first-hand updates from that ticket. Please note that all features are implemented with [this policy](https://confluence.atlassian.com/support/implementation-of-new-features-policy-201294576.html) in mind.

While this feature is not implemented, the available authentication options for those endpoints are username and [app password](https://support.atlassian.com/bitbucket-cloud/docs/app-passwords/) or [OAuth access token.](https://support.atlassian.com/bitbucket-cloud/docs/use-oauth-on-bitbucket-cloud/#Access-tokens)

Thank you, [@vickos](/t5/user/viewprofilepage/user-id/2634678) !

Patrik S


author: vickos
body: Thanks for your reply.

I was able to use username and password to authenticate the API call, but I prefer not to use my own cerdinatial in the code.

How can I use [OAuth access token,](https://support.atlassian.com/bitbucket-cloud/docs/use-oauth-on-bitbucket-cloud/#Access-tokens) Do I need to use my username and password to create one or I can do it from the site? and how to limit the token's permissions?

What you think should be the best practice if I want automatically update access token after deploying my app to the server?

Tnx,

Vicko.


Tags: cloud

rest-api
Invoices
Asked by Johannes Aho:

Where can i find atlassian invoice/receipt i need for bookeeping? how come is it so fu. hard to find?


Answers:
author: Nic Brough -Adaptavist-
body: Welcome to the Atlassian Community!

Your licences, orders, invoices and so on can all be found at my.atlassian.com - for invoices, look under orders after you log in.

comments: author: Michael diLorenzo
body: Again, why is this so difficult? I am the Atlassian billing admin for our company. I can go to admin.atlassian, and I see BILLING. When I click BILLING, I do not see anything that has anything to do with BILLING.

When I go to my.atlassian and click ORDERS (not billing), I see nothing under invoices.

How can I find my invoices?


author: Nic Brough -Adaptavist-
body: If you see nothing under invoices, you are not currently one of the billing contacts. You will need to talk to the people responsible for paying the bills.

Are you logged in with the right account?


Tags: bitbucket-cloud

cloud
Can we trigger bit bucket pipeline using yml script which is present in another repo??
Asked by Srikanth Vemuluri:

Hello Team,  

We have a situation where we want to trigger the pipelines in bit bucket repo whenever there is a merge in the particular branch. By keeping the yml script in the master branch we can easily trigger the pipelines. But if we keep yml file in another repository will it be possible to execute this?? If so please let me know


Answers:
author: Ash Moosa
body: Hi Srikanth, we are working on building that functionality. Here is the roadmap item link - <https://www.atlassian.com/wac/roadmap/cloud/reusable-ci-workflows>


Tags: bitbucket-cloud

cloud
Bitbucket is not sending webhook event for pull request comment update
Asked by Meet Rathod:

Bitbucket is not sending webhook event for pull request comment update even when we are checking all boxes![Screenshot 2023-03-24 at 8.35.05 PM.png](https://community.atlassian.com/t5/image/serverpage/image-id/247609iE64BC216DECB9E31/image-size/large?v=v2&px=999 "Screenshot 2023-03-24 at 8.35.05 PM.png")


Answers:
author: Dave Parrish _Atlassian_
body: Hi [@Meet Rathod](/t5/user/viewprofilepage/user-id/5178893) ? Bitbucket PM here. Yup, this looks like a bug to me - I was able to duplicate the problem with the "Comment update" webhook trigger not firing. I'll pass this along to the appropriate team to investigate.

I've filed a bug in our public issue tracker, which we'll update when the bug gets fixed:  
<https://jira.atlassian.com/browse/BCLOUD-22558>

Thanks for reporting this!

comments: author: Dave Parrish _Atlassian_
body: This has now been fixed. Thanks again [@Meet Rathod](/t5/user/viewprofilepage/user-id/5178893) for reporting it.


author: SOUMYA AV
body: Hi [@Dave Parrish _Atlassian_](/t5/user/viewprofilepage/user-id/853503)

Please let me know in which version of bitbucket this issue is fixed.

Currently I am using Atlassian Bitbucket v7.21.18 and can still see this as a bug


Tags: bitbucket-cloud

cloud
Not receiving email to complete 2FA for BitBucket
Asked by Levi Liester:

Shamelessly copied from another post. I'm having what seems like a similar issue.

I'm trying to setup 2FA on my bitbucket account, however, I'm not receiving the confirmation email after scanning the QR code and successfully submitting the authentication code, please assist!

Looks similar to: <https://community.atlassian.com/t5/Bitbucket-questions/Not-receiving-email-to-complete-2FA-for-BitBucket/qaq-p/1763663>

I did try several auth apps and attempted to enable the service several times. I patiently gave it about 20 minutes for the email to show up. Now I'm here :)


Answers:
author: Andy Heinzer
body: Hi [@Levi Liester](/t5/user/viewprofilepage/user-id/5178844)

I found your email address was on a suppression list we maintain. I have removed this suppression. Please try again now. I expect that you should now be able to receive these notifications.

Cheers,

Andy


Tags: bitbucket-cloud

cloud
bitbucket pipeline IndexOutOfBounds Index: 0, Size: 0 error
Asked by Meagan:

In our pipeline we run our Java unit tests.

During some of the unit tests:

- we request something from the db or a third party and it fills the array.

- we know these requests are successful (the third party tool shows received and sent request, so I have confirmed its requesting the information and it's sent back).

But it seems like bitbucket tries to move on too quickly before the variable is actually set and it throws this error. But only sometimes. I re-run the pipeline and it's fine. But 1/5 times it fails with this error.

What are ways to fix this? Caching? Sleeps? Have it auto re-run once if it fails (I'd rather not since this seems like a hack)?


Answers:
author: Mark C
body: Hi [@Meagan Hiatt](/t5/user/viewprofilepage/user-id/4760434),

Thank you for reaching out to the community.

It seems to me that you'd need to put in some buffer time so that it will not move on too quickly.  
Have you tried putting some sleep command there?

Regards,  
Mark C


Tags: bitbucket-cloud

cloud
Webhook from AWS Codebuild to Bitbucket
Asked by Eunbi LEE:

As the title, I want to receive the results from AWS CodeBuild to Bitbucket Pipeline,

For example, I want to know some results of CodeBuild (success, failure) at Bitbucket

Is there a way to do that?


Answers:
author: Patrik S
body: Hello [@Eunbi LEE](/t5/user/viewprofilepage/user-id/5158450) ,

Thank you for reaching out to the Community!

My understanding is that you use AWSCodeBuild to build your code hosted in Bitbucket Cloud, and you would like the build status on AWS to be reported back into Bitbucket. If that is the case, AWS has the below article with steps on how to build that integration :

* <https://aws.amazon.com/pt/blogs/devops/aws-codepipeline-build-status-in-a-third-party-git-repository/>

This should allow you to have the AWS build status posted back to Bitbucket Cloud

Thank you, [@Eunbi LEE](/t5/user/viewprofilepage/user-id/5158450) !  
Patrik S

comments: author: Eunbi LEE
body: Thank you for answer,

And yes, I already read this article but furthermore, I want to send build status of AWS Codebuild not CodePipeline to Bitbucket,

Is there a way with REST API ?

Thank you [@Patrik S](/t5/user/viewprofilepage/user-id/4603309)

Eunbi LEE


author: Patrik S
body: Hello [@Eunbi LEE](/t5/user/viewprofilepage/user-id/5158450) ,

To create/update the build status for a commit, you can use the following Bitbucket API endpoints :

* [Create a build status for a commit](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-commit-statuses/#api-repositories-workspace-repo-slug-commit-commit-statuses-build-post)

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

The valid values for **state** are FAILED, SUCCESSFUL, INPROGRESS, STOPPED.

* [Update a build status for a commit](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-commit-statuses/#api-repositories-workspace-repo-slug-commit-commit-statuses-build-key-put)  

```
curl -X PUT -u username:app_password https://api.bitbucket.org/2.0/repositories/my-workspace/my-repo/commit/e10dae226959c2194f2b07b077c07762d93821cf/statuses/build/{key} -H 'Content-Type: application/json' -d '{"state": "FAILED", "description": "10 tests failed", "url": "https://www.example.org/my-build-result" }'
```

You can find more details about the build status endpoints in our API reference documentation :

* <https://developer.atlassian.com/cloud/bitbucket/rest/api-group-commit-statuses/#api-group-commit-statuses>

Thank you, [@Eunbi LEE](/t5/user/viewprofilepage/user-id/5158450) !

Patrik S


author: Eunbi LEE
body: It works :) Thank you so much ! [@Patrik S](/t5/user/viewprofilepage/user-id/4603309)


author: Patrik S
body: You're very welcome!

Feel free to reach out to Community again if you ever need help in the future :)


Tags: aws

api

bitbucket-cloud

cloud

webhook
Not receiving emails notifications for pr requests
Asked by Madhu sudhan:

Not receiving emails notifications for pr requests and any other commit updates made by our teammates, pls help in resolving this issues


Answers:
author: Ben
body: G'day Madhu!

We have checked our email logs and have found that we are successfully sending emails to your mail server however the following error was received from your mail server for your email address (and likely others belonging to your domain):

```
554 5.7.1 [internal] recipient address was suppressed due to customer policy

```

This error is encountered on your mail server when any of the following conditions are met:

* The address was invalid (address does not exist)
* The user clicked the list-unsubscribe header
* The user clicked one of your emails and flagged it as SPAM. This FBL (FeedBack Loop) event should add that email address to your Suppression List.

I would suggest reaching out to your email administrator to whitelist our email accounts as follows, then try to trigger a notification:

```
noreply@am.atlassian.com
no-reply@atlassian.com
noreply@mailer.atlassian.com
notifications-noreply@bitbucket.org

```

If this still does not work, please follow this article below that I have recently authored and let me know if you have any further issues:  
<https://confluence.atlassian.com/bbkb/email-notifications-not-working-1224343600.html>

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud
issue with aws-eks-kubectl-run:2.2.0
Asked by Emmanuel Cohen-Laroque:

When deploying on EKS, I get the following error (see bold line below)  

Here is the related pipeline script  

script:  
- pipe: atlassian/aws-eks-kubectl-run:2.2.0  
variables:  
AWS_ACCESS_KEY_ID: ${REHEARSAL_AWS_KEY}  
AWS_SECRET_ACCESS_KEY: ${REHEARSAL_AWS_SECRET}  
AWS_DEFAULT_REGION: "eu-west-3"  
CLUSTER_NAME: "XXXXXXXXXXX"  
KUBECTL_COMMAND: "apply --force=true -f"  
RESOURCE_PATH: "k8s/${BITBUCKET_REPO_SLUG}-staging.yaml"  
DEBUG: "true"

Status: Downloaded newer image for bitbucketpipelines/aws-eks-kubectl-run:2.2.0  
DEBUG: Starting new HTTPS connection (1): [bitbucket.org:443](http://bitbucket.org:443/)  
DEBUG: [https://bitbucket.org:443](https://bitbucket.org/) "GET /bitbucketpipelines/official-pipes/raw/master/pipes.prod.json HTTP/1.1" 200 None  
INFO: Configuring kubeconfig...  
Added new context arn:aws:eks:eu-west-3:xxxxxxxxxxxx to /root/.kube/config  
Entries:  
context:  
cluster: arn:aws:eks:eu-west-3:xxxxxxxxxxxxxx  
user: arn:aws:eks:eu-west-3:xxxxxxxxxxxxxxx  
name: arn:aws:eks:eu-west-3:xxxxxxxxxxxxxx  
name: arn:aws:eks:eu-west-3:xxxxxxxxxxxxxxx  
user:  
exec:  
apiVersion: [client.authentication.k8s.io/v1alpha1](http://client.authentication.k8s.io/v1alpha1)  
args:  
- --region  
- eu-west-3  
- eks  
- get-token  
- --cluster-name  
- xxxxxxxxxxxxxx  
command: aws  
cluster:  
certificate-authority-data: xxxxxxxxxxxxxxx==  
server: [https://xxxxxxxxxxxxxxxxxxx.eu-west-3.eks.amazonaws.com](https://66ecfcbf3c95c505ca7123c87ab480df.gr7.eu-west-3.eks.amazonaws.com/)  
name: arn:aws:eks:eu-west-3:xxxxxxxxxxxxxxxxx  
INFO: Successfully updated the kube config.  
**`error: the path "--v=2" does not exist`**  
? kubectl apply --force=true -f failed.


Answers:
author: Igor Stoyanov
body: [@Emmanuel Cohen-Laroque](/t5/user/viewprofilepage/user-id/5178604) hi. Your pipe command was not resolved correctly.  
Please, take a look at the pipe README, you should provide *apply* related arguments under \`KUBECTL_APPLY_ARGS\`, but since \`-f\` is used by default, you could omit it. And \`--force=true\` argument should be passed to \`KUBECTL_ARGS\`.

So your script should be like this:

```
script:  - pipe: atlassian/aws-eks-kubectl-run:2.2.0    variables:      AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID      AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY      AWS_DEFAULT_REGION: $AWS_DEFAULT_REGION      CLUSTER_NAME: 'my-kube-cluster'      KUBECTL_COMMAND: 'apply'      RESOURCE_PATH: 'k8s/${BITBUCKET_REPO_SLUG}-staging.yaml'      KUBECTL_ARGS:        - "--force"
```

Regards, Igor.


Tags: aws

bitbucket-cloud

cloud

kubernetes