Search code examples
sonarqubesonar-runnersonarqube5.1

How to use sonarqube permission template regexp


I have the following sonar projet:

projectKey=com.domain.module.dev-tools.map-to-css-modules
projectName=com.domain.module.dev-tools.map-to-css-modules

I have created in sonarqube the following permissions template

name=dev-tools
description=
regexp=^com\.domain\.module\.dev-tools\.[A-z0-9-\.]+

I excpect this permissions template to be applied to any new project scanned that validate the regexp but I have to apply the permissions manually.

Does anybody know the correct synthax ?


Solution

  • It should work like that :

    name=dev-tools
    description=
    regexp=com\.domain\.module\.dev-tools\..+
    

    That's the way we're using it in Sonarqube 5.6.6 and it works fine.