X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=docs%2Finstallation-guide.rst;h=9b63c7c63778cb33ef8122ee531655fc85b92be7;hb=refs%2Fchanges%2F40%2F9340%2F1;hp=3c92bd3a2020f947d7848cac67ac50dcd45acd45;hpb=330e15935177e9d9e8442eb67354f9122f2871b1;p=pti%2Fo2.git diff --git a/docs/installation-guide.rst b/docs/installation-guide.rst index 3c92bd3..9b63c7c 100644 --- a/docs/installation-guide.rst +++ b/docs/installation-guide.rst @@ -136,9 +136,51 @@ The following instruction should be done outside of INF platform controller host export OS_PASSWORD= # If the external OAM IP same as OS_AUTH_URL's IP address, you can use the below command to set the environment - # export API_HOST_EXTERNAL_FLOATING=$(echo ${OS_AUTH_URL/$(echo ${OS_AUTH_URL} | grep :// | sed -e's,^\(.*//\).*,\1,g')} | cut -d/ -f1 | sed -e 's,:.*,,g') + # export API_HOST_EXTERNAL_FLOATING=$(echo ${OS_AUTH_URL} | sed -e s,`echo ${OS_AUTH_URL} | grep :// | sed -e's,^\(.*//\).*,\1,g'`,,g | cut -d/ -f1 | sed -e 's,:.*,,g') export API_HOST_EXTERNAL_FLOATING= + # please specify the smo service account yaml file + export SMO_SERVICEACCOUNT= + # service account and binding for smo yaml file + + cat <smo-serviceaccount.yaml + apiVersion: rbac.authorization.k8s.io/v1 + kind: Role + metadata: + namespace: default + name: pod-reader + rules: + - apiGroups: [""] # "" indicates the core API group + resources: ["pods"] + verbs: ["get", "watch", "list"] + --- + apiVersion: v1 + kind: ServiceAccount + metadata: + name: ${SMO_SERVICEACCOUNT} + namespace: default + --- + apiVersion: rbac.authorization.k8s.io/v1 + kind: RoleBinding + metadata: + name: read-pods + namespace: default + roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: pod-reader + subjects: + - kind: ServiceAccount + name: ${SMO_SERVICEACCOUNT} + namespace: default + + EOF + + kubectl apply -f smo-serviceaccount.yaml + + #export the smo account token data + export SMO_TOKEN_DATA=$(kubectl -n default describe secret $(kubectl -n default get secret | grep ${SMO_SERVICEACCOUNT} | awk '{print $1}') | grep "token:" | awk '{print $2}') + cat <o2service-override.yaml o2ims: imagePullSecrets: admin-orano2-registry-secret @@ -154,6 +196,7 @@ The following instruction should be done outside of INF platform controller host OS_PASSWORD: "${OS_PASSWORD}" K8S_KUBECONFIG: "/opt/k8s_kube.conf" API_HOST_EXTERNAL_FLOATING: "${API_HOST_EXTERNAL_FLOATING}" + EOF @@ -164,8 +207,8 @@ The following instruction should be done outside of INF platform controller host helm install o2service o2/charts/ -f o2service-override.yaml helm list |grep o2service - kubectl -n ${NAMESPACE} get pods |grep o2service - kubectl -n ${NAMESPACE} get services |grep o2service + kubectl -n ${NAMESPACE} get pods |grep o2api + kubectl -n ${NAMESPACE} get services |grep o2api 2.4 Verify INF O2 service