Use SO simulutor in cmso-robot

Issue-ID: OPTFRA-509
Change-Id: I2549e396311ad9582b898493e6bce311141a3b95
Signed-off-by: Jerry Flood <jflood@att.com>
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/resources/config/optimizer.properties b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/resources/config/optimizer.properties
index 6b72dd4..32636f4 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/resources/config/optimizer.properties
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/resources/config/optimizer.properties
@@ -53,6 +53,11 @@
 mechid.user=oof@oof.onap.org
 mechid.pass=enc:vfxQdJ1mgdcI7S6SPrzNaw==
 
+aaf.urls=https://aaf-locate:8095
+aaf.user.role.properties=/share/etc/certs/AAFUserRoles.properties
+aaf.enabled=true
+aaf.namespace=org.onap.oof
+
 cadi_loglevel=DEBUG
 cadi_prop_files=/share/etc/certs/org.onap.oof.props
 aaf.user.roles=/share/etc/certs/AAFUserRoles.properties
\ No newline at end of file
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/values.yaml b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/values.yaml
index 096332b..af56717 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/values.yaml
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-optimizer/values.yaml
@@ -25,12 +25,12 @@
 
 # application image
 repository: nexus3.onap.org:10001
-image: onap/optf-cmso-optimizer:2.0.0
+image: onap/optf-cmso-optimizer:2.1.1
 pullPolicy: Always
 
 #init container image
 dbinit:
-  image: onap/optf-cmso-dbinit:2.0.0
+  image: onap/optf-cmso-dbinit:2.1.1
 
 # flag to enable debugging - application support required
 debugEnabled: false
@@ -54,7 +54,7 @@
   enabled: true
 
 readiness:
-  initialDelaySeconds: 10
+  initialDelaySeconds: 120
   periodSeconds: 10
 
 
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/cmso.properties b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/cmso.properties
index c6c93ed..68b3688 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/cmso.properties
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/cmso.properties
@@ -102,6 +102,11 @@
 
 cmso.dispatch.url=http://localhost:8089
 
+aaf.urls=https://aaf-locate:8095
+aaf.user.role.properties=/share/etc/certs/AAFUserRoles.properties
+aaf.enabled=true
+aaf.namespace=org.onap.oof
+
 cadi_loglevel=DEBUG
 cadi_prop_files=/share/etc/certs/org.onap.oof.props
 aaf.user.roles=/share/etc/certs/AAFUserRoles.properties
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/mock.py b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/mock.py
deleted file mode 100644
index b678a4e..0000000
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/mock.py
+++ /dev/null
@@ -1,83 +0,0 @@
- # -------------------------------------------------------------------------
- #   Copyright (c) 2019 AT&T Intellectual Property
- #
- #   Licensed under the Apache License, Version 2.0 (the "License");
- #   you may not use this file except in compliance with the License.
- #   You may obtain a copy of the License at
- #
- #       http://www.apache.org/licenses/LICENSE-2.0
- #
- #   Unless required by applicable law or agreed to in writing, software
- #   distributed under the License is distributed on an "AS IS" BASIS,
- #   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- #   See the License for the specific language governing permissions and
- #   limitations under the License.
- #
- # -------------------------------------------------------------------------
- #
-
-from flask import Flask
-from flask import request
-from flask import Response
-from flask import json
-from flask import send_from_directory
-import requests
-from threading import Thread
-import time
-
-import os
-import fnmatch
-import re
-import time
-import datetime
-
-app = Flask(__name__)
-ROOT_MOCK_DIR = os.path.dirname(os.path.abspath(__file__))
-DATA_DIR =   os.path.join(ROOT_MOCK_DIR, "data")
-global requestNum
-requestNum = 1
-
-########################################################################
-########################################################################
-@app.route('/onap/so/infra/orchestrationRequests/v7/schedule/<VNFNAME>', methods=['GET', 'POST'])
-def soSchedule(VNFNAME):
-    if request.method == 'POST':
-        testid = request.headers.environ["HTTP_X_TRANSACTIONID"]
-        response = {
-            "status" : "202",
-            "entity" : {
-                "requestReferences" : {
-                    "requestId" : "000001"
-                    }
-                }
-            }
-        resp = Response(json.dumps(response), 200, mimetype='application/json')
-        return resp
-
-
-    else :
-        return "Helloooooo!!!!"
-
-########################################################################
-########################################################################
-@app.route('/onap/so/infra/orchestrationRequests/v7/<REQUESTID>', methods=['GET'])
-def soStatus(REQUESTID):
-    response = {"request" : { "requestStatus" : {
-        "requestState" : "COMPLETE",
-        "statusMessage" : "Done.",
-        "percentProgress" : 100,
-        "finishTime" : ""
-        }}}
-    now = datetime.datetime.utcnow()
-    #response["finishTime"] = now.strftime("%Y-%m-%dT%H:%M:%SZ")
-    response["request"]["requestStatus"]["finishTime"] = now.strftime("%a, %d %b %Y %H:%M:%S GMT")
-    resp = Response(json.dumps(response), 200, mimetype='application/json')
-
-    return resp
-
-########################################################################
-########################################################################
-if __name__ == "__main__":
-    app.run(host= '0.0.0.0',port=5000)
-    #app.run()
-
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/msosimulator.sh b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/msosimulator.sh
deleted file mode 100644
index c87a26b..0000000
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/resources/config/msosimulator.sh
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/sh
-pip install flask
-pip install requests
-python /share/etc/config/mock.py
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/templates/deployment.yaml b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/templates/deployment.yaml
index b26f6dd..1b17ed2 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/templates/deployment.yaml
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/templates/deployment.yaml
@@ -84,16 +84,11 @@
         resources:
 {{ include "common.resources" . }}
       - name: mso-simulator
