From: Chen, Jackie (jv246a) Date: Tue, 19 Jan 2021 21:16:34 +0000 (-0500) Subject: adding one click repo and vth helm charts X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?p=it%2Fotf.git;a=commitdiff_plain;h=f035d8413fbe22f0a2157e11946e794c99fe5159 adding one click repo and vth helm charts Change-Id: I5d2dc641b3891b049ba8477ec2c72642f77dde00 Signed-off-by: Chen, Jackie Change-Id: I359414aa5a3de49cd3c8e2d6ad1fd0f7e3a7ecff Signed-off-by: Chen, Jackie --- diff --git a/one-click/README b/one-click/README new file mode 100644 index 0000000..9522299 --- /dev/null +++ b/one-click/README @@ -0,0 +1,62 @@ +**NOTE: +** Database must be initialized before the cores and VTHs are installed, docker images have to be build, and individual charts have to be updated to pull the correct image. +** If using one-click, you need to build or update the helm dependencies after updating the individual charts that should now point to correct docker images. Oneclick uses +** anchors and pointers in its yaml, so values need to be updated in the file, do not pass values in the command line as it will ignore those values. + +Prerequisites: +- Kubernetes +- Helm 3.0 +- Docker Images + +Useful k8 commands: + view ports: kubectl get svc -n [namespace] + view secrets: kubectl get secrets -n [namespace] + view pvc: kubectl get pvc -n [namespace] + +usefule helm commands: + dependency build: helm depenency build + dependency update: helm depenency udpate + install charts: helm install [chart_name] [path_to_chart] -n [namespace] + uninstall charts: helm uninstall [chart_name] -n [namespace] + view charts: helm ls -n [namespace] + + +1. This step is to install otf databases: mysql and mongodb + + NOTE: each install of dbs requires dbs to not have pvcs set, if they exist delete them on every install. If primary starts failing, uninstall and remove pvc and reinstall + a) helm install one-click-dbs -n [namespace] . (dir: otf-oran/one-click/one-click-dbs) + +2. This step is to install otf-core componenets: otf-service-api,otf-camunda, and otf-frontend + + a) modify one-click-core values.yaml (otf-oran/one-click/one-click-core/values.yaml) with correct secret name and ip from the previous step. Fill in otf-service-api and otf-camunda ip adresses. + NOTE: format is-> mongo-ip=X.X.X.X:27017 mysql-ip=X.X.X.X:3306/otf_camunda ips are the cluster ports + NOTE: format is-> otf-url: http://X.X.X.X:80 + camunda-url: http://X.X.X.X:8443/ + service-api-url: http://X.X.X.X:8443/otf/api/ + camunda-url-no-port: http://X.X.X.X + + b) fill in the rest of the values.yaml accordingly (ie, camunda-url,&svc-url,etc) + + c) helm install otf-core -n [namespace] . (dir: otf-oran/one-click/one-click-core) + +3. This step is to run otf-vths if desired (dir: otf-oran/one-click/one-click-vths). This step will deploy ALL of OTF's VTHS so if you are only deploying specfic ones, you should skip this step. + + a) robot vths needs a mongo connections so you will have to update the values.yaml (otf-oran/one-click/one-click-vths/values.yaml) with the approiate IP and mongo secret name from step one. format is mongo-ip=X.X.X.X:27017/ + + b) helm install otf-vths -n [namespace] . (dir: otf-oran/one-click/one-click-vths) + + +SELF-CHECK **MORE UPDATES COMING** + 1) kubectl get pods -n [namespace] *make sure all pods are running with no errors* + +**COMMONLY KNOWN ERRORS/WORKAROUNDS** +1) Later verisons of chrome might have an issue where users might get stuck on the login page when trying to login. + WORKAROUND: + - use firefox + - if you have to use chrome, go to your chrome brower and paste chrome://flags/#cookies-without-same-site-must-be-secure on the URL section and disable cookies must be secure flag. + + + ***NOTES*** + - defaut username and password-> otfuser@email.com:password (use this account to managed other users via user managment tab. You can change password via the mongo database) + - You have to be in a group before you can execute any workflows or add anything VTHs.(Test def, instance, execution are saved to the group that executed it) + - In values. \ No newline at end of file diff --git a/one-click/one-click-core/.helmignore b/one-click/one-click-core/.helmignore new file mode 100644 index 0000000..0e8a0eb --- /dev/null +++ b/one-click/one-click-core/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/one-click/one-click-core/Chart.yaml b/one-click/one-click-core/Chart.yaml new file mode 100644 index 0000000..9a7871d --- /dev/null +++ b/one-click/one-click-core/Chart.yaml @@ -0,0 +1,34 @@ +apiVersion: v2 +name: one-click-core +description: A Helm chart for one click deploymeny + +# A chart can be either an 'application' or a 'library' chart. +# +# Application charts are a collection of templates that can be packaged into versioned archives +# to be deployed. +# +# Library charts provide useful utilities or functions for the chart developer. They're included as +# a dependency of application charts to inject those utilities and functions into the rendering +# pipeline. Library charts do not define any templates and therefore cannot be deployed. +#type: application + +# This is the chart version. This version number should be incremented each time you make changes +# to the chart and its templates, including the app version. +#version: 0.1.0 +version: 0.0.1 + +# This is the version number of the application being deployed. This version number should be +# incremented each time you make changes to the application. +#appVersion: 1.16.0 +appVersion: "1.0" + +dependencies: +- name: otf-oran-service-api + version: 0.0.1-SNAPSHOT + repository: "file://../../otf-service-api/helm/otf-service-api/" +- name: otf-camunda + version: 0.0.1-SNAPSHOT + repository: "file://../../otf-camunda/helm/otf-camunda/" +- name: otf-frontend + version: 0.0.5-SNAPSHOT + repository: "file://../../otf-frontend/helm/otf-frontend/" diff --git a/one-click/one-click-core/values.yaml b/one-click/one-click-core/values.yaml new file mode 100644 index 0000000..23433a1 --- /dev/null +++ b/one-click/one-click-core/values.yaml @@ -0,0 +1,65 @@ +mongo-ip: &mongoIp 127.0.0.1:27017 +mongo-secret-name: &mongoSecret one-click-dbs-mongodb +mysql-ip: &mysqlIp 127.0.0.1:3306/otf_camunda +mysql-secret-name: &mysqlSecret mysql +otf-url: &otfUrl http://127.0.0.1:80 +camunda-url: &camundaUrl http://127.0.0.1:8443/ +service-api-url: &svcUrl http://127.0.0.1:8443/otf/api/ +camunda-url-no-port: &camundaUrlNoPort http://127.0.0.1 +camunda-port: &camundaPort 8443 + +otf-oran-service-api: + one_click: + mongo: + ip: *mongoIp + secret_name: *mongoSecret + otf: + camunda: + dev: + host: *camundaUrlNoPort + port: *camundaPort + st: + host: *camundaUrlNoPort + port: *camundaPort + prod: + host: *camundaUrlNoPort + port: *camundaPort + prod_dr: + host: *camundaUrlNoPort + port: *camundaPort +otf-camunda: + one_click: + mongo: + ip: *mongoIp + secret_name: *mongoSecret + mysql: + ip: *mysqlIp + secret_name: *mysqlSecret +otf-frontend: + one_click: + mongo: + ip: *mongoIp + secret_name: *mongoSecret + otf: + OTF_URL: + dev: *otfUrl + st: *otfUrl + prod: *otfUrl + serviceApi: + prod: + SERVICEAPI_URL: *svcUrl + prod_dr: + SERVICEAPI_URL: *svcUrl + st: + SERVICEAPI_URL: *svcUrl + dev: + SERVICEAPI_URL: *svcUrl + camundaApi: + prod: + CAMUNDAAPI_URL: *camundaUrl + prod_dr: + CAMUNDAAPI_URL: *camundaUrl + st: + CAMUNDAAPI_URL: *camundaUrl + dev: + CAMUNDAAPI_URL: *camundaUrl diff --git a/one-click/one-click-dbs/.helmignore b/one-click/one-click-dbs/.helmignore new file mode 100644 index 0000000..50af031 --- /dev/null +++ b/one-click/one-click-dbs/.helmignore @@ -0,0 +1,22 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/one-click/one-click-dbs/Chart.yaml b/one-click/one-click-dbs/Chart.yaml new file mode 100644 index 0000000..cc93147 --- /dev/null +++ b/one-click/one-click-dbs/Chart.yaml @@ -0,0 +1,16 @@ +apiVersion: v1 +appVersion: "1.0" +description: A Helm chart for one click deploymeny +name: otf-one-click +version: 0.0.1 +dependencies: +- name: mongodb + version: "7.8.10" + repository: "file://../../otf-helm/otf/charts/databases/mongodb" +- name: mysql + version: 1.6.6 + repository: "file://../../otf-helm/otf/charts/databases/mysqldb" +# repository: {{ .Values.global.root_path }}otf-helm/otf/charts/databases/mongodb +#- name: service-api +# version: {{.Values.gloabl.version}} +# repository: {{.Values.global.root_path}}otf-service-api/helm/otf-service-api diff --git a/one-click/one-click-dbs/values.yaml b/one-click/one-click-dbs/values.yaml new file mode 100644 index 0000000..d907f0f --- /dev/null +++ b/one-click/one-click-dbs/values.yaml @@ -0,0 +1,8 @@ +#namespace: &namespace db + +#mysql: +# namespace: *namespace + +#mongodb: +# namespace: *namespace + diff --git a/one-click/one-click-vths/.helmignore b/one-click/one-click-vths/.helmignore new file mode 100644 index 0000000..0e8a0eb --- /dev/null +++ b/one-click/one-click-vths/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/one-click/one-click-vths/Chart.yaml b/one-click/one-click-vths/Chart.yaml new file mode 100644 index 0000000..f233748 --- /dev/null +++ b/one-click/one-click-vths/Chart.yaml @@ -0,0 +1,52 @@ +apiVersion: v2 +name: one-click-vhts +description: A Helm chart for one click vth deploymeny + +# A chart can be either an 'application' or a 'library' chart. +# +# Application charts are a collection of templates that can be packaged into versioned archives +# to be deployed. +# +# Library charts provide useful utilities or functions for the chart developer. They're included as +# a dependency of application charts to inject those utilities and functions into the rendering +# pipeline. Library charts do not define any templates and therefore cannot be deployed. +#type: application + +# This is the chart version. This version number should be incremented each time you make changes +# to the chart and its templates, including the app version. +#version: 0.1.0 +version: 0.0.1 + +# This is the version number of the application being deployed. This version number should be +# incremented each time you make changes to the application. +#appVersion: 1.16.0 +appVersion: "1.0" + +dependencies: +- name: a1-mediator-vth + version: 0.0.1 + repository: "file://../../a1-mediator-vth/helm/a1-mediator-vth/" +- name: a1-policy-manager-vth + version: 0.0.1 + repository: "file://../../a1-policy-manager-vth/helm/a1-policy-manager-vth/" +- name: a1-sdnc-vth + version: 0.0.1 + repository: "file://../../a1-sdnc-vth/helm/a1-sdnc-vth/" +- name: dmaap-vth + version: 0.0.1 + repository: "file://../../dmaap-vth/helm/dmaap-vth/" +- name: otf-ping-test-head + version: 0.0.1 + repository: "file://../../otf-ping-test-head/helm/otf-ping-test-head/" +- name: oran-ric-test-head + version: 0.0.1 + repository: "file://../../oran-ric-test-head/helm/ric-test-head/" +- name: otf-ssh-test-head + version: 0.0.1 + repository: "file://../../otf-ssh-test-head/helm/otf-ssh-test-head/" +- name: smo-o1-vth + version: 0.0.1 + repository: "file://../../smo-o1-vth/helm/smo-o1-vth/" +- name: otf-robot-test-head + version: 0.0.5-SNAPSHOT + repository: "file://../../otf-robot-test-head/helm/otf-robot-test-head/" diff --git a/one-click/one-click-vths/values.yaml b/one-click/one-click-vths/values.yaml new file mode 100644 index 0000000..ceb4693 --- /dev/null +++ b/one-click/one-click-vths/values.yaml @@ -0,0 +1,8 @@ +mongo-ip: &mongoIp 10.0.248.46:27017/ +mongo-secret-name: &mongoSecret one-click-dbs-mongodb + +otf-robot-test-head: + one_click: + mongo: + ip: *mongoIp + secret_name: *mongoSecret