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

Bamboo specs getting 401 on webhook

Sander Cornelissen May 8, 2018

I'm trying to get Gitlab working with Bamboo Specs on Bamboo 6.5. I have created a linked repository with Bamboo specs enabled. From Bamboo I received a 'scan' URL, which I inserted in Gitlab Intergrations.

Whenever the hook is hit, I get te following response:

{"message":"You do not have sufficient read permissions","status-code":401}

The push from Gitlab has no credentials, only the URL in format:

https://<bamboo server>/rest/api/latest/repository/scan?repositoryId=<id>

3 answers

0 votes
Gabriel Ribeiro
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 9, 2018

Hi @Sander Cornelissen,

I tested the solution proposed by @Siddhant Gogri and it true, if you're not allowing anonymous users to access Bamboo, the RSS will not be triggered.

As I'm pretty sure this is not the expected behavior, I've raised a bug report:

Please be sure to watch it, so that you are notified when this is fixed in a future release.

Thank you guys for reporting this.

0 votes
Siddhant Gogri May 9, 2018

Even I faced the same issue with Bamboo 6.5 and Github.

Since my dev bamboo is internally hosted, I enabled anonymous access and I could go pass that error.

0 votes
Gabriel Ribeiro
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 8, 2018

Hi Sander,

Could you please double check if the repository has access to the project you're trying to edit? You can check this in the repository configuration>Bamboo specs tab.

If you want to grant access to a build project, please follow the steps below:

 

To add a Build project:
  1. From the Bamboo header, click Projects.
  2. Click your project.
  3. In the top-right corner, click Project settings.
  4. In the sidebar, click Bamboo Specs repositories.
  5. Select your repository and click Add

More details can be found at the Enabling repository-stored Bamboo Specs page

Thanks.

Sander Cornelissen May 8, 2018

Hi,

I have checked the steps you described; the repository is for the project an allowed Bamboo Specs repository. The repository is listed in the Bamboo Specs repositories under the project I had written the Bamboo YAML spec for.

But should it work only with that URL? For example, doing a curl -XPOST with that URL  from Bamboo should normally work? When I do that with curl I received the same error.

The project I have described in Bamboo spacs exist, but the plan does not exist, is that correct?

Gabriel Ribeiro
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
May 9, 2018

Hi Sander,

Yes, running curl -x  https://<bamboo server>/rest/api/latest/repository/scan?repositoryId=<id> should trigger the change detection in Bamboo.

Did you check if bamboo is throwing any error in the logs?

Yes, the project doesn't need to exist in Bamboo, only the project.

thanks

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events