Skip to content

Latest commit

 

History

History
64 lines (46 loc) · 2.08 KB

README.md

File metadata and controls

64 lines (46 loc) · 2.08 KB

SonarQube

This Helm chart will install SonarQube and is based from the official Helm chart (docs).

How to update the chart

# adds helm chart repository
helm repo add sonarqube https://sonarsource.github.io/helm-chart-sonarqube
helm repo update

# searches for the latest version
helm search repo -l sonarqube

# manual: update version number in Chart.yaml

# updates Chart.lock
helm dependency update

How to deploy manually

# gets ingress controller public IP
NGINX_PUBLIC_IP=`kubectl get service -n ingress-nginx ingress-nginx-controller --output jsonpath='{.status.loadBalancer.ingress[0].ip}'`

# checks the Kubernetes objects generated from the chart
helm template sonarqube . -f values.yaml \
  --namespace supply-chain > temp.yaml

# applies the manifest (add "--debug > output.yaml" in case of issue)
helm upgrade --install sonarqube . -f values.yaml --create-namespace \
  --set sonarqube.ingress.hosts[0].name=sonarqube.${NGINX_PUBLIC_IP}.sslip.io \
  --set sonarqube.ingress.tls[0].hosts[0]=sonarqube.${NGINX_PUBLIC_IP}.sslip.io \
  --namespace supply-chain

# checks everything is ok
kubectl get ingress -lrelease=sonarqube -n supply-chain

# manual: open https://sonarqube.${NGINX_PUBLIC_IP}.sslip.io/ (and login with admin/admin)

# if needed, deletes the chart
helm uninstall sonarqube -n supply-chain

How to investigate

  • checks existings resources
kubectl get all -n supply-chain
kubectl get Issuers,ClusterIssuers,Certificates,CertificateRequests,Orders,Challenges -n supply-chain

How to start

  • Go to SonarQube URL
  • "My Account" > "Security" > "Tokens"
    • Generate Global Analysis Token
  • "How do you want to create your project?" > "From GitLab"