Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove jdbc config and add sonar credentials to config example #32

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ulfbiallas
Copy link

From my experience the jdbc section in the config is not necessary. Instead we should document how to provide the credentials for SonarQube which are needed as soon as you activate the user authentication in SonarQube.

How I came to this conclusion:
I setup SonarQube (user authentication deactivated) with a MySQL database. Then I scanned my project with the gulp-sonar task using the config from the example but without the jdbc section and it was working totally fine for me.

Later I activated the user authentication in SonarQube and run the gulp task again and (as expected) it failed:

Caused by: Not authorized. Analyzing this project requires to be authenticated. Please provide the values of the properties sonar.login and sonar.password.

I added the properties login and password to the config object (like described in my PR) and then it was working.

@john-shaskin
Copy link

It might also be worth noting that you can substitute a generated login token as the 'login' property, and leave 'password' blank.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants