diff options
Diffstat (limited to 'kubernetes/appc')
9 files changed, 80 insertions, 60 deletions
diff --git a/kubernetes/appc/charts/appc-cdt/templates/deployment.yaml b/kubernetes/appc/charts/appc-cdt/templates/deployment.yaml index 2192662d6a..fd29fbebfb 100644 --- a/kubernetes/appc/charts/appc-cdt/templates/deployment.yaml +++ b/kubernetes/appc/charts/appc-cdt/templates/deployment.yaml @@ -57,9 +57,9 @@ spec: env: # This sets the port that CDT will use to connect to the main appc container. # The 11 is the node port suffix that is used in the main appc oom templates - # for nodePort3. This value will be configured in appc main chart in appc-cdt section. + # for nodePort4. This value will be configured in appc main chart in appc-cdt section. - name: CDT_PORT - value: "{{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.nodePort3 }}" + value: "{{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.nodePort4 }}" volumeMounts: - mountPath: /etc/localtime name: localtime diff --git a/kubernetes/appc/charts/appc-cdt/values.yaml b/kubernetes/appc/charts/appc-cdt/values.yaml index 7db9527a7f..52adfc4d6e 100644 --- a/kubernetes/appc/charts/appc-cdt/values.yaml +++ b/kubernetes/appc/charts/appc-cdt/values.yaml @@ -26,7 +26,7 @@ flavor: small # application image repository: nexus3.onap.org:10001 -image: onap/appc-cdt-image:1.5.3 +image: onap/appc-cdt-image:1.6.3 pullPolicy: Always # application configuration diff --git a/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh index ad135f863a..c52c6e3aa1 100755 --- a/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh +++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh @@ -111,8 +111,6 @@ then # echo "Copying a working version of the logging configuration into the opendaylight etc folder" # cp ${APPC_HOME}/data/org.ops4j.pax.logging.cfg ${ODL_HOME}/etc/org.ops4j.pax.logging.cfg - echo "Starting OpenDaylight" - ${ODL_HOME}/bin/start echo "Waiting ${SLEEP_TIME} seconds for OpenDaylight to initialize" sleep ${SLEEP_TIME} @@ -137,6 +135,7 @@ then fi echo "Copying the aaa shiro configuration into opendaylight" + mkdir -p ${ODL_HOME}/etc/opendaylight/datastore/initial/config if $ENABLE_AAF then cp ${APPC_HOME}/data/properties/aaa-app-config.xml ${ODL_HOME}/etc/opendaylight/datastore/initial/config/aaa-app-config.xml @@ -144,29 +143,6 @@ then cp ${APPC_HOME}/data/aaa-app-config.xml ${ODL_HOME}/etc/opendaylight/datastore/initial/config/aaa-app-config.xml fi - echo "Restarting OpenDaylight" - ${ODL_HOME}/bin/stop - checkRun () { - running=0 - while read a b c d e f g h - do - if [ "$h" == "/bin/sh /opt/opendaylight/bin/karaf server" ] - then - running=1 - fi - done < <(ps -eaf) - echo $running - } - - while [ $( checkRun ) == 1 ] - do - echo "Karaf is still running, waiting..." - sleep 5s - done - echo "Karaf process has stopped" - sleep 10s - - echo "Installed at `date`" > ${SDNC_HOME}/.installed fi # Move journal and snapshots directory to persistent storage @@ -195,5 +171,27 @@ ln -s ${hostdir}/snapshots ${ODL_HOME}/snapshots echo "Starting cdt-proxy-service jar, logging to ${APPC_HOME}/cdt-proxy-service/jar.log" java -jar ${APPC_HOME}/cdt-proxy-service/cdt-proxy-service.jar > ${APPC_HOME}/cdt-proxy-service/jar.log & -exec ${ODL_HOME}/bin/karaf server +echo "Adding a property system.properties for AAF cadi.properties location" +echo "" >> ${ODL_HOME}/etc/system.properties +echo "cadi_prop_files=${APPC_HOME}/data/properties/cadi.properties" >> ${ODL_HOME}/etc/system.properties +echo "" >> ${ODL_HOME}/etc/system.properties + +echo "Adding a value to property appc.asdc.env in appc.properties for appc-asdc-listener feature" +echo "" >> $APPC_HOME/data/properties/appc.properties +echo "appc.asdc.env=$DMAAP_TOPIC_ENV" >> $APPC_HOME/data/properties/appc.properties +echo "" >> $APPC_HOME/data/properties/appc.properties + +echo "Copying jetty, keystore for https into opendalight" +cp ${APPC_HOME}/data/jetty.xml ${ODL_HOME}/etc/jetty.xml +cp ${APPC_HOME}/data/keystore ${ODL_HOME}/etc/keystore +cp ${APPC_HOME}/data/custom.properties ${ODL_HOME}/etc/custom.properties +echo "Copying a working version of the logging configuration into the opendaylight etc folder" +cp ${APPC_HOME}/data/org.ops4j.pax.logging.cfg ${ODL_HOME}/etc/org.ops4j.pax.logging.cfg + +ODL_BOOT_FEATURES_EXTRA="odl-netconf-connector,odl-restconf-noauth,odl-netconf-clustered-topology,odl-mdsal-clustering" +sed -i -e "\|featuresBoot[^a-zA-Z]|s|$|,${ODL_BOOT_FEATURES_EXTRA}|" $ODL_HOME/etc/org.apache.karaf.features.cfg + +exec ${APPC_HOME}/bin/dockerInstall.sh & +echo "Starting OpenDaylight" +exec ${ODL_HOME}/bin/karaf server diff --git a/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaa-app-config.xml b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaa-app-config.xml index 81834eaafc..de6e7e4742 100644 --- a/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaa-app-config.xml +++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/aaa-app-config.xml @@ -80,42 +80,42 @@ <urls> <pair-key>/auth/**</pair-key> <!-- <pair-value>authcBasic, roles[admin], dynamicAuthorization</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/restconf/config/aaa-cert-mdsal**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/restconf/operational/aaa-cert-mdsal**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/restconf/operations/aaa-cert-rpc**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/restconf/config/aaa-authn-model**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/restconf/operational/aaa-authn-model**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/restconf/operations/cluster-admin**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> <urls> <pair-key>/**</pair-key> <!-- <pair-value>authcBasic, roles[admin]</pair-value> --> - <pair-value>authcBasic, roles[org.onap.appc.odl|odl-api|*]</pair-value> + <pair-value>authcBasic, roles[org.onap.appc.odl:odl-api:*]</pair-value> </urls> </shiro-configuration> diff --git a/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/bath_config.csv b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/bath_config.csv new file mode 100644 index 0000000000..24a3dff7e2 --- /dev/null +++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/bath_config.csv @@ -0,0 +1,8 @@ +# APPC HELM CHART APPC_RESTCONF_UI -> appc@appc.onap.org +Basic YWRtaW46S3A4Yko0U1hzek0wV1hsaGFrM2VIbGNzZTJnQXc4NHZhb0dHbUp2VXkyVQ==,Basic YXBwY0BhcHBjLm9uYXAub3JnOmRlbW8xMjM0NTYh,2050-03-03 +# jolokiaall = demo@people.osaaf.org +Basic am9sb2tpYWFsbDpqb2xva2lhYWxs,Basic ZGVtb0BwZW9wbGUub3NhYWYub3JnOmRlbW8xMjM0NTYh,2050-03-03 +# restall = aaf_admin@people.osaaf.org +Basic cmVzdGFsbDpyZXN0YWxs,Basic YWFmX2FkbWluQHBlb3BsZS5vc2FhZi5vcmc6ZGVtbzEyMzQ1NiE=,2050-03-03 +# odlro = mmmanger@people.osaaf.org +Basic b2Rscm86b2Rscm8=,Basic bW1tYW5nZXJAcGVvcGxlLm9zYWFmLm9yZzpkZW1vMTIzNDU2IQ==,2050-03-03 diff --git a/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/cadi.properties b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/cadi.properties index 0e8b71cf53..e7399f6f04 100644 --- a/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/cadi.properties +++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/data/properties/cadi.properties @@ -19,7 +19,7 @@ ### #hostname=localhost -cadi_loglevel=INFO +cadi_loglevel=DEBUG cadi_bath_convert=/opt/onap/appc/data/properties/bath_config.csv ############################################################ @@ -48,11 +48,11 @@ cadi_longitude=-122.26147 aaf_locate_url=https://aaf-locate.{{.Release.Namespace}}:8095 # AAF URL -aaf_url=https://AAF_LOCATE_URL/AAF_NS.service:2.0 +aaf_url=https://AAF_LOCATE_URL/onap.org.osaaf.aaf.service:2.1 # AAF Environment Designation aaf_env=DEV # OAuth2 Endpoints -aaf_oauth2_token_url=https://AAF_LOCATE_URL/AAF_NS.token:2.0/token -aaf_oauth2_introspect_url=https://AAF_LOCATE_URL/AAF_NS.introspect:2.0/introspect +aaf_oauth2_token_url=https://AAF_LOCATE_URL/onap.org.osaaf.aaf.token:2.1/token +aaf_oauth2_introspect_url=https://AAF_LOCATE_URL/onap.org.osaaf.aaf.introspect:2.1/introspect diff --git a/kubernetes/appc/templates/service.yaml b/kubernetes/appc/templates/service.yaml index fdd31a4ed0..a44214a611 100644 --- a/kubernetes/appc/templates/service.yaml +++ b/kubernetes/appc/templates/service.yaml @@ -41,23 +41,31 @@ spec: - port: {{ .Values.service.externalPort }} targetPort: {{ .Values.service.internalPort }} nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }} - name: "{{ .Values.service.portName }}-8443" + name: "{{ .Values.service.portName }}-8282" - port: {{ .Values.service.externalPort2 }} + targetPort: {{ .Values.service.internalPort2 }} nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort2 }} - name: "{{ .Values.service.portName }}-1830" + name: "{{ .Values.service.portName }}-8443" - port: {{ .Values.service.externalPort3 }} targetPort: {{ .Values.service.internalPort3 }} nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort3 }} + name: "{{ .Values.service.portName }}-1830" + - port: {{ .Values.service.externalPort4 }} + targetPort: {{ .Values.service.internalPort4 }} + nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort4 }} name: "{{ .Values.service.portName }}-9090" {{- else -}} - port: {{ .Values.service.externalPort }} targetPort: {{ .Values.service.internalPort }} - name: {{ .Values.service.portName }}-8443 + name: {{ .Values.service.portName }}-8282 - port: {{ .Values.service.externalPort2 }} targetPort: {{ .Values.service.internalPort2 }} - name: {{ .Values.service.portName }}-1830 + name: {{ .Values.service.portName }}-8443 - port: {{ .Values.service.externalPort3 }} targetPort: {{ .Values.service.internalPort3 }} + name: {{ .Values.service.portName }}-1830 + - port: {{ .Values.service.externalPort4 }} + targetPort: {{ .Values.service.internalPort4 }} name: {{ .Values.service.portName }}-9090 {{- end}} selector: diff --git a/kubernetes/appc/templates/statefulset.yaml b/kubernetes/appc/templates/statefulset.yaml index 4fded9aa24..1401a8225d 100644 --- a/kubernetes/appc/templates/statefulset.yaml +++ b/kubernetes/appc/templates/statefulset.yaml @@ -108,6 +108,9 @@ spec: - mountPath: /opt/onap/appc/data/properties/aaa-app-config.xml name: onap-appc-data-properties subPath: aaa-app-config.xml + - mountPath: /opt/onap/appc/data/properties/bath_config.csv + name: onap-appc-data-properties + subPath: bath_config.csv - mountPath: /opt/onap/appc/svclogic/config/svclogic.properties name: onap-appc-svclogic-config subPath: svclogic.properties @@ -145,7 +148,7 @@ spec: name: {{ include "common.fullname" . }}-data - mountPath: /var/log/onap name: logs - - mountPath: /opt/opendaylight/current/etc/org.ops4j.pax.logging.cfg + - mountPath: /opt/onap/appc/data/org.ops4j.pax.logging.cfg name: log-config subPath: org.ops4j.pax.logging.cfg resources: diff --git a/kubernetes/appc/values.yaml b/kubernetes/appc/values.yaml index 578dbc7453..00ed799bef 100644 --- a/kubernetes/appc/values.yaml +++ b/kubernetes/appc/values.yaml @@ -31,7 +31,7 @@ global: flavor: small # application image repository: nexus3.onap.org:10001 -image: onap/appc-image:1.5.3 +image: onap/appc-image:1.6.3 pullPolicy: Always # flag to enable debugging - application support required @@ -93,9 +93,9 @@ dgbuilder: service: name: appc-dgbuilder -#passing value to cdt chart. value of nodePort3 will be same as appc.service.nodePort3. +#passing value to cdt chart. value of nodePort4 will be same as appc.service.nodePort4. appc-cdt: - nodePort3: 11 + nodePort4: 11 # default number of instances replicaCount: 1 @@ -119,19 +119,22 @@ service: type: NodePort name: appc portName: appc - #targetPort - internalPort: 8443 - #port - externalPort: 8443 - nodePort: 30 - - externalPort2: 1830 - nodePort2: 31 + + internalPort: 8181 + externalPort: 8282 + nodePort: "08" + + internalPort2: 8443 + externalPort2: 8443 + nodePort2: 30 + + externalPort3: 1830 + nodePort3: 31 clusterPort: 2550 - internalPort3: 9191 - externalPort3: 9090 - nodePort3: 11 + internalPort4: 9191 + externalPort4: 9090 + nodePort4: 11 ## Persist data to a persitent volume persistence: |