Several Environment variables are not working with Docker image

This create complex situation to investigate, like when it breaks your sonarqube context and page is indefinitely loading, or when it breaks your ldap integration…

  • versions used (SonarQube, Scanner, Plugin, and any relevant extension)
    Latest Docker Sonarqube 8.2-community (e7cc715e8756)

  • error observed (wrap logs/code around triple quote ``` for proper formatting)
    Several environment variables are not taken into account, although those are documented into Environment Variables | SonarQube Docs
    So far, following environment variables are not working:

    • SONAR_LOG_*
    • LDAP_*
    • SONAR_WEB_CONTEXT
    • probably others
  • potential workaround
    Hopefully, old naming convention from sonar.properties file is still working (sonar.web.context for example)

Hi,
Thanks for reporting. I confirm that the mechanism doesn’t work for some properties on the list. Here is the ticket to track it: https://jira.sonarsource.com/browse/SONAR-13272

The workaround is to configure these properties through sonar.properties or in case of docker you can also pass these properties to the entrypoint, like this:

docker run -p 9000:9000 sonarqube:8.2-community -Dsonar.web.context=/my-context
2 Likes