-        image: "{{ .Values.global.pythonRepository }}/{{ .Values.global.pythonImage }}"
+        image: "{{ include "common.repository" . }}/{{ .Values.robotimage }}"
         imagePullPolicy: {{ .Values.global.pullPolicy | default .Values.pullPolicy }}
         volumeMounts:
         - name: {{ include "common.fullname" . }}-config
           mountPath: /share/etc/config
-        command:
-        - /bin/sh
-        args:
-        - -x
-        - /share/etc/config/msosimulator.sh
         ports:
         - containerPort: 5000        
         resources:
@@ -179,10 +174,6 @@
               path: ticketmgt.properties
             - key: liquibase.properties
               path: liquibase.properties
-            - key: mock.py
-              path: mock.py
-            - key: msosimulator.sh
-              path: msosimulator.sh
         - name:  {{ include "common.fullname" . }}-logs
           emptyDir: {}
         - name: {{ include "common.fullname" . }}-filebeat
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/values.yaml b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/values.yaml
index 3dad361..85f6094 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/values.yaml
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-service/values.yaml
@@ -19,20 +19,19 @@
   nodePortPrefix: 302
   readinessRepository: oomk8s
   readinessImage: readiness-check:2.0.0
-  pythonRepository: library
-  pythonImage: python:3.6-alpine
 
 subChartsOnly:
   enabled: true
 
 # application image
 repository: nexus3.onap.org:10001
-image: onap/optf-cmso-service:2.0.0
+image: onap/optf-cmso-service:2.1.1
+robotimage: onap/optf-cmso-robot:2.1.1
 pullPolicy: Always
 
 #init container image
 dbinit:
-  image: onap/optf-cmso-dbinit:2.0.0
+  image: onap/optf-cmso-dbinit:2.1.1
 
 # flag to enable debugging - application support required
 debugEnabled: false
@@ -56,7 +55,7 @@
   enabled: true
 
 readiness:
-  initialDelaySeconds: 10
+  initialDelaySeconds: 120
   periodSeconds: 10
 
 
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/resources/config/ticketmgt.properties b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/resources/config/ticketmgt.properties
index d687ab3..e8fb5b6 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/resources/config/ticketmgt.properties
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/resources/config/ticketmgt.properties
@@ -30,4 +30,9 @@
 #-------------------------------------------------------------------------------
 cadi_loglevel=DEBUG
 cadi_prop_files=/share/etc/certs/org.onap.oof.props
-aaf.user.roles=/share/etc/certs/AAFUserRoles.properties
\ No newline at end of file
+aaf.user.roles=/share/etc/certs/AAFUserRoles.properties
+
+aaf.urls=https://aaf-locate:8095
+aaf.user.role.properties=/share/etc/certs/AAFUserRoles.properties
+aaf.enabled=true
+aaf.namespace=org.onap.oof
\ No newline at end of file
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/values.yaml b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/values.yaml
index 7d093c1..300a72c 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/values.yaml
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-ticketmgt/values.yaml
@@ -26,7 +26,7 @@
 
 # application image
 repository: nexus3.onap.org:10001
-image: onap/optf-cmso-ticketmgt:2.0.0
+image: onap/optf-cmso-ticketmgt:2.1.1
 pullPolicy: Always
 
 
@@ -52,7 +52,7 @@
   enabled: true
 
 readiness:
-  initialDelaySeconds: 10
+  initialDelaySeconds: 120
   periodSeconds: 10
 
 
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/resources/config/topology.properties b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/resources/config/topology.properties
index d687ab3..e8fb5b6 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/resources/config/topology.properties
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/resources/config/topology.properties
@@ -30,4 +30,9 @@
 #-------------------------------------------------------------------------------
 cadi_loglevel=DEBUG
 cadi_prop_files=/share/etc/certs/org.onap.oof.props
-aaf.user.roles=/share/etc/certs/AAFUserRoles.properties
\ No newline at end of file
+aaf.user.roles=/share/etc/certs/AAFUserRoles.properties
+
+aaf.urls=https://aaf-locate:8095
+aaf.user.role.properties=/share/etc/certs/AAFUserRoles.properties
+aaf.enabled=true
+aaf.namespace=org.onap.oof
\ No newline at end of file
diff --git a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/values.yaml b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/values.yaml
index dc8040e..c8ac5d7 100644
--- a/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/values.yaml
+++ b/kubernetes/oof/charts/oof-cmso/charts/oof-cmso-topology/values.yaml
@@ -25,7 +25,7 @@
 
 # application image
 repository: nexus3.onap.org:10001
-image: onap/optf-cmso-topology:2.0.0
+image: onap/optf-cmso-topology:2.1.1
 pullPolicy: Always
 
 
@@ -51,7 +51,7 @@
   enabled: true
 
 readiness:
-  initialDelaySeconds: 10
+  initialDelaySeconds: 120
   periodSeconds: 10