Delete a project from SonarQube
Does anyone know how to delete a project from a SonarQube server?
Th开发者_如何学运维anks, Ronen.
You have 2 ways to delete a project:
If you are an admin of the project, you can delete it from its configuration actions
=> See "Deleting a project" in the "Project Administration" documentation page
If you are a SonarQube administrator, then you can also delete a project from the "Project Management" page
=> See "Project Management/Project Existence" documentation page
Updated for Sonar 2.11:
- Select the project (from the home page)
- Then click on the Project Deletion link on the bottom of the left panel
- Finally, confirm using the Delete Project button
In Sonar 3.6, the deletion button is in the project page, under the search input, inside the menu Configuration (you must be logged as administrator):
Login with administrator account. Select the project name. There you can see "project deletion" under configuration menu.
Login with an administrator account, then browse to the settings page of your project to get the button "delete project".
In some situations that you want to make it programatically you can use the SonarQube's Rest Web API to do so. According to SonarQube documentation:
POST api/projects/bulk_delete
Which can be used by passing the project's ID in the "keys" parameter. I'm no pro in Curl but it should be something like this (code generated in the Postman client) for project with key "daBestProjectKey":
curl -X POST -H "Authorization: Basic YWRtaW46YWRtaW4=" -H "Cache-Control: no-cache" -H "Postman-Token: 10a0e9a1-8dae-a9d1-45f2-0d8e56de999d" -H "Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW" -F "keys=daBestProjectKey" "http://localhost:9000/api/projects/bulk_delete"
[Home] button in top left corner >> [Projects] tab in top left corner >> (under name, click on the name of your project) >> [Project Deletion] (on the left panel/dashboard at the bottom) >> [Delete project] (in the center of the page, kind of).
SonarQube 5.1
(released on April 23, 2015) Consider that you need to have administrative permissions. You can perform as described in the documentation:
For SonarQube 5.1, following are the two options that can be followed:
Here is SonarQube version 4.4,
Seems each version the GUI is changed....
Here is the steps I use to DELETE any project from My SonarQube.
- Login as administrator
- Go to Administration -> Projects -> Projects Management
- Select the Project(s) you want to DELETE
- Click on Delete button at top right corner.
This information is for SonarQube version 5.0 which is latest for now - Released on 17th January 2015
You can delete the project from Project Configuration which is present on right hand side of Project Dashboard.The same screenshot is attached below.
if you are an Administrator of SonarQube, the you have the authority to delete multiple projects.
Just go to settings and you see a tab on your left as "bulk deletion". Please find the attached screenshot for the same.
Sonar Admin login with uwr: admin and pwd: admin (default one) --> Setting -->Bulk Deletion -->select projects you want to delete and delete.
Login with an administrator account, then browse to the settings page of your project to get the button "delete project".
Here is the steps I use to DELETE any project from My SonarQube.
Login as administrator. Go to Administration -> Projects -> Projects Management. Select the Project(s) you want to DELETE. Click on Delete button at top right corner.
or with the command line: POST api/projects/bulk_delete.
精彩评论