Install ReportPortal
Inspect the prerequisites and the main steps to perform for installing ReportPortal.
Prerequisites​
- Kubectl version 1.34.0+ is installed. Please refer to the Kubernetes official website for details.
- Helm version 3.14.0+ is installed. Please refer to the Helm page on GitHub for details.
Please refer to the ReportPortal Helm Chart section for details.
MinIO Installation​
To install MinIO, follow the steps below:
-
Check that
krcinamespace is created. If not, run the following command to create it:kubectl create namespace krciFor the OpenShift usersWhen using the OpenShift platform, install the
SecurityContextConstraintsresources.
In case of using a custom namespace for thereportportal, change the namespace in theuserssection.View: report-portal-third-party-resources-scc.yaml
apiVersion: security.openshift.io/v1kind: SecurityContextConstraintsmetadata:annotations:"helm.sh/hook": "pre-install"name: report-portal-minio-rabbitmq-postgresqlallowHostDirVolumePlugin: falseallowHostIPC: falseallowHostNetwork: falseallowHostPID: falseallowHostPorts: falseallowPrivilegeEscalation: trueallowPrivilegedContainer: falseallowedCapabilities: nullallowedFlexVolumes: []defaultAddCapabilities: []fsGroup:type: MustRunAsranges:- min: 999max: 65543groups: []priority: 1readOnlyRootFilesystem: falserequiredDropCapabilities:- KILL- MKNOD- SETUID- SETGIDrunAsUser:type: MustRunAsRangeuidRangeMin: 1uidRangeMax: 65543seLinuxContext:type: MustRunAssupplementalGroups:type: RunAsAnyusers:- system:serviceaccount:report-portal:minio- system:serviceaccount:report-portal:rabbitmq- system:serviceaccount:report-portal:postgresqlvolumes:- configMap- downwardAPI- emptyDir- persistentVolumeClaim- projected- secretView: report-portal-elasticsearch-scc.yaml
apiVersion: security.openshift.io/v1kind: SecurityContextConstraintsmetadata:annotations:"helm.sh/hook": "pre-install"name: report-portal-elasticsearchallowHostDirVolumePlugin: falseallowHostIPC: falseallowHostNetwork: falseallowHostPID: falseallowHostPorts: falseallowPrivilegedContainer: trueallowedCapabilities: []allowedFlexVolumes: []defaultAddCapabilities: []fsGroup:type: MustRunAsranges:- max: 1000min: 1000groups: []priority: 0readOnlyRootFilesystem: falserequiredDropCapabilities: []runAsUser:type: MustRunAsRangeuidRangeMax: 1000uidRangeMin: 0seLinuxContext:type: MustRunAssupplementalGroups:type: RunAsAnyusers:- system:serviceaccount:report-portal:elasticsearch-mastervolumes:- configMap- downwardAPI- emptyDir- persistentVolumeClaim- projected- secret -
Add a chart repository:
helm repo add bitnami https://charts.bitnami.com/bitnamihelm repo update -
Create MinIO admin secret:
kubectl -n krci create secret generic reportportal-minio-creds \--from-literal=root-password=<root_password> \--from-literal=root-user=<root_user> -
Install MinIO v.11.10.3 using bitnami/minio Helm chart v.11.10.3:
helm install minio bitnami/minio \--version 11.10.3 \--values values.yaml \--namespace krciCheck out the values.yaml file sample of the MinIO customization:
View: values.yaml
auth:existingSecret: reportportal-minio-credspersistence:size: 1Gi
RabbitMQ Installation​
To install RabbitMQ, follow the steps below:
-
Use the
krcinamespace from the MinIO installation. -
Use
bitnamichart repository from the MinIO installation. -
Create RabbitMQ admin secret:
kubectl -n krci create secret generic reportportal-rabbitmq-creds \--from-literal=rabbitmq-password=<rabbitmq_password> \--from-literal=rabbitmq-erlang-cookie=<rabbitmq_erlang_cookie>warningThe
rabbitmq_passwordpassword must be 10 characters long.
Therabbitmq_erlang_cookiepassword must be 32 characters long. -
Install RabbitMQ v.10.3.8 using bitnami/rabbitmq Helm chart v.10.3.8:
helm install rabbitmq bitnami/rabbitmq \--version 10.3.8 \--values values.yaml \--namespace krciCheck out the values.yaml file sample of the RabbitMQ customization:
View: values.yaml
auth:existingPasswordSecret: reportportal-rabbitmq-credsexistingErlangSecret: reportportal-rabbitmq-credspersistence:size: 1Gi -
After the rabbitmq pod gets the status Running, you need to configure the RabbitMQ memory threshold
kubectl -n krci exec -it rabbitmq-0 -- rabbitmqctl set_vm_memory_high_watermark 0.8
Elasticsearch Installation​
To install Elasticsearch, follow the steps below:
-
Use
krcinamespace from the MinIO installation. -
Add a chart repository:
helm repo add elastic https://helm.elastic.cohelm repo update -
Install Elasticsearch v.7.17.3 using elastic/elasticsearch Helm chart v.7.17.3:
helm install elasticsearch elastic/elasticsearch \--version 7.17.3 \--values values.yaml \--namespace krciCheck out the values.yaml file sample of the Elasticsearch customization:
View: values.yaml
replicas: 1extraEnvs:- name: discovery.typevalue: single-node- name: cluster.initial_master_nodesvalue: ""rbac:create: trueresources:requests:cpu: "100m"memory: "2Gi"volumeClaimTemplate:resources:requests:storage: 3Gi
PostgreSQL Installation​
To install PostgreSQL, follow the steps below:
-
Use
krcinamespace from the MinIO installation. -
Add a chart repository:
helm repo add bitnami-archive https://raw.githubusercontent.com/bitnami/charts/archive-full-index/bitnamihelm repo update -
Create PostgreSQL admin secret:
kubectl -n krci create secret generic reportportal-postgresql-creds \--from-literal=postgresql-password=<postgresql_password> \--from-literal=postgresql-postgres-password=<postgresql_postgres_password>warningThe
postgresql_passwordandpostgresql_postgres_passwordpasswords must be 16 characters long. -
Install PostgreSQL v.10.9.4 using Helm chart v.10.9.4:
helm install postgresql bitnami-archive/postgresql \--version 10.9.4 \--values values.yaml \--namespace krciCheck out the values.yaml file sample of the PostgreSQL customization:
View: values.yaml
persistence:size: 1Giresources:requests:cpu: "100m"serviceAccount:enabled: truepostgresqlUsername: "rpuser"postgresqlDatabase: "reportportal"existingSecret: "reportportal-postgresql-creds"initdbScripts:init_postgres.sh: |#!/bin/sh/opt/bitnami/postgresql/bin/psql -U postgres -d ${POSTGRES_DB} -c 'CREATE EXTENSION IF NOT EXISTS ltree; CREATE EXTENSION IF NOT EXISTS pgcrypto; CREATE EXTENSION IF NOT EXISTS pg_trgm;'
ReportPortal Installation​
To install ReportPortal, follow the steps below:
-
Use
krcinamespace from the MinIO installation.For the OpenShift usersWhen using the OpenShift platform, install the
SecurityContextConstraintsresource.
In case of using a custom namespace for thereportportal, change the namespace in theuserssection.View: report-portal-reportportal-scc.yaml
apiVersion: security.openshift.io/v1kind: SecurityContextConstraintsmetadata:annotations:"helm.sh/hook": "pre-install"name: report-portalallowHostDirVolumePlugin: falseallowHostIPC: falseallowHostNetwork: falseallowHostPID: falseallowHostPorts: falseallowPrivilegedContainer: trueallowedCapabilities: []allowedFlexVolumes: []defaultAddCapabilities: []fsGroup:type: MustRunAsranges:- max: 1000min: 1000groups: []priority: 0readOnlyRootFilesystem: falserequiredDropCapabilities: []runAsUser:type: MustRunAsRangeuidRangeMax: 1000uidRangeMin: 0seLinuxContext:type: MustRunAssupplementalGroups:type: RunAsAnyusers:- system:serviceaccount:report-portal:reportportalvolumes:- configMap- downwardAPI- emptyDir- persistentVolumeClaim- projected- secret -
Add a chart repository:
helm repo add report-portal "https://reportportal.github.io/kubernetes"helm repo update -
Install ReportPortal v.5.8.0 using Helm chart v.5.8.0:
helm install report-portal report-portal/reportportal \--values values.yaml \--namespace krciCheck out the values.yaml file sample of the ReportPortal customization:
View: values.yaml
serviceindex:resources:requests:cpu: 50muat:resources:requests:cpu: 50mserviceui:resources:requests:cpu: 50mserviceAccountName: "reportportal"securityContext:runAsUser: 0serviceapi:resources:requests:cpu: 50mserviceanalyzer:resources:requests:cpu: 50mserviceanalyzertrain:resources:requests:cpu: 50mrabbitmq:SecretName: "reportportal-rabbitmq-creds"endpoint:address: rabbitmq.<EDP_PROJECT>.svc.cluster.localuser: userapiuser: userpostgresql:SecretName: "reportportal-postgresql-creds"endpoint:address: postgresql.<EDP_PROJECT>.svc.cluster.localelasticsearch:endpoint: http://elasticsearch-master.<EDP_PROJECT>.svc.cluster.local:9200minio:secretName: "reportportal-minio-creds"endpoint: http://minio.<EDP_PROJECT>.svc.cluster.local:9000endpointshort: minio.<EDP_PROJECT>.svc.cluster.local:9000accesskeyName: "root-user"secretkeyName: "root-password"ingress:# IF YOU HAVE SOME DOMAIN NAME SET INGRESS.USEDOMAINNAME to trueusedomainname: truehosts:- report-portal-<EDP_PROJECT>.<ROOT_DOMAIN> -
For the OpenShift platform, install a Gateway with Route:
View: gateway-config-cm.yaml
kind: ConfigMapmetadata:name: gateway-confignamespace: report-portalapiVersion: v1data:traefik-dynamic-config.yml: |http:middlewares:strip-ui:stripPrefix:prefixes:- "/ui"forceSlash: falsestrip-api:stripPrefix:prefixes:- "/api"forceSlash: falsestrip-uat:stripPrefix:prefixes:- "/uat"forceSlash: falserouters:index-router:rule: "Path(`/`)"service: "index"ui-router:rule: "PathPrefix(`/ui`)"middlewares:- strip-uiservice: "ui"uat-router:rule: "PathPrefix(`/uat`)"middlewares:- strip-uatservice: "uat"api-router:rule: "PathPrefix(`/api`)"middlewares:- strip-apiservice: "api"services:uat:loadBalancer:servers:- url: "http://report-portal-reportportal-uat:9999/"index:loadBalancer:servers:- url: "http://report-portal-reportportal-index:8080/"api:loadBalancer:servers:- url: "http://report-portal-reportportal-api:8585/"ui:loadBalancer:servers:- url: "http://report-portal-reportportal-ui:8080/"traefik.yml: |entryPoints:http:address: ":8081"metrics:address: ":8082"metrics:prometheus:entryPoint: metricsaddEntryPointsLabels: trueaddServicesLabels: truebuckets:- 0.1- 0.3- 1.2- 5.0providers:file:filename: /etc/traefik/traefik-dynamic-config.ymlView: gateway-deployment.yaml
apiVersion: apps/v1kind: Deploymentmetadata:labels:app: reportportalname: gatewaynamespace: report-portalspec:replicas: 1selector:matchLabels:component: gatewaytemplate:metadata:labels:component: gatewayspec:containers:- image: quay.io/waynesun09/traefik:2.3.6name: traefikports:- containerPort: 8080protocol: TCPresources: {}volumeMounts:- mountPath: /etc/traefik/name: configreadOnly: truevolumes:- name: configconfigMap:defaultMode: 420name: gateway-configView: gateway-route.yaml
kind: RouteapiVersion: route.openshift.io/v1metadata:labels:app: reportportalname: reportportalnamespace: report-portalspec:host: report-portal.<CLUSTER_DOMAIN>port:targetPort: httptls:insecureEdgeTerminationPolicy: Redirecttermination: edgeto:kind: Servicename: gatewayweight: 100wildcardPolicy: NoneView: gateway-service.yaml
apiVersion: v1kind: Servicemetadata:labels:app: reportportalcomponent: gatewayname: gatewaynamespace: report-portalspec:ports:# use 8081 to allow for usage of the dashboard which is on port 8080- name: httpport: 8081protocol: TCPtargetPort: 8081selector:component: gatewaysessionAffinity: Nonetype: ClusterIP
For user access: default/1q2w3e
For admin access: superadmin/erebus
Please refer to the ReportPortal.io page for details.
It is also possible to install ReportPortal via cluster add-ons. For details, please refer to the Install via Add-Ons page.