靜態源碼分析軟體 SonarQube
安裝
- docker run -d –name sonarqube -p 9000:9000 -p 9092:9092 sonarqube
- docker start sonarqube
- 打開瀏覽器連到localhost:9000
- 帳密都是admin
建立測試專案
- 建立測試專案
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
- 輸入字串產生token
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
- 連到 https://docs.sonarqube.org/latest/analysis/scan/sonarscanner/ 下載 sonar-scanner-cli-4.0.0.1744-linux.zip
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
4. 解壓縮到~/opt資料夾
5. 編輯nano ~/.bashrc
-
source ~/.bashrc
-
進入專案程式碼資料夾(ex: cd ~/project/flask_init)
-
執行網頁提供的指令
Image Not Showing
Possible Reasons
- The image file may be corrupted
- The server hosting the image is unavailable
- The image path is incorrect
- The image format is not supported
Learn More →
-
回到localhost:9000就可以看到靜態分析結果
補充
會出現 底下錯誤訊息:
Error when running: 'node -v'. Is Node.js available during analysis? No CSS files will be analyzed.
還不確定在哪裡修正