Helm chart not parsed

Hi,

We would like SonarCloud to analyze both code and helm chart although despite many tries our helm chart is not detected.
From the root of the repo we have one folder for source code and one for helm chart which contain a template folder with atleast 1 deployment object.

Kubernetes language is activated (we also tried by expliciting sonar.kubernetes.activate)
We use BitbucketCloud and version 3.11.0.3922 of sonar-maven-plugin
We did add -Dsonar.maven.scanAll=true to mvn verify:
mvn verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.maven.scanAll=true -Dsonar.host.url=XXX -Dsonar.login=XXX -Dsonar.organization=XXX -Dsonar.qualitygate.wait=true

If during CI we list files before mvn verify we can see properly helm chart folder.

Logs:
[INFO] --- sonar:3.11.0.3922:sonar (default-cli) @ XXX-service ---
[INFO] 07:28:35.394 Java 21.0.2 Eclipse Adoptium (64-bit)
[INFO] 07:28:35.394 Linux 5.10.197-186.748.amzn2.x86_64 (amd64)
[INFO] 07:28:35.395 Bitbucket Cloud Pipelines detected, no host variable set. Defaulting to sonarcloud.io.
[INFO] 07:28:35.437 User cache: /root/.sonar/cache
[INFO] 07:28:36.831 Communicating with SonarCloud
[INFO] 07:28:36.848 Parameter sonar.maven.scanAll is enabled. The scanner will attempt to collect additional sources.

[INFO] 07:28:43.376 Preprocessing files...
[INFO] 07:28:43.701 2 languages detected in 114 preprocessed files
[INFO] 07:28:43.701 0 files ignored because of inclusion/exclusion patterns
[INFO] 07:28:43.702 0 files ignored because of scm ignore settings

2 languages detected being java and xml (pom.xml).

Any idea why our helm chart is not parsed?

Regards,

Simon

Hi Simon,

Welcome to the community!

Can you provide the text of your full analysis log, please?

 
Thx,
Ann

Hi Ann,

Please find attached full analysis log:
sonar-analysis-logs.txt (20.8 KB)

Regards,

Simon

Hi Simon,

What’s your Helm chart named, and where is it located?

As you stated originally, analysis should be picking up all files

Parameter sonar.maven.scanAll is enabled.

But it’s possible the file is still being overlooked.

 
Thx,
Ann

Hi Ann,

We run mvn verify from root of repository.
At root of repo we have a folder helm which contain:

ls helm/
Chart.yaml  templates  values-XXX.yaml  values.yaml

And in templates we have atleast 1 deployment object

Regards,

Simon

Hi Simon,

Thanks for that detail.

I’ve flagged this for the team that owns the scanner. I’m wondering if it’s a question of an extra directory at project root instead of individual files.

 
Thx,
Ann