Must-share information
Versions in use
- SonarQube Server:
sonarqube:community
(latest Docker image) - Scanner: Not yet configured
- Authentication Plugin: GitHub OAuth (default plugin)
- Database: PostgreSQL 15 (
postgres:15
Docker image)
Deployment Method
- Deployed via: Docker (
docker run
commands) - Network: Custom Docker bridge network
alert_network
- Volumes: Persistent Docker volumes for both PostgreSQL and SonarQube data/logs/extensions
What I’m Trying to Achieve
I want to enable GitHub login for SonarQube and allow access for members of my GitHub organization nyltechnology
.
My GitHub username is AnserAliNYL
, and I am a confirmed member of that organization.
What I’ve Tried So Far
- Logged in with GitHub successfully (UI redirect works)
- Encountered this error upon redirect:
You're not authorized to access this page. Please contact the administrator.
Reason:
'AnserAliNYL' must be a member of at least one organization: 'nyltechnology'
- Confirmed that the GitHub organization
nyltechnology
exists: https://github.com/nyltechnology - Tried incognito/private browser sessions
- Reset volumes and restarted containers
Docker Commands Used
# Start PostgreSQL
docker run -d --name postgres-sonarqube --network alert_network -e POSTGRES_USER=sonar -e POSTGRES_PASSWORD=sonar -e POSTGRES_DB=sonarqube -v pg_data:/var/lib/postgresql/data postgres:15
# Start SonarQube
docker run -d --name sonarqube-custom --network alert_network -p 127.0.0.1:9000:9000 -e SONAR_WEB_CONTEXT=/sonarqube -e SONAR_JDBC_URL=jdbc:postgresql://postgres-sonarqube:5432/sonarqube -e SONAR_JDBC_USERNAME=sonar -e SONAR_JDBC_PASSWORD=sonar -v sonarqube_data:/opt/sonarqube/data -v sonarqube_extensions:/opt/sonarqube/extensions -v sonarqube_logs:/opt/sonarqube/logs sonarqube:community
Questions
- Why is SonarQube not recognizing my GitHub org membership?
- Should I use a GitHub OAuth App or GitHub App for more control(currently using GitHub APP)?
Thanks in advance for the help!