From c175a0de2f05d37c1c774684318a525eb96bb59b Mon Sep 17 00:00:00 2001 From: Avi Ziv Date: Thu, 15 Mar 2018 13:21:44 +0200 Subject: [PATCH] Create on boarding docker Add BE and Cassandra init docker images Change-Id: Id9d767c73fc946819cec821b4634ce650cbb22fd Issue-ID: SDC-781 Signed-off-by: Michael Lando --- .gitignore | 3 + asdctool/pom.xml | 1 - .../chef-solo/roles/cassandra-actions.json | 1 - catalog-be/pom.xml | 12 - catalog-be/sdc-backend/Dockerfile | 4 - .../recipes/BE_2_setup_configuration.rb | 13 +- .../templates/default/BE-configuration.yaml.erb | 7 +- .../templates/default/ready-probe.sh.erb | 2 +- catalog-fe/pom.xml | 1 - .../sdc-catalog-fe/files/default/FE-logback.xml | 4 +- .../recipes/FE_2_setup_configuration.rb | 15 +- .../templates/default/FE-configuration.yaml.erb | 26 +- .../default/FE-onboarding-configuration.yaml.erb | 6 +- .../templates/default/ready-probe.sh.erb | 2 +- .../main/java/org/openecomp/sdc/fe/Constants.java | 17 +- .../java/org/openecomp/sdc/fe/mdc/MdcData.java | 38 ++ .../openecomp/sdc/fe/servlets/FeProxyServlet.java | 196 ++++--- .../sdc/fe/servlets/HealthCheckService.java | 8 +- .../openecomp/sdc/fe/servlets/SSLProxyServlet.java | 14 +- .../org/openecomp/sdc/fe/utils/BeProtocol.java | 14 + .../openecomp/sdc/servlets/FeProxyServletTest.java | 62 +- .../org/openecomp/sdc/fe/config/Configuration.java | 74 ++- .../openecomp/sdc/fe/config/ConfigurationTest.java | 28 - .../onboarding-rest-war/pom.xml | 2 +- openecomp-be/dist/pom.xml | 24 + .../artifacts/Dockerfile | 19 + .../sdc-onboard-backend/attributes/default.rb | 10 + .../sdc-onboard-backend/files/default/keystore | Bin 0 -> 4255 bytes .../sdc-onboard-backend/files/default/logback.xml | 328 +++++++++++ .../recipes/ON_1_cleanup_jettydir.rb | 23 + .../recipes/ON_2_locate_keystore.rb | 14 + .../sdc-onboard-backend/recipes/ON_3_logback.rb | 7 + .../recipes/ON_4_setup_jetty_modules.rb | 55 ++ .../recipes/ON_5_setup_configuration.rb | 20 + .../recipes/ON_6_prepareProbeFile.rb | 9 + .../templates/default/configuration.yaml.erb | 20 + .../templates/default/http-ini.erb | 29 + .../templates/default/https-ini.erb | 29 + .../templates/default/ready-probe.sh.erb | 11 + .../templates/default/ssl-ini.erb | 90 +++ .../artifacts/chef-solo/LICENSE | 201 +++++++ .../artifacts/chef-solo/README.md | 37 ++ .../artifacts/chef-solo/chefignore | 11 + .../artifacts/chef-solo/cookbooks/README.md | 54 ++ .../artifacts/chef-solo/data_bags/README.md | 63 ++ .../artifacts/chef-solo/environments/README.md | 5 + .../artifacts/chef-solo/roles/README.md | 16 + .../chef-solo/roles/sdc-onboard-backend.json | 23 + .../artifacts/chef-solo/solo.json | 4 + .../artifacts/chef-solo/solo.rb | 16 + .../artifacts/logback.xml | 328 +++++++++++ .../artifacts/onboarding_configuration.yaml | 16 + .../artifacts/startup.sh | 23 + .../dist/sdc-onboard-backend-docker/pom.xml | 142 +++++ .../artifacts/Dockerfile | 12 + .../artifacts/startup.sh | 24 + .../dist/sdc-onboard-db-init-docker/pom.xml | 119 ++++ .../main/resources/onboarding_configuration.yaml | 11 + openecomp-be/pom.xml | 35 +- .../tools/install/database/init_keyspaces.cql | 2 + .../tools/install/database/init_schemas.cql | 50 ++ pom.xml | 14 +- sdc-os-chef/environments/Template.json | 16 +- .../configmaps/sdc-environment-configmap.yaml | 16 +- .../sdc/templates/deployments/sdc-be.yaml | 23 +- .../sdc/templates/deployments/sdc-cs.yaml | 4 + .../sdc/templates/deployments/sdc-fe.yaml | 48 +- .../sdc/templates/deployments/sdc-onboard.yaml | 131 +++++ .../templates/jobs/sdc-onboard-cassandra-init.yaml | 86 +++ .../sdc/templates/services/all-services.yaml | 32 ++ sdc-os-chef/kubernetes/sdc/values.yaml | 2 + sdc-os-chef/pom.xml | 18 +- sdc-os-chef/scripts/docker_run.sh | 54 +- sdc-os-chef/scripts/k8s/bin_nsenter | Bin 0 -> 90162 bytes .../{etc/bash_completion.d/nsenter => etc_nsenter} | 0 sdc-os-chef/scripts/k8s/kubernetes_run.sh | 23 +- sdc-os-chef/sdc-os-common/.gitignore | 21 - sdc-os-chef/sdc-os-common/.kitchen.yml | 26 - sdc-os-chef/sdc-os-common/Berksfile | 3 - sdc-os-chef/sdc-os-common/README.md | 4 - sdc-os-chef/sdc-os-common/chefignore | 107 ---- sdc-os-chef/sdc-os-common/metadata.rb | 20 - sdc-os-chef/sdc-os-common/recipes/default.rb | 5 - sdc-os-chef/sdc-os-common/spec/spec_helper.rb | 2 - .../spec/unit/recipes/default_spec.rb | 22 - .../templates/default/BE-configuration.yaml.erb | 634 --------------------- .../test/smoke/default/default_test.rb | 18 - services/activity-spec/pom.xml | 2 +- test-apis-ci/pom.xml | 1 - .../templates/default/sdc-sanity.yaml.erb | 15 +- .../org/openecomp/sdc/ci/tests/config/Config.java | 19 + .../utils/general/OnboardingUtillViaApis.java | 2 +- .../ci/tests/utils/general/OnboardingUtils.java | 2 +- .../utils/general/VendorLicenseModelRestUtils.java | 18 +- .../general/VendorSoftwareProductRestUtils.java | 28 +- ui-ci/pom.xml | 1 - .../templates/default/sdc-sanity.yaml.erb | 14 +- utils/webseal-simulator/pom.xml | 1 - 98 files changed, 2677 insertions(+), 1185 deletions(-) create mode 100644 catalog-fe/src/main/java/org/openecomp/sdc/fe/mdc/MdcData.java create mode 100644 catalog-fe/src/main/java/org/openecomp/sdc/fe/utils/BeProtocol.java create mode 100644 openecomp-be/dist/pom.xml create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/Dockerfile create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/attributes/default.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/files/default/keystore create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/files/default/logback.xml create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_1_cleanup_jettydir.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_2_locate_keystore.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_3_logback.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_4_setup_jetty_modules.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_5_setup_configuration.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_6_prepareProbeFile.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/configuration.yaml.erb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/http-ini.erb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/https-ini.erb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ready-probe.sh.erb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ssl-ini.erb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/LICENSE create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/README.md create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/chefignore create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/cookbooks/README.md create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/data_bags/README.md create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/environments/README.md create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/README.md create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/sdc-onboard-backend.json create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.json create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.rb create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/logback.xml create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/onboarding_configuration.yaml create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/artifacts/startup.sh create mode 100644 openecomp-be/dist/sdc-onboard-backend-docker/pom.xml create mode 100644 openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/Dockerfile create mode 100644 openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/startup.sh create mode 100644 openecomp-be/dist/sdc-onboard-db-init-docker/pom.xml create mode 100644 openecomp-be/tools/install/database/init_keyspaces.cql create mode 100644 openecomp-be/tools/install/database/init_schemas.cql create mode 100644 sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-onboard.yaml create mode 100644 sdc-os-chef/kubernetes/sdc/templates/jobs/sdc-onboard-cassandra-init.yaml create mode 100755 sdc-os-chef/scripts/k8s/bin_nsenter rename sdc-os-chef/scripts/k8s/{etc/bash_completion.d/nsenter => etc_nsenter} (100%) delete mode 100644 sdc-os-chef/sdc-os-common/.gitignore delete mode 100644 sdc-os-chef/sdc-os-common/.kitchen.yml delete mode 100644 sdc-os-chef/sdc-os-common/Berksfile delete mode 100644 sdc-os-chef/sdc-os-common/README.md delete mode 100644 sdc-os-chef/sdc-os-common/chefignore delete mode 100644 sdc-os-chef/sdc-os-common/metadata.rb delete mode 100644 sdc-os-chef/sdc-os-common/recipes/default.rb delete mode 100644 sdc-os-chef/sdc-os-common/spec/spec_helper.rb delete mode 100644 sdc-os-chef/sdc-os-common/spec/unit/recipes/default_spec.rb delete mode 100644 sdc-os-chef/sdc-os-common/templates/default/BE-configuration.yaml.erb delete mode 100644 sdc-os-chef/sdc-os-common/test/smoke/default/default_test.rb diff --git a/.gitignore b/.gitignore index 6fcd3c0973..bd0f3d1e8a 100644 --- a/.gitignore +++ b/.gitignore @@ -264,3 +264,6 @@ utils/DmaapPublisher/logs/* /openecomp-ui/yarn.lock /ui-ci/sdc-ui-tests/chef-repo/cookbooks/sdc-ui-tests/files/default/Files/VNFs/* + +/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/init_keyspaces.cql +/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/init_schemas.cql diff --git a/asdctool/pom.xml b/asdctool/pom.xml index b429e61bff..b733facf80 100644 --- a/asdctool/pom.xml +++ b/asdctool/pom.xml @@ -801,7 +801,6 @@ ${project.basedir}/sdc-cassandra-init ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest diff --git a/asdctool/sdc-cassandra-init/chef-solo/roles/cassandra-actions.json b/asdctool/sdc-cassandra-init/chef-solo/roles/cassandra-actions.json index 11aba44a3f..b06e4872e3 100644 --- a/asdctool/sdc-cassandra-init/chef-solo/roles/cassandra-actions.json +++ b/asdctool/sdc-cassandra-init/chef-solo/roles/cassandra-actions.json @@ -11,7 +11,6 @@ "chef_type": "role", "run_list": [ "recipe[cassandra-actions::01-createCsUser]", - "recipe[cassandra-actions::02-createDoxKeyspace]", "recipe[cassandra-actions::03-schemaCreation]", "recipe[cassandra-actions::04-importComformance]" ], diff --git a/catalog-be/pom.xml b/catalog-be/pom.xml index 9fa78926c1..373ae996a8 100644 --- a/catalog-be/pom.xml +++ b/catalog-be/pom.xml @@ -902,16 +902,6 @@ - - catalog - - false - - - - ${project.artifactId}-${project.version} - - docker-staging @@ -1046,7 +1036,6 @@ ${project.basedir}/sdc-backend ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest @@ -1060,7 +1049,6 @@ ${project.basedir}/sdc-backend-init ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest diff --git a/catalog-be/sdc-backend/Dockerfile b/catalog-be/sdc-backend/Dockerfile index 20a4624a49..ed54c8a443 100644 --- a/catalog-be/sdc-backend/Dockerfile +++ b/catalog-be/sdc-backend/Dockerfile @@ -4,12 +4,8 @@ COPY chef-solo /root/chef-solo/ COPY chef-repo/cookbooks/. /root/chef-solo/cookbooks/ -ADD onboarding-be-*.war ${JETTY_BASE}/webapps/ - ADD catalog-be-*.war ${JETTY_BASE}/webapps/ -ADD api-docs.war ${JETTY_BASE}/webapps/ - USER root RUN chown -R jetty:jetty ${JETTY_BASE}/webapps diff --git a/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_2_setup_configuration.rb b/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_2_setup_configuration.rb index c04b11b815..3bad06f6fb 100644 --- a/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_2_setup_configuration.rb +++ b/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_2_setup_configuration.rb @@ -1,4 +1,13 @@ -replication_factor=1 +# Set the cassandra replica number +cassandra_nodes = node['Nodes']['CS'] +if cassandra_nodes.length <=2 + replication_factor=1 +elsif cassandra_nodes.length >2 && cassandra_nodes.length <=4 + replication_factor=3 +else + replication_factor=4 +end + template "titan.properties" do path "#{ENV['JETTY_BASE']}/config/catalog-be/titan.properties" @@ -30,7 +39,7 @@ template "catalog-be-config" do :catalog_port => node['BE'][:http_port], :ssl_port => node['BE'][:https_port], :cassandra_ip => node['Nodes']['CS'], - :rep_factor => 1, + :rep_factor => replication_factor, :DC_NAME => node['cassandra'][:cluster_name]+node.chef_environment, :titan_Path => "/var/lib/jetty/config/catalog-be/", :socket_connect_timeout => node['cassandra']['socket_connect_timeout'], diff --git a/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/BE-configuration.yaml.erb b/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/BE-configuration.yaml.erb index a35896afe6..a390a80441 100644 --- a/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/BE-configuration.yaml.erb +++ b/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/BE-configuration.yaml.erb @@ -553,14 +553,13 @@ heatEnvArtifactHeader: "" heatEnvArtifactFooter: "" onboarding: + host: <%= node['ONBOARDING_BE_VIP'] %> <% if node[:disableHttp] -%> protocol: https - host: <%= @catalog_ip %> - port: <%= node['BE'][:https_port] %> + port: <%= node['ONBOARDING_BE'][:https_port] %> <% else %> protocol: http - host: <%= @catalog_ip %> - port: <%= node['BE'][:http_port] %> + port: <%= node['ONBOARDING_BE'][:http_port] %> <% end -%> downloadCsarUri: "/onboarding-api/v1.0/vendor-software-products/packages" healthCheckUri: "/onboarding-api/v1.0/healthcheck" diff --git a/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/ready-probe.sh.erb b/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/ready-probe.sh.erb index 84d1c6f08f..9da843152c 100644 --- a/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/ready-probe.sh.erb +++ b/catalog-be/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/templates/default/ready-probe.sh.erb @@ -2,7 +2,7 @@ health_Check_http_code=$(curl --max-time 5 -o /dev/null -w '%{http_code}' http://127.0.0.1:8080/sdc2/rest/healthCheck) if [[ "$health_Check_http_code" -eq 200 ]]; then - exit 200 + exit 0 else exit $health_Check_http_code fi diff --git a/catalog-fe/pom.xml b/catalog-fe/pom.xml index 3b5bcab4b6..2d3e2a48bc 100644 --- a/catalog-fe/pom.xml +++ b/catalog-fe/pom.xml @@ -503,7 +503,6 @@ ${project.basedir}/sdc-frontend ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest diff --git a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/files/default/FE-logback.xml b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/files/default/FE-logback.xml index 2f793f386b..7ae4438959 100644 --- a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/files/default/FE-logback.xml +++ b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/files/default/FE-logback.xml @@ -1,8 +1,8 @@ - - + + diff --git a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb index abefd28588..2f747c308d 100644 --- a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb +++ b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb @@ -29,14 +29,9 @@ end template "onboarding-fe-config" do - path "#{ENV['JETTY_BASE']}/config/onboarding-fe/onboarding_configuration.yaml" - source "FE-onboarding-configuration.yaml.erb" - owner "jetty" - group "jetty" - mode "0755" - variables({ - :catalog_ip => node['Nodes']['BE'], - :catalog_port => node['BE'][:http_port], - :ssl_port => node['BE'][:https_port] -}) + path "#{ENV['JETTY_BASE']}/config/onboarding-fe/onboarding_configuration.yaml" + source "FE-onboarding-configuration.yaml.erb" + owner "jetty" + group "jetty" + mode "0755" end \ No newline at end of file diff --git a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-configuration.yaml.erb b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-configuration.yaml.erb index 1a245d24b5..b4368709c4 100644 --- a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-configuration.yaml.erb +++ b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-configuration.yaml.erb @@ -32,15 +32,23 @@ healthCheckSocketTimeoutInMs: 5000 healthCheckIntervalInSeconds: 5 onboarding: - host: <%= @fe_host_ip %> + hostFe: <%= @fe_host_ip %> <% if node[:disableHttp] -%> - protocol: https - port: <%= node['FE'][:https_port] %> + protocolFe: https + portFe: <%= node['FE'][:https_port] %> <% else %> - protocol: http - port: <%= node['FE'][:http_port] %> + protocolFe: http + portFe: <%= node['FE'][:http_port] %> + <% end -%> + healthCheckUriFe: "/onboarding/v1.0/healthcheck" + hostBe: <%= node['ONBOARDING_BE_VIP'] %> + <% if node[:disableHttp] -%> + protocolBe: https + portBe: <%= node['ONBOARDING_BE'][:https_port] %> + <% else %> + protocolBe: http + portBe: <%= node['ONBOARDING_BE'][:http_port] %> <% end -%> - healthCheckUri: "/onboarding/v1.0/healthcheck" dcae: host: <%= @fe_host_ip %> @@ -53,12 +61,6 @@ dcae: <% end -%> healthCheckUri: "/dcae/healthCheck" -dcae: - protocol: http - host: localhost - port: 8181 - healthCheckUri: "/dcae/healthCheck" - identificationHeaderFields: - - &HTTP_IV_USER HTTP_IV_USER diff --git a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb index 71ed876ee7..beb774b4a9 100644 --- a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb +++ b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb @@ -1,9 +1,9 @@ notifications: pollingIntervalMsec: 2000 selectionSize: 100 - beHost: <%= @catalog_ip %> + beHost: <%= node['ONBOARDING_BE_VIP'] %> <% if node[:disableHttp] -%> - beHttpPort: <%= node['BE'][:https_port] %> + beHttpPort: <%= node['ONBOARDING_BE'][:https_port] %> <% else %> - beHttpPort: <%= node['BE'][:http_port] %> + beHttpPort: <%= node['ONBOARDING_BE'][:http_port] %> <% end -%> \ No newline at end of file diff --git a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb index f721f9a694..d09880d825 100644 --- a/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb +++ b/catalog-fe/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/ready-probe.sh.erb @@ -2,7 +2,7 @@ health_Check_http_code=$(curl --max-time 5 -o /dev/null -w '%{http_code}' http://127.0.0.1:8181/sdc1/rest/healthCheck) if [[ "$health_Check_http_code" -eq 200 ]]; then - exit 200 + exit 0 else exit $health_Check_http_code fi \ No newline at end of file diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java index a64ba08d69..e42644466e 100644 --- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java +++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/Constants.java @@ -22,15 +22,14 @@ package org.openecomp.sdc.fe; public class Constants { - public static String HTTP_IV_USER = "HTTP_IV_USER"; - public static String USER_ID = "USER_ID"; - public static String ECOMP_PORTAL_COOKIE = "UserId"; - public static String HTTP_CSP_FIRSTNAME = "HTTP_CSP_FIRSTNAME"; - public static String HTTP_CSP_LASTNAME = "HTTP_CSP_LASTNAME"; - public static String HTTP_IV_REMOTE_ADDRESS = "HTTP_IV_REMOTE_ADDRESS"; - public static String HTTP_CSP_WSTYPE = "HTTP_CSP_WSTYPE"; - public static String HTTP_CSP_EMAIL = "HTTP_CSP_EMAIL"; - + public static final String HTTP_IV_USER = "HTTP_IV_USER"; + public static final String USER_ID = "USER_ID"; + public static final String ECOMP_PORTAL_COOKIE = "UserId"; + public static final String HTTP_CSP_FIRSTNAME = "HTTP_CSP_FIRSTNAME"; + public static final String HTTP_CSP_LASTNAME = "HTTP_CSP_LASTNAME"; + public static final String HTTP_IV_REMOTE_ADDRESS = "HTTP_IV_REMOTE_ADDRESS"; + public static final String HTTP_CSP_WSTYPE = "HTTP_CSP_WSTYPE"; + public static final String HTTP_CSP_EMAIL = "HTTP_CSP_EMAIL"; public static final String WEBSEAL_USER_ID_HEADER = "csp-attuid"; } diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/mdc/MdcData.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/mdc/MdcData.java new file mode 100644 index 0000000000..aa78a89eaf --- /dev/null +++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/mdc/MdcData.java @@ -0,0 +1,38 @@ +package org.openecomp.sdc.fe.mdc; + +public class MdcData { + private String serviceInstanceID; + private String userId; + private String remoteAddr; + private String localAddr; + private Long transactionStartTime; + + public MdcData(String serviceInstanceID, String userId, String remoteAddr, String localAddr, Long transactionStartTime) { + super(); + this.serviceInstanceID = serviceInstanceID; + this.userId = userId; + this.remoteAddr = remoteAddr; + this.localAddr = localAddr; + this.transactionStartTime = transactionStartTime; + } + + public Long getTransactionStartTime() { + return transactionStartTime; + } + + public String getUserId() { + return userId; + } + + public String getRemoteAddr() { + return remoteAddr; + } + + public String getLocalAddr() { + return localAddr; + } + + public String getServiceInstanceID() { + return serviceInstanceID; + } +} diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java index f9ac666933..511592afe2 100644 --- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java +++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/FeProxyServlet.java @@ -20,7 +20,6 @@ package org.openecomp.sdc.fe.servlets; -import java.net.URI; import java.util.concurrent.TimeUnit; import javax.servlet.http.HttpServletRequest; @@ -28,10 +27,11 @@ import javax.servlet.http.HttpServletResponse; import org.eclipse.jetty.client.api.Response; import org.openecomp.sdc.common.api.Constants; -import org.openecomp.sdc.common.config.EcompErrorName; import org.openecomp.sdc.fe.config.Configuration; import org.openecomp.sdc.fe.config.ConfigurationManager; import org.openecomp.sdc.fe.config.FeEcompErrorManager; +import org.openecomp.sdc.fe.mdc.MdcData; +import org.openecomp.sdc.fe.utils.BeProtocol; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.slf4j.MDC; @@ -41,12 +41,30 @@ import com.google.common.cache.CacheBuilder; public class FeProxyServlet extends SSLProxyServlet { private static final long serialVersionUID = 1L; - private static final String URL = "%s://%s:%s%s"; - private static Logger log = LoggerFactory.getLogger(FeProxyServlet.class.getName()); + private static final String URL = "%s://%s%s%s"; + private static final String ONBOARDING_CONTEXT = "/onboarding-api"; + private static final String DCAED_CONTEXT = "/dcae-api"; + private static final Logger log = LoggerFactory.getLogger(FeProxyServlet.class.getName()); private static Cache mdcDataCache = CacheBuilder.newBuilder().expireAfterWrite(10, TimeUnit.SECONDS).build(); +// @Override +// public URI rewriteURI(HttpServletRequest request) { +// try { +// logFeRequest(request); +// } catch (Exception e) { +// FeEcompErrorManager.getInstance().logFeHttpLoggingError("FE Request"); +// log.error("Unexpected FE request logging error :", e); +// } +// String originalUrl = request.getRequestURL().toString(); +// String redirectedUrl = getModifiedUrl(request); +// +// log.debug("FeProxyServlet Redirecting request from: {} , to: {}", originalUrl, redirectedUrl); +// +// return URI.create(redirectedUrl); +// } + @Override - public URI rewriteURI(HttpServletRequest request) { + protected String rewriteTarget(HttpServletRequest request) { try { logFeRequest(request); } catch (Exception e) { @@ -58,18 +76,29 @@ public class FeProxyServlet extends SSLProxyServlet { log.debug("FeProxyServlet Redirecting request from: {} , to: {}", originalUrl, redirectedUrl); - return URI.create(redirectedUrl); + return redirectedUrl; } +// @Override +// protected void onResponseSuccess(HttpServletRequest request, HttpServletResponse response, Response proxyResponse) { +// try { +// logFeResponse(request, proxyResponse); +// } catch (Exception e) { +// FeEcompErrorManager.getInstance().logFeHttpLoggingError("FE Response"); +// log.error("Unexpected FE response logging error :", e); +// } +// super.onResponseSuccess(request, response, proxyResponse); +// } +//protected void onProxyResponseSuccess(HttpServletRequest clientRequest, HttpServletResponse proxyResponse, Response serverResponse) { @Override - protected void onResponseSuccess(HttpServletRequest request, HttpServletResponse response, Response proxyResponse) { + protected void onProxyResponseSuccess(HttpServletRequest request, HttpServletResponse proxyResponse, Response response) { try { - logFeResponse(request, proxyResponse); + logFeResponse(request, response); } catch (Exception e) { FeEcompErrorManager.getInstance().logFeHttpLoggingError("FE Response"); log.error("Unexpected FE response logging error :", e); } - super.onResponseSuccess(request, response, proxyResponse); + super.onProxyResponseSuccess(request, proxyResponse, response); } private void logFeRequest(HttpServletRequest httpRequest) { @@ -135,79 +164,104 @@ public class FeProxyServlet extends SSLProxyServlet { MDC.put("timer", transactionStartTime); } - private class MdcData { - private String serviceInstanceID; - private String userId; - private String remoteAddr; - private String localAddr; - private Long transactionStartTime; - - public MdcData(String serviceInstanceID, String userId, String remoteAddr, String localAddr, Long transactionStartTime) { - super(); - this.serviceInstanceID = serviceInstanceID; - this.userId = userId; - this.remoteAddr = remoteAddr; - this.localAddr = localAddr; - this.transactionStartTime = transactionStartTime; + private String getModifiedUrl(HttpServletRequest request) { + Configuration config = getConfiguration(request); + if (config == null) { + log.error("failed to retrive configuration."); + throw new RuntimeException("failed to read FE configuration"); } - - public Long getTransactionStartTime() { - return transactionStartTime; + String uri = request.getRequestURI(); + String protocol; + String host; + String port; + if (uri.contains(ONBOARDING_CONTEXT)){ + uri = uri.replace("/sdc1/feProxy"+ONBOARDING_CONTEXT,ONBOARDING_CONTEXT); + protocol = config.getOnboarding().getProtocolBe(); + host = config.getOnboarding().getHostBe(); + port = config.getOnboarding().getPortBe().toString(); } - - public String getUserId() { - return userId; + else if(uri.contains(DCAED_CONTEXT)){ + uri = uri.replace("/sdc1/feProxy"+DCAED_CONTEXT,DCAED_CONTEXT); + protocol = config.getBeProtocol(); + host = config.getBeHost(); + if (config.getBeProtocol().equals(BeProtocol.HTTP.getProtocolName())) { + port = config.getBeHttpPort().toString(); + } else { + port = config.getBeSslPort().toString(); + } } + else{ + uri = uri.replace("/sdc1/feProxy","/sdc2"); + protocol = config.getBeProtocol(); + host = config.getBeHost(); + if (config.getBeProtocol().equals(BeProtocol.HTTP.getProtocolName())) { + port = config.getBeHttpPort().toString(); + } else { + port = config.getBeSslPort().toString(); + } - public String getRemoteAddr() { - return remoteAddr; } - public String getLocalAddr() { - return localAddr; - } + String authority = getAuthority(host, port); + String queryString = getQueryString(request); + return String.format(URL,protocol,authority,uri,queryString); + + + + +// String scheme = config.getBeProtocol(); +// String uri = request.getRequestURI().toString(); +// StringBuilder url = new StringBuilder(); +// url.append(scheme).append("://").append(config.getBeHost()); +// url.append(":"); +// if (config.getBeProtocol().equals(BeProtocol.HTTP.getProtocolName())) { +// url.append(config.getBeHttpPort()); +// } else { +// url.append(config.getBeSslPort()); +// } +// url.append(uri); +// String queryString = request.getQueryString(); // d=789 +// if (queryString != null) { +// url.append("?").append(queryString); +// } +// +// String redirectedUrl = url.toString(); +// String onboardingForwardContext = config.getOnboardingForwardContext(); +// if (onboardingForwardContext == null || onboardingForwardContext.isEmpty()) { +// onboardingForwardContext = "/onboarding-api"; +// } +// redirectedUrl = redirectedUrl.replace("/sdc1/feProxy/dcae-api", "/dcae"); +// redirectedUrl = redirectedUrl.replace("/sdc1/feProxy/onboarding-api", onboardingForwardContext); +// redirectedUrl = redirectedUrl.replace("/sdc1/feProxy", "/sdc2"); +// return redirectedUrl; - public String getServiceInstanceID() { - return serviceInstanceID; - } } - public String getModifiedUrl(HttpServletRequest request) { - Configuration config = getConfiguration(request); - if (config == null) { - log.error("failed to retrive configuration."); - } - String scheme = config.getBeProtocol(); - String uri = request.getRequestURI().toString(); - StringBuilder url = new StringBuilder(); - url.append(scheme).append("://").append(config.getBeHost()); - url.append(":"); - if (config.getBeProtocol().equals(BE_PROTOCOL.HTTP.getProtocolName())) { - url.append(config.getBeHttpPort()); - } else { - url.append(config.getBeSslPort()); - } - url.append(uri); - String queryString = request.getQueryString(); // d=789 - if (queryString != null) { - url.append("?").append(queryString); - } - - String redirectedUrl = url.toString(); - String onboardingForwardContext = config.getOnboardingForwardContext(); - if (onboardingForwardContext == null || onboardingForwardContext.isEmpty()) { - onboardingForwardContext = "/onboarding-api"; - } - redirectedUrl = redirectedUrl.replace("/sdc1/feProxy/dcae-api", "/dcae"); - redirectedUrl = redirectedUrl.replace("/sdc1/feProxy/onboarding-api", onboardingForwardContext); - redirectedUrl = redirectedUrl.replace("/sdc1/feProxy", "/sdc2"); - return redirectedUrl; + private Configuration getConfiguration(HttpServletRequest request) { + return ((ConfigurationManager) request.getSession().getServletContext().getAttribute(Constants.CONFIGURATION_MANAGER_ATTR)).getConfiguration(); } - private Configuration getConfiguration(HttpServletRequest request) { - Configuration config = ((ConfigurationManager) request.getSession().getServletContext().getAttribute(Constants.CONFIGURATION_MANAGER_ATTR)).getConfiguration(); - return config; - } + private String getAuthority(String host, String port) { + String authority; + if (port==null){ + authority=host; + } + else{ + authority=host+":"+port; + } + return authority; + } + + private String getQueryString(HttpServletRequest request) { + String queryString = request.getQueryString(); + if (queryString != null) { + queryString="?"+queryString; + } + else{ + queryString=""; + } + return queryString; + } } diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java index fce5d35d20..7f5ea06b97 100644 --- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java +++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/HealthCheckService.java @@ -295,10 +295,10 @@ public class HealthCheckService { Configuration.OnboardingConfig onboardingConfig = config.getOnboarding(); if (onboardingConfig != null) { - String protocol = onboardingConfig.getProtocol(); - String host = onboardingConfig.getHost(); - Integer port = onboardingConfig.getPort(); - String uri = onboardingConfig.getHealthCheckUri(); + String protocol = onboardingConfig.getProtocolFe(); + String host = onboardingConfig.getHostFe(); + Integer port = onboardingConfig.getPortFe(); + String uri = onboardingConfig.getHealthCheckUriFe(); return protocol + "://" + host + ":" + port + uri; } diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/SSLProxyServlet.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/SSLProxyServlet.java index c3ba279c8c..4edcfe1286 100644 --- a/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/SSLProxyServlet.java +++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/servlets/SSLProxyServlet.java @@ -33,6 +33,7 @@ import org.eclipse.jetty.util.ssl.SslContextFactory; import org.openecomp.sdc.common.api.Constants; import org.openecomp.sdc.fe.config.Configuration; import org.openecomp.sdc.fe.config.ConfigurationManager; +import org.openecomp.sdc.fe.utils.BeProtocol; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -41,18 +42,7 @@ public abstract class SSLProxyServlet extends ProxyServlet { private static final long serialVersionUID = 1L; private static Logger log = LoggerFactory.getLogger(SSLProxyServlet.class.getName()); - public enum BE_PROTOCOL { - HTTP("http"), SSL("ssl"); - private String protocolName; - public String getProtocolName() { - return protocolName; - } - - BE_PROTOCOL(String protocolName) { - this.protocolName = protocolName; - } - }; @Override public void customizeProxyRequest(Request proxyRequest, HttpServletRequest request) { @@ -77,7 +67,7 @@ public abstract class SSLProxyServlet extends ProxyServlet { protected HttpClient createHttpClient() throws ServletException { Configuration config = ((ConfigurationManager) getServletConfig().getServletContext() .getAttribute(Constants.CONFIGURATION_MANAGER_ATTR)).getConfiguration(); - boolean isSecureClient = !config.getBeProtocol().equals(BE_PROTOCOL.HTTP.getProtocolName()); + boolean isSecureClient = !config.getBeProtocol().equals(BeProtocol.HTTP.getProtocolName()); HttpClient client = (isSecureClient) ? getSecureHttpClient() : super.createHttpClient(); setTimeout(600000); client.setIdleTimeout(600000); diff --git a/catalog-fe/src/main/java/org/openecomp/sdc/fe/utils/BeProtocol.java b/catalog-fe/src/main/java/org/openecomp/sdc/fe/utils/BeProtocol.java new file mode 100644 index 0000000000..923728672e --- /dev/null +++ b/catalog-fe/src/main/java/org/openecomp/sdc/fe/utils/BeProtocol.java @@ -0,0 +1,14 @@ +package org.openecomp.sdc.fe.utils; + +public enum BeProtocol { + HTTP("http"), SSL("ssl"); + private String protocolName; + + public String getProtocolName() { + return protocolName; + } + + BeProtocol(String protocolName) { + this.protocolName = protocolName; + } + }; \ No newline at end of file diff --git a/catalog-fe/src/test/java/org/openecomp/sdc/servlets/FeProxyServletTest.java b/catalog-fe/src/test/java/org/openecomp/sdc/servlets/FeProxyServletTest.java index 4c4eb1ca2a..f3bd9a75b8 100644 --- a/catalog-fe/src/test/java/org/openecomp/sdc/servlets/FeProxyServletTest.java +++ b/catalog-fe/src/test/java/org/openecomp/sdc/servlets/FeProxyServletTest.java @@ -52,18 +52,22 @@ public class FeProxyServletTest { * http://localhost:8080/sdc1/feProxy/dummy/not/working --> * http://localhost:8090/sdc2/dummy/not/working */ - FeProxyServlet feProxy = new FeProxyServlet(); + FeProxyServletForTest feProxy = new FeProxyServletForTest(); final static HttpServletRequest servletRequest = Mockito.mock(HttpServletRequest.class); final static HttpSession httpSession = Mockito.mock(HttpSession.class); final static ServletContext servletContext = Mockito.mock(ServletContext.class); final static ConfigurationManager configurationManager = Mockito.mock(ConfigurationManager.class); final static Configuration configuration = Mockito.mock(Configuration.class); + final static Configuration.OnboardingConfig onboardingConfiguration = Mockito.mock(Configuration.OnboardingConfig.class); final static Request proxyRequest = Mockito.spy(Request.class); final static HttpFields httpFields = Mockito.mock(HttpFields.class); final static String BE_PROTOCOL = "http"; final static String BE_HOST = "172.20.43.124"; final static int BE_PORT = 8090; + final static String ONBOARDING_BE_PROTOCOL = "http"; + final static String ONBOARDING_BE_HOST = "172.20.43.125"; + final static int ONBOARDING_BE_PORT = 8091; final static String HEADER_1 = "Header1"; final static String HEADER_2 = "Header2"; final static String HEADER_3 = "Header3"; @@ -81,6 +85,10 @@ public class FeProxyServletTest { when(configuration.getBeProtocol()).thenReturn(BE_PROTOCOL); when(configuration.getBeHost()).thenReturn(BE_HOST); when(configuration.getBeHttpPort()).thenReturn(BE_PORT); + when(configuration.getOnboarding()).thenReturn(onboardingConfiguration); + when(configuration.getOnboarding().getProtocolBe()).thenReturn(ONBOARDING_BE_PROTOCOL); + when(configuration.getOnboarding().getHostBe()).thenReturn(ONBOARDING_BE_HOST); + when(configuration.getOnboarding().getPortBe()).thenReturn(ONBOARDING_BE_PORT); List strList = new ArrayList(); strList.add(HEADER_1); @@ -110,13 +118,44 @@ public class FeProxyServletTest { when(servletRequest.getContextPath()).thenReturn("/sdc1"); when(servletRequest.getServletPath()).thenReturn("/feProxy/rest/dummyBeAPI"); - URI rewriteURI = feProxy.rewriteURI(servletRequest); + String rewriteURI = feProxy.rewriteTarget(servletRequest); - assertTrue(rewriteURI.toString().equals(expectedChangedUrl)); + assertTrue(rewriteURI.equals(expectedChangedUrl)); } + @Test + public void testRewriteURIWithOnboardingAPIRequest() { + when(servletRequest.getRequestURI()).thenReturn("/sdc1/feProxy/onboarding-api/gg%20g?subtype=VF"); + String requestResourceUrl = "http://localhost:8080/sdc1/feProxy/onboarding-api/gg%20g?subtype=VF"; + String expectedChangedUrl = ONBOARDING_BE_PROTOCOL + "://" + ONBOARDING_BE_HOST + ":" + ONBOARDING_BE_PORT + "/onboarding-api/gg%20g?subtype=VF"; + when(servletRequest.getRequestURL()).thenReturn(new StringBuffer(requestResourceUrl)); + + when(servletRequest.getContextPath()).thenReturn("/sdc1"); + when(servletRequest.getServletPath()).thenReturn("/feProxy/onboarding-api/gg%20g?subtype=VF"); + + String rewriteURI = feProxy.rewriteTarget(servletRequest); + + assertTrue(rewriteURI.equals(expectedChangedUrl)); + } + + @Test public void testRewriteURIWithQureyParam_APIRequest() { + when(servletRequest.getRequestURI()).thenReturn("/sdc1/feProxy/dcae-api/gg%20g?subtype=VF"); + String requestResourceUrl = "http://localhost:8080/sdc1/feProxy/dcae-api/gg%20g?subtype=VF"; + String expectedChangedUrl = BE_PROTOCOL + "://" + BE_HOST + ":" + BE_PORT + "/dcae-api/gg%20g?subtype=VF"; + when(servletRequest.getRequestURL()).thenReturn(new StringBuffer(requestResourceUrl)); + + when(servletRequest.getContextPath()).thenReturn("/sdc1"); + when(servletRequest.getServletPath()).thenReturn("/feProxy/dcae-api/gg%20g?subtype=VF"); + + String rewriteURI = feProxy.rewriteTarget(servletRequest); + + assertTrue(rewriteURI.equals(expectedChangedUrl)); + } + + @Test + public void testRewriteTargetWithRedeirectAPIRequest() { when(servletRequest.getRequestURI()).thenReturn("/sdc1/feProxy/rest/gg%20g?subtype=VF"); String requestResourceUrl = "http://localhost:8080/sdc1/feProxy/rest/gg%20g?subtype=VF"; String expectedChangedUrl = BE_PROTOCOL + "://" + BE_HOST + ":" + BE_PORT + "/sdc2/rest/gg%20g?subtype=VF"; @@ -125,11 +164,13 @@ public class FeProxyServletTest { when(servletRequest.getContextPath()).thenReturn("/sdc1"); when(servletRequest.getServletPath()).thenReturn("/feProxy/rest/gg%20g?subtype=VF"); - URI rewriteURI = feProxy.rewriteURI(servletRequest); + String rewriteURI = feProxy.rewriteTarget(servletRequest); - assertTrue(rewriteURI.toString().equals(expectedChangedUrl)); + assertTrue(rewriteURI.equals(expectedChangedUrl)); } + + @Test public void testCustomizeProxyRequest() { feProxy.customizeProxyRequest(proxyRequest, servletRequest); @@ -137,4 +178,15 @@ public class FeProxyServletTest { verify(proxyRequest, times(1)).header(Mockito.anyString(), Mockito.anyString()); } + + /** + * class for testing only exposes the protected method. + */ + public static class FeProxyServletForTest extends FeProxyServlet{ + + @Override + public String rewriteTarget(HttpServletRequest request) { + return super.rewriteTarget(request); + } + } } diff --git a/common-app-api/src/main/java/org/openecomp/sdc/fe/config/Configuration.java b/common-app-api/src/main/java/org/openecomp/sdc/fe/config/Configuration.java index 7267bd148c..012e96afa2 100644 --- a/common-app-api/src/main/java/org/openecomp/sdc/fe/config/Configuration.java +++ b/common-app-api/src/main/java/org/openecomp/sdc/fe/config/Configuration.java @@ -258,14 +258,6 @@ public class Configuration extends BasicConfiguration { this.feFqdn = feFqdn; } - public String getOnboardingForwardContext() { - return onboardingForwardContext; - } - - public void setOnboardingForwardContext(String onboardingForwardContext) { - this.onboardingForwardContext = onboardingForwardContext; - } - public OnboardingConfig getOnboarding() { return onboarding; } @@ -330,42 +322,68 @@ public class Configuration extends BasicConfiguration { } public static class OnboardingConfig { + String protocolFe = "http"; + String hostFe; + Integer portFe; + String protocolBe = "http"; + String hostBe; + Integer portBe; + String healthCheckUriFe; + + public String getProtocolFe() { + return protocolFe; + } - String protocol = "http"; - String host; - Integer port; - String healthCheckUri; + public void setProtocolFe(String protocolFe) { + this.protocolFe = protocolFe; + } - public String getProtocol() { - return protocol; + public String getProtocolBe() { + return protocolBe; } - public void setProtocol(String protocol) { - this.protocol = protocol; + public void setProtocolBe(String protocolBe) { + this.protocolBe = protocolBe; } - public String getHost() { - return host; + public String getHostFe() { + return hostFe; } - public void setHost(String host) { - this.host = host; + public void setHostFe(String hostFe) { + this.hostFe = hostFe; } - public Integer getPort() { - return port; + public String getHostBe() { + return hostBe; } - public void setPort(Integer port) { - this.port = port; + public void setHostBe(String hostBe) { + this.hostBe = hostBe; } - public String getHealthCheckUri() { - return healthCheckUri; + public Integer getPortFe() { + return portFe; } - public void setHealthCheckUri(String healthCheckUri) { - this.healthCheckUri = healthCheckUri; + public void setPortFe(Integer portFe) { + this.portFe = portFe; + } + + public Integer getPortBe() { + return portBe; + } + + public void setPortBe(Integer portBe) { + this.portBe = portBe; + } + + public String getHealthCheckUriFe() { + return healthCheckUriFe; + } + + public void setHealthCheckUriFe(String healthCheckUriFe) { + this.healthCheckUriFe = healthCheckUriFe; } } diff --git a/common-app-api/src/test/java/org/openecomp/sdc/fe/config/ConfigurationTest.java b/common-app-api/src/test/java/org/openecomp/sdc/fe/config/ConfigurationTest.java index 6342da8222..4afafaefd4 100644 --- a/common-app-api/src/test/java/org/openecomp/sdc/fe/config/ConfigurationTest.java +++ b/common-app-api/src/test/java/org/openecomp/sdc/fe/config/ConfigurationTest.java @@ -499,35 +499,7 @@ public class ConfigurationTest { testSubject.setFeFqdn(feFqdn); } - - @Test - public void testGetOnboardingForwardContext() throws Exception { - Configuration testSubject; - String result; - - // default test - testSubject = createTestSubject(); - result = testSubject.getOnboardingForwardContext(); - } - - - @Test - public void testSetOnboardingForwardContext() throws Exception { - Configuration testSubject; - String onboardingForwardContext = ""; - // default test - testSubject = createTestSubject(); - testSubject.setOnboardingForwardContext(onboardingForwardContext); - } - - - - - - - - @Test public void testToString() throws Exception { Configuration testSubject; diff --git a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml index 39ed3aef06..c8b238389a 100644 --- a/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml +++ b/openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/pom.xml @@ -223,7 +223,7 @@ - {"Version": "${version}"} + {"Version": "${project.version}"} diff --git a/openecomp-be/dist/pom.xml b/openecomp-be/dist/pom.xml new file mode 100644 index 0000000000..2600dd6878 --- /dev/null +++ b/openecomp-be/dist/pom.xml @@ -0,0 +1,24 @@ + + 4.0.0 + + openecomp-sdc-docker-dist + org.openecomp.sdc + openecomp-sdc-docker-dist + pom + + http://maven.apache.org + + + org.openecomp.sdc + openecomp-sdc + 1.2.0-SNAPSHOT + .. + + + + /sdc-onboard-backend-docker + /sdc-onboard-db-init-docker + + + \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/Dockerfile b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/Dockerfile new file mode 100644 index 0000000000..a3e56fde23 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/Dockerfile @@ -0,0 +1,19 @@ +FROM onap/base_sdc-jetty:1.3.0-SNAPSHOT-latest + +COPY chef-solo /root/chef-solo/ + +COPY chef-repo/cookbooks /root/chef-solo/cookbooks/ + +ADD onboarding-be-*.war ${JETTY_BASE}/webapps/ + +ADD api-docs.war ${JETTY_BASE}/webapps/ + +USER root + +RUN chown -R jetty:jetty ${JETTY_BASE}/webapps + +COPY startup.sh /root/ + +RUN chmod 770 /root/startup.sh + +ENTRYPOINT [ "/root/startup.sh" ] diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/attributes/default.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/attributes/default.rb new file mode 100644 index 0000000000..47c3e2991a --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/attributes/default.rb @@ -0,0 +1,10 @@ +# +default['ONBOARDING_BE'][:http_port] = 8081 +default['ONBOARDING_BE'][:https_port] = 8445 +default['FE'][:http_port] = 8181 +default['FE'][:https_port] = 9443 +default['disableHttp'] = true +default['cassandra'][:truststore_password] = "Aa123456" +default['jetty'][:keystore_pwd] = "OBF:1cp61iuj194s194u194w194y1is31cok" +default['jetty'][:keymanager_pwd] = "OBF:1cp61iuj194s194u194w194y1is31cok" +default['jetty'][:truststore_pwd] = "OBF:1cp61iuj194s194u194w194y1is31cok" diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/files/default/keystore b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/files/default/keystore new file mode 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U!d;a>BzhaBb)`#58Sd=%+v1_`}S)8|rG{VxzCF*~sjhKwjOb4X7 z74mQ+;x}G9$Vg)H3%8XFxaAIO|K_+Z + + + + + + + + + + + + + + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/all.log + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/all.log.%i + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/error.log + + + + + + AUDIT_MARKER + + NEUTRAL + DENY + + + + + + TRANSACTION_MARKER + + NEUTRAL + DENY + + + + + INFO + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/error.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug.log + + + + + + + TRANSACTION_MARKER + + NEUTRAL + DENY + + + + + + + e.level.toInt() <= DEBUG.toInt() + + + DENY + + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug_by_package.log + + + + + + + TRANSACTION_MARKER + + NEUTRAL + DENY + + + + + + + e.level.toInt() <= DEBUG.toInt() + + + DENY + NEUTRAL + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug_by_package.log.%i + + 1 + 10 + + + + 20MB + + + ${asdc-debug-log-pattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/audit.log + + + + + + AUDIT_MARKER + AUDIT + + DENY + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/audit.log.%i + + 1 + 10 + + + + 20MB + + + ${auditLoggerPattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/metrics.log + + + + + + METRICS + + DENY + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/metrics.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/transaction.log + + + + + + TRANSACTION_MARKER + + DENY + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/transaction.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_1_cleanup_jettydir.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_1_cleanup_jettydir.rb new file mode 100644 index 0000000000..2c703f2039 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_1_cleanup_jettydir.rb @@ -0,0 +1,23 @@ +directory "tempdir_creation" do + path "#{ENV['JETTY_BASE']}/temp" + owner 'jetty' + group 'jetty' + mode '0755' + action :create +end + +directory "create_config_dir" do + path "#{ENV['JETTY_BASE']}/config" + owner 'jetty' + group 'jetty' + mode '0755' + action :create +end + +directory "onboarding-be" do + path "#{ENV['JETTY_BASE']}/config/onboarding-be" + owner 'jetty' + group 'jetty' + mode '0755' + action :create +end diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_2_locate_keystore.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_2_locate_keystore.rb new file mode 100644 index 0000000000..e838543e7d --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_2_locate_keystore.rb @@ -0,0 +1,14 @@ +directory "Jetty_etcdir_creation" do + path "#{ENV['JETTY_BASE']}/etc" + owner 'jetty' + group 'jetty' + mode '0755' + action :create +end + +cookbook_file "#{ENV['JETTY_BASE']}/etc/keystore" do + source "keystore" + owner "jetty" + group "jetty" + mode 0755 +end diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_3_logback.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_3_logback.rb new file mode 100644 index 0000000000..823c3cd44e --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_3_logback.rb @@ -0,0 +1,7 @@ +cookbook_file "#{ENV['JETTY_BASE']}/config/onboarding-be/logback.xml" do + source "logback.xml" + mode 0755 + owner "jetty" + group "jetty" +end + diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_4_setup_jetty_modules.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_4_setup_jetty_modules.rb new file mode 100644 index 0000000000..82a066589b --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_4_setup_jetty_modules.rb @@ -0,0 +1,55 @@ +#Set the http module option +if node['disableHttp'] + http_option = "#--module=http" +else + http_option = "--module=http" +end + + +bash "create-jetty-modules" do +cwd "#{ENV['JETTY_BASE']}" +code <<-EOH + cd "#{ENV['JETTY_BASE']}" + java -jar "#{ENV['JETTY_HOME']}"/start.jar --add-to-start=deploy + java -jar "#{ENV['JETTY_HOME']}"/start.jar --add-to-startd=http,https,logging,setuid +EOH +end + + +template "http-ini" do + path "#{ENV['JETTY_BASE']}/start.d/http.ini" + source "http-ini.erb" + owner "jetty" + group "jetty" + mode "0755" + variables ({ + :http_option => http_option , + :http_port => "#{node['ONBOARDING_BE'][:http_port]}" + }) + +end + + +template "https-ini" do + path "#{ENV['JETTY_BASE']}/start.d/https.ini" + source "https-ini.erb" + owner "jetty" + group "jetty" + mode "0755" + variables :https_port => "#{node['ONBOARDING_BE'][:https_port]}" +end + + +template "ssl-ini" do + path "#{ENV['JETTY_BASE']}/start.d/ssl.ini" + source "ssl-ini.erb" + owner "jetty" + group "jetty" + mode "0755" + variables ({ + :https_port => "#{node['ONBOARDING_BE'][:https_port]}" , + :jetty_keystore_pwd => "#{node['jetty'][:keystore_pwd]}" , + :jetty_keymanager_pwd => "#{node['jetty'][:keymanager_pwd]}" , + :jetty_truststore_pwd => "#{node['jetty'][:truststore_pwd]}" + }) +end diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_5_setup_configuration.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_5_setup_configuration.rb new file mode 100644 index 0000000000..90e0802a94 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_5_setup_configuration.rb @@ -0,0 +1,20 @@ +template "onboard-be-config" do + path "#{ENV['JETTY_BASE']}/config/onboarding-be/onboarding_configuration.yaml" + source "configuration.yaml.erb" + owner "jetty" + group "jetty" + mode "0755" + variables({ + :onboard_ip => node['ONBOARDING_BE_VIP'], + :onboard_port => node['ONBOARDING_BE'][:http_port], + :ssl_port => node['ONBOARDING_BE'][:https_port], + :cassandra_ip => node['Nodes']['CS'], + :DC_NAME => node['cassandra'][:cluster_name]+node.chef_environment, + :socket_connect_timeout => node['cassandra']['socket_connect_timeout'], + :socket_read_timeout => node['cassandra']['socket_read_timeout'], + :cassandra_pwd => node['cassandra'][:cassandra_password], + :cassandra_usr => node['cassandra'][:cassandra_user], + :cassandra_truststore_password => node['cassandra'][:truststore_password], + :cassandra_ssl_enabled => "#{ENV['cassandra_ssl_enabled']}" + }) +end \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_6_prepareProbeFile.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_6_prepareProbeFile.rb new file mode 100644 index 0000000000..edc8f9eebf --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/recipes/ON_6_prepareProbeFile.rb @@ -0,0 +1,9 @@ +template "/var/lib/ready-probe.sh" do + source "ready-probe.sh.erb" + sensitive true + mode 0755 + variables({ + :onboard_port => "#{node['ONBOARDING_BE'][:http_port]}", + :ssl_port => "#{node['ONBOARDING_BE'][:https_port]}" + }) +end diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/configuration.yaml.erb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/configuration.yaml.erb new file mode 100644 index 0000000000..df1c7b516e --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/configuration.yaml.erb @@ -0,0 +1,20 @@ +notifications: + pollingIntervalMsec: 2000 + selectionSize: 100 + beHost: <%= @onboard_ip %> + beHttpPort: <%= @onboard_port %> + +cassandraConfig: + cassandraHosts: [<%= @cassandra_ip %>] + localDataCenter: <%= @DC_NAME %> + reconnectTimeout : 30000 + socketReadTimeout: <%= @socket_read_timeout %> + socketConnectTimeout: <%= @socket_connect_timeout %> + authenticate: true + username: <%= @cassandra_usr %> + password: <%= @cassandra_pwd %> + ssl: <%= @cassandra_ssl_enabled %> + truststorePath: /config/truststore + truststorePassword: <%= @cassandra_truststore_password %> + + diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/http-ini.erb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/http-ini.erb new file mode 100644 index 0000000000..8f2669032b --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/http-ini.erb @@ -0,0 +1,29 @@ +# --------------------------------------- +# Module: http +<%= @http_option %> + +### HTTP Connector Configuration + +## Connector host/address to bind to +# jetty.http.host=0.0.0.0 + +## Connector port to listen on +jetty.http.port=<%= @http_port %> + +## Connector idle timeout in milliseconds +jetty.http.idleTimeout=30000 + +## Connector socket linger time in seconds (-1 to disable) +# jetty.http.soLingerTime=-1 + +## Number of acceptors (-1 picks default based on number of cores) +# jetty.http.acceptors=-1 + +## Number of selectors (-1 picks default based on number of cores) +# jetty.http.selectors=-1 + +## ServerSocketChannel backlog (0 picks platform default) +# jetty.http.acceptorQueueSize=0 + +## Thread priority delta to give to acceptor threads +# jetty.http.acceptorPriorityDelta=0 diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/https-ini.erb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/https-ini.erb new file mode 100644 index 0000000000..9999a4109b --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/https-ini.erb @@ -0,0 +1,29 @@ +# --------------------------------------- +# Module: https +--module=https + +### HTTPS Connector Configuration + +## Connector host/address to bind to +# jetty.https.host=0.0.0.0 + +## Connector port to listen on +jetty.https.port=<%= @https_port %> + +## Connector idle timeout in milliseconds +jetty.https.idleTimeout=30000 + +## Connector socket linger time in seconds (-1 to disable) +# jetty.https.soLingerTime=-1 + +## Number of acceptors (-1 picks default based on number of cores) +# jetty.https.acceptors=-1 + +## Number of selectors (-1 picks default based on number of cores) +# jetty.https.selectors=-1 + +## ServerSocketChannel backlog (0 picks platform default) +# jetty.https.acceptorQueueSize=0 + +## Thread priority delta to give to acceptor threads +# jetty.https.acceptorPriorityDelta=0 diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ready-probe.sh.erb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ready-probe.sh.erb new file mode 100644 index 0000000000..4e58227241 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ready-probe.sh.erb @@ -0,0 +1,11 @@ +#!/bin/bash +<% if node[:disableHttp] -%> +health_Check_http_code=$(curl --max-time 5 -o /dev/null -w '%{http_code}' -X GET --header "USER_ID: cs0008" --header "Accept: application/json" "http://127.0.0.1:<%= @ssl_port %>/onboarding-api/v1.0/healthcheck") +<% else %> +health_Check_http_code=$(curl --max-time 5 -o /dev/null -w '%{http_code}' -X GET --header "USER_ID: cs0008" --header "Accept: application/json" "http://127.0.0.1:<%= @onboard_port %>/onboarding-api/v1.0/healthcheck") +<% end -%> +if [[ "$health_Check_http_code" -eq 200 ]]; then + exit 0 +else + exit $health_Check_http_code +fi diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ssl-ini.erb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ssl-ini.erb new file mode 100644 index 0000000000..1f1ff5d394 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-repo/cookbooks/sdc-onboard-backend/templates/default/ssl-ini.erb @@ -0,0 +1,90 @@ +# --------------------------------------- +# Module: ssl +--module=ssl + +### TLS(SSL) Connector Configuration + +## Connector host/address to bind to +# jetty.ssl.host=0.0.0.0 + +## Connector port to listen on +jetty.ssl.port=<%= @https_port %> + +## Connector idle timeout in milliseconds +# jetty.ssl.idleTimeout=30000 + +## Connector socket linger time in seconds (-1 to disable) +# jetty.ssl.soLingerTime=-1 + +## Number of acceptors (-1 picks default based on number of cores) +# jetty.ssl.acceptors=-1 + +## Number of selectors (-1 picks default based on number of cores) +# jetty.ssl.selectors=-1 + +## ServerSocketChannel backlog (0 picks platform default) +# jetty.ssl.acceptorQueueSize=0 + +## Thread priority delta to give to acceptor threads +# jetty.ssl.acceptorPriorityDelta=0 + +## Whether request host names are checked to match any SNI names +# jetty.ssl.sniHostCheck=true + +## max age in seconds for a Strict-Transport-Security response header (default -1) +# jetty.ssl.stsMaxAgeSeconds=31536000 + +## include subdomain property in any Strict-Transport-Security header (default false) +# jetty.ssl.stsIncludeSubdomains=true + +### SslContextFactory Configuration +## Note that OBF passwords are not secure, just protected from casual observation +## See http://www.eclipse.org/jetty/documentation/current/configuring-security-secure-passwords.html + +## Keystore file path (relative to $jetty.base) +# jetty.sslContext.keyStorePath=etc/keystore + +## Truststore file path (relative to $jetty.base) +#jetty.sslContext.trustStorePath=etc/truststore + +## Keystore password +# jetty.sslContext.keyStorePassword=OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4 +jetty.sslContext.keyStorePassword=<%= @jetty_keystore_pwd %> + +## Keystore type and provider +# jetty.sslContext.keyStoreType=JKS +# jetty.sslContext.keyStoreProvider= + +## KeyManager password +# jetty.sslContext.keyManagerPassword=OBF:1u2u1wml1z7s1z7a1wnl1u2g +jetty.sslContext.keyManagerPassword=<%= @jetty_keymanager_pwd %> + +## Truststore password +# jetty.sslContext.trustStorePassword=OBF:1vny1zlo1x8e1vnw1vn61x8g1zlu1vn4 +jetty.sslContext.trustStorePassword=<%= @jetty_truststore_pwd %> + +## Truststore type and provider +# jetty.sslContext.trustStoreType=JKS +# jetty.sslContext.trustStoreProvider= + +## whether client certificate authentication is required +# jetty.sslContext.needClientAuth=false + +## Whether client certificate authentication is desired +# jetty.sslContext.wantClientAuth=false + +## Whether cipher order is significant (since java 8 only) +# jetty.sslContext.useCipherSuitesOrder=true + +## To configure Includes / Excludes for Cipher Suites or Protocols see tweak-ssl.xml example at +## https://www.eclipse.org/jetty/documentation/current/configuring-ssl.html#configuring-sslcontextfactory-cipherSuites + +## Set the size of the SslSession cache +# jetty.sslContext.sslSessionCacheSize=-1 + +## Set the timeout (in seconds) of the SslSession cache timeout +# jetty.sslContext.sslSessionTimeout=-1 + +## Allow SSL renegotiation +# jetty.sslContext.renegotiationAllowed=true +# jetty.sslContext.renegotiationLimit=5 diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/LICENSE b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/LICENSE new file mode 100644 index 0000000000..11069edd79 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + +TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + +1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + +2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + +3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + +4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + +5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + +6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + +7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + +8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + +9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + +END OF TERMS AND CONDITIONS + +APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + +Copyright [yyyy] [name of copyright owner] + +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. diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/README.md b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/README.md new file mode 100644 index 0000000000..ddb0fda830 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/README.md @@ -0,0 +1,37 @@ +Deprecated +========== + +Use of this repository is deprecated. We recommend using the `chef generate repo` command that comes with [ChefDK](http://downloads.chef.io/chef-dk/). + +Overview +======== + +Every Chef installation needs a Chef Repository. This is the place where cookbooks, roles, config files and other artifacts for managing systems with Chef will live. We strongly recommend storing this repository in a version control system such as Git and treat it like source code. + +While we prefer Git, and make this repository available via GitHub, you are welcome to download a tar or zip archive and use your favorite version control system to manage the code. + +Repository Directories +====================== + +This repository contains several directories, and each directory contains a README file that describes what it is for in greater detail, and how to use it for managing your systems with Chef. + +* `cookbooks/` - Cookbooks you download or create. +* `data_bags/` - Store data bags and items in .json in the repository. +* `roles/` - Store roles in .rb or .json in the repository. +* `environments/` - Store environments in .rb or .json in the repository. + +Configuration +============= + +The repository contains a knife configuration file. + +* .chef/knife.rb + +The knife configuration file `.chef/knife.rb` is a repository specific configuration file for knife. If you're using Hosted Chef, you can download one for your organization from the management console. If you're using the Open Source Chef Server, you can generate a new one with `knife configure`. For more information about configuring Knife, see the Knife documentation. + +https://docs.chef.io/knife.html + +Next Steps +========== + +Read the README file in each of the subdirectories for more information about what goes in those directories. diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/chefignore b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/chefignore new file mode 100644 index 0000000000..ba30af6cff --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/chefignore @@ -0,0 +1,11 @@ +# Put files/directories that should be ignored in this file. +# Lines that start with '# ' are comments. + +# emacs +*~ + +# vim +*.sw[a-z] + +# subversion +*/.svn/* diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/cookbooks/README.md b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/cookbooks/README.md new file mode 100644 index 0000000000..86ea46bfbb --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/cookbooks/README.md @@ -0,0 +1,54 @@ +This directory contains the cookbooks used to configure systems in your infrastructure with Chef. + +Knife needs to be configured to know where the cookbooks are located with the `cookbook_path` setting. If this is not set, then several cookbook operations will fail to work properly. + + cookbook_path ["./cookbooks"] + +This setting tells knife to look for the cookbooks directory in the present working directory. This means the knife cookbook subcommands need to be run in the `chef-repo` directory itself. To make sure that the cookbooks can be found elsewhere inside the repository, use an absolute path. This is a Ruby file, so something like the following can be used: + + current_dir = File.dirname(__FILE__) + cookbook_path ["#{current_dir}/../cookbooks"] + +Which will set `current_dir` to the location of the knife.rb file itself (e.g. `~/chef-repo/.chef/knife.rb`). + +Configure knife to use your preferred copyright holder, email contact and license. Add the following lines to `.chef/knife.rb`. + + cookbook_copyright "Example, Com." + cookbook_email "cookbooks@example.com" + cookbook_license "apachev2" + +Supported values for `cookbook_license` are "apachev2", "mit","gplv2","gplv3", or "none". These settings are used to prefill comments in the default recipe, and the corresponding values in the metadata.rb. You are free to change the the comments in those files. + +Create new cookbooks in this directory with Knife. + + knife cookbook create COOKBOOK + +This will create all the cookbook directory components. You don't need to use them all, and can delete the ones you don't need. It also creates a README file, metadata.rb and default recipe. + +You can also download cookbooks directly from the Opscode Cookbook Site. There are two subcommands to help with this depending on what your preference is. + +The first and recommended method is to use a vendor branch if you're using Git. This is automatically handled with Knife. + + knife cookbook site install COOKBOOK + +This will: + +* Download the cookbook tarball from cookbooks.opscode.com. +* Ensure its on the git master branch. +* Checks for an existing vendor branch, and creates if it doesn't. +* Checks out the vendor branch (chef-vendor-COOKBOOK). +* Removes the existing (old) version. +* Untars the cookbook tarball it downloaded in the first step. +* Adds the cookbook files to the git index and commits. +* Creates a tag for the version downloaded. +* Checks out the master branch again. +* Merges the cookbook into master. +* Repeats the above for all the cookbooks dependencies, downloading them from the community site + +The last step will ensure that any local changes or modifications you have made to the cookbook are preserved, so you can keep your changes through upstream updates. + +If you're not using Git, use the site download subcommand to download the tarball. + + knife cookbook site download COOKBOOK + +This creates the COOKBOOK.tar.gz from in the current directory (e.g., `~/chef-repo`). We recommend following a workflow similar to the above for your version control tool. diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/data_bags/README.md b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/data_bags/README.md new file mode 100644 index 0000000000..0c15a391fa --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/data_bags/README.md @@ -0,0 +1,63 @@ +Data Bags +--------- + +This directory contains directories of the various data bags you create for your infrastructure. Each subdirectory corresponds to a data bag on the Chef Server, and contains JSON files of the items that go in the bag. + +First, create a directory for the data bag. + + mkdir data_bags/BAG + +Then create the JSON files for items that will go into that bag. + + $EDITOR data_bags/BAG/ITEM.json + +The JSON for the ITEM must contain a key named "id" with a value equal to "ITEM". For example, + + { + "id": "foo" + } + +Next, create the data bag on the Chef Server. + + knife data bag create BAG + +Then upload the items in the data bag's directory to the Chef Server. + + knife data bag from file BAG ITEM.json + + +Encrypted Data Bags +------------------- + +Added in Chef 0.10, encrypted data bags allow you to encrypt the contents of your data bags. The content of attributes will no longer be searchable. To use encrypted data bags, first you must have or create a secret key. + + openssl rand -base64 512 > secret_key + +You may use this secret_key to add items to a data bag during a create. + + knife data bag create --secret-file secret_key passwords mysql + +You may also use it when adding ITEMs from files, + + knife data bag create passwords + knife data bag from file passwords data_bags/passwords/mysql.json --secret-file secret_key + +The JSON for the ITEM must contain a key named "id" with a value equal to "ITEM" and the contents will be encrypted when uploaded. For example, + + { + "id": "mysql", + "password": "abc123" + } + +Without the secret_key, the contents are encrypted. + + knife data bag show passwords mysql + id: mysql + password: 2I0XUUve1TXEojEyeGsjhw== + +Use the secret_key to view the contents. + + knife data bag show passwords mysql --secret-file secret_key + id: mysql + password: abc123 + diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/environments/README.md b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/environments/README.md new file mode 100644 index 0000000000..50ac48db2b --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/environments/README.md @@ -0,0 +1,5 @@ +Requires Chef 0.10.0+. + +This directory is for Ruby DSL and JSON files for environments. For more information see the Chef wiki page: + +http://docs.chef.io/environments.html diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/README.md b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/README.md new file mode 100644 index 0000000000..b0ee0b4d21 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/README.md @@ -0,0 +1,16 @@ +Create roles here, in either the Role Ruby DSL (.rb) or JSON (.json) files. To install roles on the server, use knife. + +For example, create `roles/base_example.rb`: + + name "base_example" + description "Example base role applied to all nodes." + # List of recipes and roles to apply. Requires Chef 0.8, earlier versions use 'recipes()'. + #run_list() + # Attributes applied if the node doesn't have it set already. + #default_attributes() + # Attributes applied no matter what the node has set already. + #override_attributes() + +Then upload it to the Chef Server: + + knife role from file roles/base_example.rb diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/sdc-onboard-backend.json b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/sdc-onboard-backend.json new file mode 100644 index 0000000000..53915ff355 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/roles/sdc-onboard-backend.json @@ -0,0 +1,23 @@ +{ + "name": "sdc-onboard-backend", + "description": "Installation application - SDC_Onboard_Backend", + "json_class": "Chef::Role", + "default_attributes": { + + }, + "override_attributes": { + + }, + "chef_type": "role", + "run_list": [ + "recipe[sdc-onboard-backend::ON_1_cleanup_jettydir]", + "recipe[sdc-onboard-backend::ON_2_locate_keystore]", + "recipe[sdc-onboard-backend::ON_3_logback]", + "recipe[sdc-onboard-backend::ON_4_setup_jetty_modules]", + "recipe[sdc-onboard-backend::ON_5_setup_configuration]", + "recipe[sdc-onboard-backend::ON_6_prepareProbeFile]" + ], + "env_run_lists": { + } +} + diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.json b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.json new file mode 100644 index 0000000000..0b032da81e --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.json @@ -0,0 +1,4 @@ +{ + "run_list": [ "role[sdc-onboard-backend]" ] +} + diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.rb b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.rb new file mode 100644 index 0000000000..06c1af4592 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/chef-solo/solo.rb @@ -0,0 +1,16 @@ +root = File.absolute_path(File.dirname(__FILE__)) +file_cache_path root +cookbook_path root + '/cookbooks' +json_attribs root + '/solo.json' +checksum_path root + '/checksums' +data_bag_path root + '/data_bags' +environment_path root + '/environments' +file_backup_path root + '/backup' +file_cache_path root + '/cache' +log_level :info +log_location STDOUT +rest_timeout 300 +role_path root + '/roles' +syntax_check_cache_path +umask 0022 +verbose_logging nil diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/logback.xml b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/logback.xml new file mode 100644 index 0000000000..0865b1b8c7 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/logback.xml @@ -0,0 +1,328 @@ + + + + + + + + + + + + + + + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/all.log + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/all.log.%i + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/error.log + + + + + + AUDIT_MARKER + + NEUTRAL + DENY + + + + + + TRANSACTION_MARKER + + NEUTRAL + DENY + + + + + INFO + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/error.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug.log + + + + + + + TRANSACTION_MARKER + + NEUTRAL + DENY + + + + + + + e.level.toInt() <= DEBUG.toInt() + + + DENY + + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug_by_package.log + + + + + + + TRANSACTION_MARKER + + NEUTRAL + DENY + + + + + + + e.level.toInt() <= DEBUG.toInt() + + + DENY + NEUTRAL + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/debug_by_package.log.%i + + 1 + 10 + + + + 20MB + + + ${asdc-debug-log-pattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/audit.log + + + + + + AUDIT_MARKER + AUDIT + + DENY + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/audit.log.%i + + 1 + 10 + + + + 20MB + + + ${auditLoggerPattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/metrics.log + + + + + + METRICS + + DENY + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/metrics.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/transaction.log + + + + + + TRANSACTION_MARKER + + DENY + ACCEPT + + + + ${log.home}/${ECOMP-component-name}/${ECOMP-subcomponent-name}/transaction.log.%i + + 1 + 10 + + + + 20MB + + + ${default-log-pattern} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/onboarding_configuration.yaml b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/onboarding_configuration.yaml new file mode 100644 index 0000000000..d662b75f2d --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/onboarding_configuration.yaml @@ -0,0 +1,16 @@ +notifications: + pollingIntervalMsec: 2000 + selectionSize: 10 + beHost: localhost + beHttpPort: 8080 + +cassandraConfig: + cassandraHosts: ['localhost'] + localDataCenter: CLUSTER_NAME + reconnectTimeout : 30000 + authenticate: true + username: CS_USER + password: CS_PASS + ssl: false + truststorePath : /config/.truststore + truststorePassword : Aa123456 diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/startup.sh b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/startup.sh new file mode 100644 index 0000000000..1517f72202 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/artifacts/startup.sh @@ -0,0 +1,23 @@ +#!/bin/sh + + +cd /root/chef-solo +chef-solo -c solo.rb -E ${ENVNAME} +rc=$? +if [[ $rc != 0 ]]; then + echo "Chef exaction failed." + exit $rc; +fi + + +JAVA_OPTIONS=" ${JAVA_OPTIONS} \ + -Dconfig.home=${JETTY_BASE}/config \ + -Dlog.home=${JETTY_BASE}/logs \ + -Dlogback.configurationFile=${JETTY_BASE}/config/onboarding-be/logback.xml \ + -Dconfiguration.yaml=${JETTY_BASE}/config/onboarding-be/onboarding_configuration.yaml" + +cd /var/lib/jetty + +/docker-entrypoint.sh & + +while true; do sleep 2; done \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-backend-docker/pom.xml b/openecomp-be/dist/sdc-onboard-backend-docker/pom.xml new file mode 100644 index 0000000000..027ea019eb --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-backend-docker/pom.xml @@ -0,0 +1,142 @@ + + 4.0.0 + + openecomp-sdc-docker-backend + org.openecomp.sdc + openecomp-sdc-docker-backend + pom + + http://maven.apache.org + + + org.openecomp.sdc + openecomp-sdc-docker-dist + 1.2.0-SNAPSHOT + .. + + + + + sdc-onboard-backend + + + + + maven-resources-plugin + 3.0.2 + + + copy-resources-war + verify + + copy-resources + + + ${project.basedir}/artifacts + + + + ${project.parent.basedir}/../../openecomp-be/tools/swagger-ui/api-docs + + + api-docs.war + + + + + ${project.parent.basedir}/../../openecomp-be/api/openecomp-sdc-rest-webapp/onboarding-rest-war/target + + + onboarding-be-${project.version}.war + + + + + ${project.parent.basedir}/../../openecomp-be/lib/openecomp-sdc-notification-lib/openecomp-sdc-notification-worker/src/main/resources + + + onboarding_configuration.yaml + + + + + ${project.parent.basedir}/../../catalog-be/src/main/resources/config + + + logback.xml + + + + + + + + + io.fabric8 + docker-maven-plugin + ${fabric8.version} + + + true + 1.23 + nexus3.onap.org:10001 + + + docker + docker + + + + + + + onap/${docker.image.name} + ${docker.image.name} + + try + ${project.basedir}/artifacts + + ${docker.tag} + ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest + + + + + + + + clean-images + pre-clean + + remove + + + true + onap/${docker.image.name} + + + + + generate-images + install + + build + + + + + push-images + deploy + + push + + + onap/${docker.image.name} + + + + + + + \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/Dockerfile b/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/Dockerfile new file mode 100644 index 0000000000..597c5d281b --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/Dockerfile @@ -0,0 +1,12 @@ +FROM onap/base_sdc-cqlsh:1.2.0-SNAPSHOT-latest + +COPY init_keyspaces.cql /root/ + +COPY init_schemas.cql /root/ + +COPY startup.sh /root/ + +RUN chmod 770 /root/startup.sh + +ENTRYPOINT [ "/root/startup.sh" ] + diff --git a/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/startup.sh b/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/startup.sh new file mode 100644 index 0000000000..9e2c489cb0 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-db-init-docker/artifacts/startup.sh @@ -0,0 +1,24 @@ +#!/bin/bash + +cd /root + +CS_PORT="" +CS_HOST=127.0.0.1 + +if [ ! -z "${CS_HOST_IP}" ]; then + CS_HOST=$CS_HOST_IP +fi + +if [ ! -z "${CS_HOST_PORT}" ]; then + CS_PORT=$CS_HOST_PORT +fi + +echo "[Info] Going to initialize sdc onboard cassandra: user=$SDC_USER; host=$CS_HOST; port=$CS_PORT" +echo "[Info] Initializing onboard keyspaces" +cqlsh -u $SDC_USER -p $SDC_PASSWORD -f init_keyspaces.cql $CS_HOST $CS_PORT + +echo "[Info] Initializing onboard schemas" +cqlsh -u $SDC_USER -p $SDC_PASSWORD -f init_schemas.cql $CS_HOST $CS_PORT + +rc=$? +if [[ $rc != 0 ]]; then exit $rc; fi \ No newline at end of file diff --git a/openecomp-be/dist/sdc-onboard-db-init-docker/pom.xml b/openecomp-be/dist/sdc-onboard-db-init-docker/pom.xml new file mode 100644 index 0000000000..6ec49f9f10 --- /dev/null +++ b/openecomp-be/dist/sdc-onboard-db-init-docker/pom.xml @@ -0,0 +1,119 @@ + + 4.0.0 + + openecomp-sdc-docker-db-init + org.openecomp.sdc + openecomp-sdc-docker-db-init + pom + + http://maven.apache.org + + + org.openecomp.sdc + openecomp-sdc-docker-dist + 1.2.0-SNAPSHOT + .. + + + + + sdc-onboard-cassandra-init + + + + + maven-resources-plugin + 3.0.2 + + + copy-resources-war + verify + + copy-resources + + + ${project.basedir}/artifacts + + + + ${project.parent.basedir}/../../openecomp-be/tools/install/database + + + init_keyspaces.cql + init_schemas.cql + + + + + + + + + io.fabric8 + docker-maven-plugin + ${fabric8.version} + + + true + 1.23 + nexus3.onap.org:10001 + + + docker + docker + + + + + + + onap/${docker.image.name} + ${docker.image.name} + + try + ${project.basedir}/artifacts + + ${docker.tag} + ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest + + + + + + + + clean-images + pre-clean + + remove + + + true + onap/${docker.image.name} + + + + + generate-images + install + + build + + + + + push-images + deploy + + push + + + onap/${docker.image.name} + + + + + + + \ No newline at end of file diff --git a/openecomp-be/lib/openecomp-sdc-notification-lib/openecomp-sdc-notification-worker/src/main/resources/onboarding_configuration.yaml b/openecomp-be/lib/openecomp-sdc-notification-lib/openecomp-sdc-notification-worker/src/main/resources/onboarding_configuration.yaml index a1b7ba5d9e..d662b75f2d 100644 --- a/openecomp-be/lib/openecomp-sdc-notification-lib/openecomp-sdc-notification-worker/src/main/resources/onboarding_configuration.yaml +++ b/openecomp-be/lib/openecomp-sdc-notification-lib/openecomp-sdc-notification-worker/src/main/resources/onboarding_configuration.yaml @@ -3,3 +3,14 @@ notifications: selectionSize: 10 beHost: localhost beHttpPort: 8080 + +cassandraConfig: + cassandraHosts: ['localhost'] + localDataCenter: CLUSTER_NAME + reconnectTimeout : 30000 + authenticate: true + username: CS_USER + password: CS_PASS + ssl: false + truststorePath : /config/.truststore + truststorePassword : Aa123456 diff --git a/openecomp-be/pom.xml b/openecomp-be/pom.xml index 517a425835..03613c4438 100644 --- a/openecomp-be/pom.xml +++ b/openecomp-be/pom.xml @@ -16,14 +16,6 @@ ../onboarding - - /api - /lib - /tools/swagger-ui - /tools/zusammen-tools - /backend - - com.fasterxml.jackson.core @@ -210,5 +202,32 @@ + + /api + /lib + /tools/swagger-ui + /tools/zusammen-tools + /backend + + + + + + + + + + + + docker + + false + + + + /dist + + + diff --git a/openecomp-be/tools/install/database/init_keyspaces.cql b/openecomp-be/tools/install/database/init_keyspaces.cql new file mode 100644 index 0000000000..86cea01c45 --- /dev/null +++ b/openecomp-be/tools/install/database/init_keyspaces.cql @@ -0,0 +1,2 @@ +CREATE KEYSPACE IF NOT EXISTS dox WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }; +CREATE KEYSPACE IF NOT EXISTS zusammen_dox WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 1 }; \ No newline at end of file diff --git a/openecomp-be/tools/install/database/init_schemas.cql b/openecomp-be/tools/install/database/init_schemas.cql new file mode 100644 index 0000000000..1aa5d11303 --- /dev/null +++ b/openecomp-be/tools/install/database/init_schemas.cql @@ -0,0 +1,50 @@ +USE dox; +CREATE TYPE IF NOT EXISTS version (major int, minor int); +CREATE TYPE IF NOT EXISTS user_candidate_version (version frozen, user text); +CREATE TABLE IF NOT EXISTS version_info (entity_type text, entity_id text, active_version frozen, status text, candidate frozen, viewable_versions set>, latest_final_version frozen, PRIMARY KEY (entity_type, entity_id)); +CREATE TABLE IF NOT EXISTS version_info_deleted (entity_type text, entity_id text, active_version frozen, status text, candidate frozen, viewable_versions set>, latest_final_version frozen, PRIMARY KEY (entity_type, entity_id)); +CREATE TABLE IF NOT EXISTS unique_value (type text, value text, PRIMARY KEY ((type, value))); +CREATE TABLE IF NOT EXISTS package_details (VSP_ID text, version text,DISPLAY_NAME text,vsp_name text,vsp_description text,VENDOR_NAME text,CATEGORY text,SUB_CATEGORY text,VENDOR_RELEASE text,PACKAGE_CHECKSUM text,PACKAGE_TYPE text,TRANSLATE_CONTENT blob,PRIMARY KEY ((VSP_ID, version))); +CREATE TABLE IF NOT EXISTS vsp_enriched_service_template (vsp_id text, version frozen, base_name text static, name text, content_data blob, PRIMARY KEY ((vsp_id, version), name)); +CREATE TABLE IF NOT EXISTS vsp_enriched_service_artifact (vsp_id text, version frozen, name text, content_data blob, PRIMARY KEY ((vsp_id, version), name)); +CREATE TABLE IF NOT EXISTS application_config (namespace text, key text, value text, PRIMARY KEY (namespace, key)); +CREATE TABLE IF NOT EXISTS dox.Action (actionUUID text, actionInvariantUUID text, version frozen, status text, name text, vendor_list set, category_list set, timestamp timestamp, user text, supportedModels set, supportedComponents set, data text, PRIMARY KEY ((actionInvariantUUID, version))); +CREATE INDEX IF NOT EXISTS action_supportedComponents ON dox.Action (supportedComponents); +CREATE INDEX IF NOT EXISTS action_category_list ON dox.Action (category_list); +CREATE INDEX IF NOT EXISTS action_supportedModels ON dox.Action (supportedModels); +CREATE INDEX IF NOT EXISTS action_vendor_list ON dox.Action (vendor_list); +CREATE INDEX IF NOT EXISTS action_actionUUID ON dox.Action (actionUUID); +CREATE TABLE IF NOT EXISTS dox.ecompcomponent(id text PRIMARY KEY, name text); +CREATE INDEX IF NOT EXISTS action_name ON dox.Action (name); +CREATE TABLE IF NOT EXISTS action_artifact(artifactuuid text, effective_version int, artifact blob, PRIMARY KEY(artifactuuid, effective_version)) WITH CLUSTERING ORDER BY (effective_version DESC); +CREATE TABLE IF NOT EXISTS activity_log (item_id text, version_id text, activity_id text, type text, user text, timestamp timestamp, success boolean, message text, comment text, PRIMARY KEY (item_id, version_id, activity_id)); +CREATE TABLE IF NOT EXISTS healing (space text,item_id text,version_id text, healing_needed boolean,old_version text, PRIMARY KEY((space,item_id),version_id)); +CREATE TABLE IF NOT EXISTS migration (id text, ismigrated boolean, primary key (id)); +CREATE TABLE IF NOT EXISTS item_permissions (item_id text,user_id text, permission text, PRIMARY KEY(item_id,user_id)) WITH CLUSTERING ORDER BY (user_id DESC); +CREATE TABLE IF NOT EXISTS user_permission_items (user_id text,permission text, item_list set, PRIMARY KEY ((user_id), permission)); +CREATE TABLE IF NOT EXISTS NOTIFICATION_SUBSCRIBERS (entity_id text PRIMARY KEY, subscribers set); +CREATE TABLE IF NOT EXISTS last_notification (owner_id text PRIMARY KEY, event_id timeuuid); +CREATE TABLE IF NOT EXISTS notifications (owner_id text, event_id timeuuid, read boolean, originator_id text, event_type text, event_attributes text, PRIMARY KEY (owner_id, event_id)) WITH CLUSTERING ORDER BY (event_id DESC); +CREATE TABLE IF NOT EXISTS vsp_merge_hint (space text, item_id text, version_id text, model_id text, model_resolution text, PRIMARY KEY ((space, item_id, version_id))); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'composition.component', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "name": { "type": "string"<#if !manual>, "enum": [ "${component.name}" ], "default": "${component.name}" }, "displayName": { "type": "string"<#if !manual && component.displayName??>, "enum": [ "${component.displayName}" ], "default": "${component.displayName}" }, "vfcCode": { "type": "string" }, "nfcCode": { "type": "string" }, "nfcFunction": { "type": "string" }, "description": { "type": "string" } }, "additionalProperties": false, "required": [ "name"<#if !manual && component.displayName??>, "displayName" ] }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'composition.compute', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "name": { "type": "string" <#if !manual>, "enum": [ "${compute.name}" ], "default": "${compute.name}" }, "description": { "type": "string", "maxLength": 300 } } }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'composition.deployment', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "model": { "type": "string", "maxLength": 30 }, "description": { "type": "string", "maxLength": 300 }, "featureGroupId":{ "type": "string", "enum": [<#if featureGroupIds??> <#list featureGroupIds as featureGroupId> "${featureGroupId}"<#sep>, ] }, "componentComputeAssociations": { "type": "array", "properties": { "vfcid": { "type": "string" }, "computeFlavorid": { "type": "string" } }, "additionalProperties": false } }, "additionalProperties": false, "required": [ "model" ] }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'composition.image', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "fileName": { "type": "string" }, "description": { "type": "string" } }, "additionalProperties": false }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'composition.network', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "name": { "type": "string"<#if !manual>, "enum": [ "${network.name}" ], "default": "${network.name}" }, "dhcp": { "type": "boolean"<#if !manual>, "enum": [ ${network.dhcp?c} ], "default": ${network.dhcp?c} } }, "additionalProperties": false, "required": [ "name", "dhcp" ] }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'composition.nic', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "name": { "type": "string", "enum": [ "${nic.name}" ], "default": "${nic.name}" }, "description": { "type": "string" }<#if !manual><#if nic.networkId??>, "networkId": { "type": "string", "enum": [ "${nic.networkId}" ], "default": "${nic.networkId}" } <#elseif manual><#if nic.networkId??>, "networkId": { "type": "string", "enum": [ "${nic.networkId}" ], "default": "${nic.networkId}" } <#else>, "networkId": { "type": "string", "enum": [<#list networkIds as networkId> "${networkId}"<#sep>, ] } , "networkDescription": { "type": "string" }, "networkType": { "type": "string", "enum": [ "${nic.networkType}" ], "default": "${nic.networkType}" } }, "additionalProperties": false, "required": [ "name" ] }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'questionnaire.component', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "general": { "type": "object", "properties": { "hypervisor": { "type": "object", "properties": { "hypervisor": { "type": "string", "enum": [ "KVM", "VMWare ESXi" ], "default": "KVM" }, "drivers": { "type": "string", "maxLength": 300, "pattern": "^[A-Za-z0-9_,-]*$" }, "containerFeaturesDescription": { "type": "string", "maxLength": 1000, "pattern": "^[A-Za-z0-9_, -]*$" } }, "additionalProperties": false }, "image": { "type": "object", "properties": { "providedBy": { "type": "string", "enum": [ "AIC", "Vendor" ], "default": "AIC" } }, "additionalProperties": false }, "disk": { "type": "object" , "properties": { "bootDiskSizePerVM": { "type": "number", "maximum": 100 }, "ephemeralDiskSizePerVM": { "type": "number", "maximum": 400 } }, "additionalProperties": false }, "recovery": { "type": "object", "properties": { "pointObjective": { "type": "number", "minimum": 0, "exclusiveMinimum": true, "maximum": 15, "exclusiveMaximum ": true }, "timeObjective": { "type": "number", "minimum": 0, "exclusiveMinimum": true, "maximum": 300, "exclusiveMaximum ": true }, "vmProcessFailuresHandling": { "type": "string" } }, "additionalProperties": false }, "dnsConfiguration": { "type": "string" }, "vmCloneUsage": { "type": "string", "maxLength": 300 } }, "additionalProperties": false }, "compute": { "type": "object", "properties": { "numOfVMs": { "type": "object", "properties": { "minimum": { "type": "number", "minimum": 0, "maximum": 100 }, "maximum": { "type": "number", "minimum": <#if (componentQuestionnaireData.compute.numOfVMs.minimum)?? && (componentQuestionnaireData.compute.numOfVMs.minimum)?is_number && ((componentQuestionnaireData.compute.numOfVMs.minimum) > 0 && (componentQuestionnaireData.compute.numOfVMs.minimum) <= 100)> ${componentQuestionnaireData.compute.numOfVMs.minimum}<#else> 0 , "exclusiveMinimum": true, "maximum": 100 } }, "additionalProperties": false }, "guestOS": { "type": "object", "properties": { "name": { "type": "string", "maxLength": 50 }, "bitSize": { "type": "number", "enum": [ 64, 32 ], "default": 64 }, "tools": { "type": "string" } }, "additionalProperties": false } }, "additionalProperties": false }, "highAvailabilityAndLoadBalancing": { "type": "object", "properties": { "isComponentMandatory": { "type": "string", "enum": ["","YES", "NO"], "default": "" }, "highAvailabilityMode": { "type": "string", "enum": ["","geo-activeactive", "geo-activestandby", "local-activeactive", "local-activestandby"], "default": "" }, "failureLoadDistribution": { "type": "string", "maxLength": 1000 }, "nkModelImplementation": { "type": "string", "maxLength": 1000 }, "architectureChoice": { "type": "string", "maxLength": 1000 }, "slaRequirements": { "type": "string", "maxLength": 1000 }, "horizontalScaling": { "type": "string", "maxLength": 1000 }, "loadDistributionMechanism": { "type": "string", "maxLength": 1000 } }, "additionalProperties": false }, "network": { "type": "object", "properties": { "networkCapacity": { "type": "object", "properties": { "protocolWithHighestTrafficProfileAcrossAllNICs": { "type": "string", "enum": [ "", "TCP", "UDP", "SCTP", "IPsec" ], "default": "" }, "networkTransactionsPerSecond": { "type": "number" } }, "additionalProperties": false } }, "additionalProperties": false }, "storage": { "type": "object", "properties": { "backup": { "type": "object", "properties": { "backupType": { "type": "string", "enum": [ "On Site", "Off Site" ], "default": "On Site" }, "backupStorageSize": { "type": "number" }, "backupSolution": { "type": "string" }, "backupNIC": { "type": "string", "enum": [ ""<#if nicNames??><#list nicNames as nicName> , "${nicName}" ], "default": "" } }, "additionalProperties": false }, "snapshotBackup": { "type": "object", "properties": { "snapshotFrequency": { "type": "number", "default": 24, "minimum": 1, "exclusiveMinimum": true } }, "additionalProperties": false }, "logBackup": { "type": "object", "properties": { "sizeOfLogFiles": { "type": "number", "maximum": 5, "exclusiveMaximum": true }, "logBackupFrequency": { "type": "number", "maximum": 4, "exclusiveMaximum": true }, "logRetentionPeriod": { "type": "number", "maximum": 15, "exclusiveMaximum": true }, "logFileLocation": { "type": "string", "maxLength": 300 } }, "additionalProperties": false } }, "additionalProperties": false } }, "additionalProperties": false }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'questionnaire.compute', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "vmSizing": { "type": "object", "properties": { "numOfCPUs": { "type": "number", "minimum": 0, "exclusiveMinimum": true, "maximum": 16, "default": 2 }, "fileSystemSizeGB": { "type": "number", "minimum": 0, "exclusiveMinimum": true, "default": 5 }, "persistentStorageVolumeSize": { "type": "number", "minimum": 0, "exclusiveMinimum": true }, "ioOperationsPerSec": { "type": "number", "minimum": 0, "exclusiveMinimum": true }, "cpuOverSubscriptionRatio": { "type": "string", "enum": [ "1:1", "4:1", "16:1" ], "default": "4:1" }, "memoryRAM": { "type": "string", "enum": [ "1 GB", "2 GB", "3 GB", "4 GB", "5 GB", "6 GB", "7 GB", "8 GB", "9 GB", "10 GB", "11 GB", "12 GB", "13 GB", "14 GB", "15 GB", "16 GB", "17 GB", "18 GB", "19 GB", "20 GB", "21 GB", "22 GB", "23 GB", "24 GB", "25 GB", "26 GB", "27 GB", "28 GB", "29 GB", "30 GB", "31 GB", "32 GB" ], "default": "1 GB" } }, "additionalProperties": false } } }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'questionnaire.image', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "format": { "type": "string", "enum": [ "aki","ami","ari","iso","qcow2","raw", "vdi","vhd","vmdk" ] }, "version": { "type": "string", "minLength": 1 }, "md5": { "type": "string" } }, "additionalProperties": false, "required": [ "version" ] }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'questionnaire.nic', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "protocols": { "type": "object", "properties": { "protocols": { "type": "array", "items": { "type": "string", "enum": [ "", "TCP", "UDP", "SCTP", "IPsec" ], "default": "" }, "minItems": 1 }, "protocolWithHighestTrafficProfile": { "$ref": "#/properties/protocols/properties/protocols/items" } }, "additionalProperties": false }, "ipConfiguration": { "type": "object", "properties": { "ipv4Required": { "type": "boolean", "default": true }, "ipv6Required": { "type": "boolean", "default": false } }, "additionalProperties": false }, "network": { "type": "object", "properties": { "networkDescription": { "type": "string", "pattern": "[A-Za-z]+", "maxLength": 300 } }, "additionalProperties": false }, "sizing": { "type": "object", "definitions": { "peakAndAvg": { "type": "object", "properties": { "peak": { "type": "number" }, "avg": { "type": "number" } }, "additionalProperties": false }, "packetsAndBytes": { "type": "object", "properties": { "packets": { "$ref": "#/properties/sizing/definitions/peakAndAvg" }, "bytes": { "$ref": "#/properties/sizing/definitions/peakAndAvg" } }, "additionalProperties": false } }, "properties": { "describeQualityOfService": { "type": "string" }, "inflowTrafficPerSecond": { "$ref": "#/properties/sizing/definitions/packetsAndBytes" }, "outflowTrafficPerSecond": { "$ref": "#/properties/sizing/definitions/packetsAndBytes" }, "flowLength": { "$ref": "#/properties/sizing/definitions/packetsAndBytes" }, "acceptableJitter": { "type": "object", "properties": { "mean": { "type": "number" }, "max": { "type": "number" }, "variable": { "type": "number" } }, "additionalProperties": false }, "acceptablePacketLoss": { "type": "number", "minimum": 0, "maximum": 100 } }, "additionalProperties": false } }, "additionalProperties": false }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.schemaTemplates', 'questionnaire.vsp', '{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "general": { "type": "object", "properties": { "affinityData": { "type": "string", "enum": [ "", "Affinity", "Anti Affinity", "None" ], "default": "" }, "availability": { "type": "object", "properties": { "useAvailabilityZonesForHighAvailability": { "type": "boolean", "default": false } }, "additionalProperties": false }, "regionsData": { "type": "object", "properties": { "multiRegion": { "type": "boolean", "default": false }, "regions": { "type": "array", "items": { "type": "string", "enum": [ "", "Alphareta", "Birmingham", "Dallas", "Fairfield CA", "Hayward CA", "Lisle", "Mission", "San Diego", "Secaucus" ], "default": "" } } }, "additionalProperties": false }, "storageDataReplication": { "type": "object", "properties": { "storageReplicationAcrossRegion": { "type": "boolean", "default": false }, "storageReplicationSize": { "type": "number", "minimum": 0, "maximum": 100, "exclusiveMaximum": true }, "storageReplicationFrequency": { "type": "number", "minimum": 5 }, "storageReplicationSource": { "type": "string", "maxLength": 300 }, "storageReplicationDestination": { "type": "string", "maxLength": 300 } }, "additionalProperties": false } }, "additionalProperties": false } }, "additionalProperties": false }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.monitoring', 'compute.ceilometer', '{ "ceilometerMetricList": [ { "name": "instance", "type": "Gauge", "unit": "instance", "category": "compute", "description": "Existence of instance" }, { "name": "memory", "type": "Gauge", "unit": "MB", "category": "compute", "description": "Volume of RAM allocated to the instance" }, { "name": "memory.usage", "type": "Gauge", "unit": "MB", "category": "compute", "description": "Volume of RAM used by the instance from the amount of its allocated memory" }, { "name": "memory.resident", "type": "Gauge", "unit": "MB", "category": "compute", "description": "Volume of RAM used by the instance on the physical machine" }, { "name": "cpu", "type": "Cumulative", "unit": "ns", "category": "compute", "description": "CPU time used" }, { "name": "cpu_util", "type": "Gauge", "unit": "%", "category": "compute", "description": "Average CPU utilization" }, { "name": "cpu.delta", "type": "Delta", "unit": "ns", "category": "compute", "description": "CPU time used since previous datapoint" }, { "name": "vcpus", "type": "Gauge", "unit": "vcpu", "category": "compute", "description": "Number of virtual CPUs allocated to the instance" }, { "name": "disk.latency", "type": "Gauge", "unit": "ms", "category": "disk", "description": "Average disk latency" }, { "name": "disk.iops", "type": "Gauge", "unit": "count/s", "category": "disk", "description": "Average disk iops" }, { "name": "disk.device.latency", "type": "Gauge", "unit": "ms", "category": "disk", "description": "Average disk latency per device" }, { "name": "disk.device.iops", "type": "Gauge", "unit": "count/s", "category": "disk", "description": "Average disk iops per device" }, { "name": "disk.capacity", "type": "Gauge", "unit": "B", "category": "disk", "description": "The amount of disk that the instance can see" }, { "name": "disk.allocation", "type": "Gauge", "unit": "B", "category": "disk", "description": "The amount of disk occupied by the instance on the host machine" }, { "name": "disk.usage", "type": "Gauge", "unit": "B", "category": "disk", "description": "The physical size in bytes of the image container on the host" }, { "name": "disk.device.capacity", "type": "Gauge", "unit": "B", "category": "disk", "description": "The amount of disk per device that the instance can see" }, { "name": "disk.device.allocation", "type": "Gauge", "unit": "B", "category": "disk", "description": "The amount of disk per device occupied by the instance on the host machine" }, { "name": "disk.device.usage", "type": "Gauge", "unit": "B", "category": "disk", "description": "The physical size in bytes of the image container on the host per device" }, { "name": "disk.device.read.requests", "type": "Cumulative", "unit": "request", "category": "disk", "description": "Number of read requests" }, { "name": "disk.device.read.requests.rate", "type": "Gauge", "unit": "request/s", "category": "disk", "description": "Average rate of read requests" }, { "name": "disk.device.write.requests", "type": "Cumulative", "unit": "request", "category": "disk", "description": "Number of write requests" }, { "name": "disk.device.write.requests.rate", "type": "Gauge", "unit": "request/s", "category": "disk", "description": "Average rate of write requests" }, { "name": "disk.device.read.bytes", "type": "Cumulative", "unit": "B", "category": "disk", "description": "Volume of reads" }, { "name": "disk.device.read.bytes.rate", "type": "Gauge", "unit": "B/s", "category": "disk", "description": "Average rate of reads" }, { "name": "disk.device.write.bytes", "type": "Cumulative", "unit": "B", "category": "disk", "description": "Volume of writes" }, { "name": "disk.device.write.bytes.rate", "type": "Gauge", "unit": "B/s", "category": "disk", "description": "Average rate of writes" }, { "name": "disk.write.requests", "type": "Cumulative", "unit": "request", "category": "compute", "description": "Number of write requests" }, { "name": "disk.write.requests.rate", "type": "Gauge", "unit": "request/s", "category": "compute", "description": "Average rate of write requests" }, { "name": "disk.read.bytes", "type": "Cumulative", "unit": "B", "category": "compute", "description": "Volume of reads" }, { "name": "disk.read.bytes.rate", "type": "Gauge", "unit": "B/s", "category": "compute", "description": "Average rate of reads" }, { "name": "disk.write.bytes", "type": "Cumulative", "unit": "B", "category": "compute", "description": "Volume of writes" }, { "name": "disk.write.bytes.rate", "type": "Gauge", "unit": "B/s", "category": "compute", "description": "Average rate of writes" }, { "name": "disk.read.requests", "type": "Cumulative", "unit": "request", "category": "compute", "description": "Number of read requests" }, { "name": "disk.root.size", "type": "Gauge", "unit": "GB", "category": "compute", "description": "Size of root disk" }, { "name": "disk.ephemeral.size", "type": "Gauge", "unit": "GB", "category": "compute", "description": "Size of ephemeral disk" } ] }'); +INSERT INTO application_config (namespace,key,value) VALUES ('vsp.monitoring', 'port.ceilometer', '{ "ceilometerMetricList": [ { "name": "network.incoming.bytes", "type": "Cumulative", "unit": "B", "category": "network", "description": "Number of incoming bytes" }, { "name": "network.incoming.bytes.rate", "type": "Gauge", "unit": "B/s", "category": "network", "description": "Average rate of incoming bytes" }, { "name": "network.outgoing.bytes", "type": "Cumulative", "unit": "B", "category": "network", "description": "Number of outgoing bytes" }, { "name": "network.outgoing.bytes.rate", "type": "Gauge", "unit": "B/s", "category": "network", "description": "Average rate of outgoing bytes" }, { "name": "network.incoming.packets", "type": "Cumulative", "unit": "packet", "category": "network", "description": "Number of incoming packets" }, { "name": "network.incoming.packets.rate", "type": "Gauge", "unit": "packet/s", "category": "network", "description": "Average rate of incoming packets" }, { "name": "network.outpoing.packets", "type": "Cumulative", "unit": "packet", "category": "network", "description": "Number of outgoing packets" }, { "name": "network.outgoing.packets.rate", "type": "Gauge", "unit": "packet/s", "category": "network", "description": "Average rate of outgoing packets" } ] }'); +USE zusammen_dox; +CREATE TABLE IF NOT EXISTS item (item_id text primary key, item_info text, creation_time timestamp, modification_time timestamp); +CREATE TABLE IF NOT EXISTS version (space text, item_id text, version_id text,base_version_id text,info text,relations text,creation_time timestamp,modification_time timestamp ,PRIMARY KEY (( space, item_id ), version_id)); +CREATE TABLE IF NOT EXISTS version_elements (space text,item_id text,version_id text,revision_id text,element_ids Map, dirty_element_ids set,stage_element_ids set, conflict_element_ids set, publish_time timestamp,user text,message text, PRIMARY KEY (( space, item_id, version_id ),revision_id)); +CREATE TABLE IF NOT EXISTS element_namespace (item_id text, element_id text, namespace text, PRIMARY KEY ((item_id, element_id))); +CREATE TABLE IF NOT EXISTS element (space text,item_id text,version_id text,element_id text,revision_id text,parent_id text,namespace text,info text,relations text,data blob,searchable_data blob,visualization blob,sub_element_ids set ,element_hash text,PRIMARY KEY (( space, item_id, version_id, element_id ),revision_id)); +CREATE TABLE IF NOT EXISTS element_synchronization_state (space text, item_id text, version_id text, element_id text,revision_id text, publish_time timestamp, dirty boolean, PRIMARY KEY (( space, item_id, version_id ), element_id,revision_id)); +CREATE TABLE IF NOT EXISTS element_stage (space text, item_id text,version_id text, element_id text, parent_id text, namespace text, info text, relations text,data blob, searchable_data blob, visualization blob, sub_element_ids set,element_hash text, publish_time timestamp, action text, conflicted boolean,conflict_dependent_ids set, PRIMARY KEY (( space, item_id, version_id, element_id ))); +CREATE TABLE IF NOT EXISTS version_stage (space text, item_id text, version_id text, base_version_id text, creation_time timestamp,modification_time timestamp, publish_time timestamp, action text, PRIMARY KEY (( space, item_id ), version_id)); \ No newline at end of file diff --git a/pom.xml b/pom.xml index e10b896cb7..6354009ad9 100644 --- a/pom.xml +++ b/pom.xml @@ -118,7 +118,7 @@ 0.23.0 ${project.version}-${maven.build.timestamp} - ${project.version}-latest + @@ -446,17 +446,17 @@ - ecomp-releases + onap-releases Release Repository ${nexus.proxy}/content/repositories/releases/ - ecomp-snapshots + onap-snapshots Snapshots Repository ${nexus.proxy}/content/repositories/snapshots/ - ecomp-public + onap-public Public Repository ${nexus.proxy}/content/repositories/public/ @@ -465,17 +465,17 @@ - ecomp-releases + onap-releases Release Repository ${nexus.proxy}/content/repositories/releases/ - ecomp-snapshots + onap-snapshots Snapshot Repository ${nexus.proxy}/content/repositories/snapshots/ - ecomp-site + onap-site dav:${nexus.proxy}${sitePath} diff --git a/sdc-os-chef/environments/Template.json b/sdc-os-chef/environments/Template.json index 7eb7376ed4..9073f2c562 100644 --- a/sdc-os-chef/environments/Template.json +++ b/sdc-os-chef/environments/Template.json @@ -11,6 +11,7 @@ "disableHttp": false, "CS_VIP": "yyy", "BE_VIP": "yyy", + "ONBOARDING_BE_VIP": "yyy", "FE_VIP": "yyy", "ES_VIP": "yyy", "KB_VIP": "yyy", @@ -34,11 +35,12 @@ "fqdn": ["10.0.11.1", "10.0.11.1"] }, "Nodes": { - "CS": "yyy", - "BE": "yyy", - "FE": "yyy", - "ES": "yyy", - "KB": "yyy" + "CS": "yyy", + "BE": "yyy", + "ONBOARDING_BE": "yyy", + "FE": "yyy", + "ES": "yyy", + "KB": "yyy" }, "Plugins": { "DCAE": { @@ -64,6 +66,10 @@ "http_port": "8080", "https_port": "8443" }, + "ONBOARDING_BE": { + "http_port": "8081", + "https_port": "8445" + }, "elasticsearch": { "cluster_name": "SDC-ES-", "ES_path_home": "/usr/share/elasticsearch", diff --git a/sdc-os-chef/kubernetes/sdc/templates/configmaps/sdc-environment-configmap.yaml b/sdc-os-chef/kubernetes/sdc/templates/configmaps/sdc-environment-configmap.yaml index abc1d209ba..29215a0748 100644 --- a/sdc-os-chef/kubernetes/sdc/templates/configmaps/sdc-environment-configmap.yaml +++ b/sdc-os-chef/kubernetes/sdc/templates/configmaps/sdc-environment-configmap.yaml @@ -17,11 +17,12 @@ data: "default_attributes": { "disableHttp": false, - "CS_VIP": "sdc-cs.{{ .Values.nsPrefix }}", - "BE_VIP": "sdc-be.{{ .Values.nsPrefix }}", - "FE_VIP": "sdc-fe.{{ .Values.nsPrefix }}", - "ES_VIP": "sdc-es.{{ .Values.nsPrefix }}", - "KB_VIP": "sdc-es.{{ .Values.nsPrefix }}", + "CS_VIP": "sdc-cs.{{ .Values.nsPrefix }}-sdc", + "BE_VIP": "sdc-be.{{ .Values.nsPrefix }}-sdc", + "ONBOARDING_BE_VIP": "sdc-onboard-be.{{ .Values.nsPrefix }}-sdc", + "FE_VIP": "sdc-fe.{{ .Values.nsPrefix }}-sdc", + "ES_VIP": "sdc-es.{{ .Values.nsPrefix }}-sdc", + "KB_VIP": "sdc-es.{{ .Values.nsPrefix }}-sdc", "interfaces": { "application": "eth0", "private": "eth1" @@ -44,6 +45,7 @@ data: "Nodes": { "CS": "sdc-cs", "BE": "sdc-be", + "ONBOARDING_BE": "sdc-onboard-be", "FE": "sdc-fe", "ES": "sdc-es", "KB": "sdc-kb" @@ -72,6 +74,10 @@ data: "http_port": "8080", "https_port": "8443" }, + "ONBOARDING_BE": { + "http_port": "8081", + "https_port": "8445" + }, "elasticsearch": { "cluster_name": "SDC-ES-", "ES_path_home": "/usr/share/elasticsearch", diff --git a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-be.yaml b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-be.yaml index c0ff9e13a1..8189bd9785 100644 --- a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-be.yaml +++ b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-be.yaml @@ -35,6 +35,8 @@ spec: - sdc-cs - --container-name - sdc-kb + - --container-name + - sdc-onboard-backend env: - name: NAMESPACE valueFrom: @@ -67,8 +69,8 @@ spec: - containerPort: 8443 - containerPort: 8080 volumeMounts: - - mountPath: /usr/share/elasticsearch/data/ - name: sdc-sdc-es-es + #- mountPath: /usr/share/elasticsearch/data/ + # name: sdc-sdc-es-es - mountPath: /root/chef-solo/environments/ name: sdc-environments - mountPath: /etc/localtime @@ -88,14 +90,17 @@ spec: fieldRef: fieldPath: status.podIP - name: JAVA_OPTIONS - value: "" + value: "-Xmx1536m -Xms1536m" + - name: cassandra_ssl_enabled + value: "false" lifecycle: postStart: exec: command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/catalog-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"] readinessProbe: - tcpSocket: - port: 8443 + exec: + command: + - "/var/lib/ready-probe.sh" initialDelaySeconds: 120 periodSeconds: 10 failureThreshold: 30 @@ -110,9 +115,9 @@ spec: - name: sdc-logback hostPath: path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/sdc/be/logback.xml - - name: sdc-sdc-es-es - hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES + #- name: sdc-sdc-es-es + # hostPath: + # path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES - name: sdc-environments configMap: name: sdc-environment @@ -121,7 +126,7 @@ spec: path: /etc/localtime - name: sdc-logs hostPath: - path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs + path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs/BE - name: sdc-check-job-completion configMap: name: sdc-check-job-completion diff --git a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-cs.yaml b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-cs.yaml index 61efd8ba9a..9dad280526 100644 --- a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-cs.yaml +++ b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-cs.yaml @@ -30,6 +30,10 @@ spec: - name: CS_PASSWORD valueFrom: secretKeyRef: {name: sdc-cs-secret, key: cs_password} + - name: MAX_HEAP_SIZE + value: 1536M + - name: HEAP_NEWSIZE + value: 512M volumeMounts: - mountPath: /var/lib/cassandra/ name: sdc-sdc-cs-cs diff --git a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-fe.yaml b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-fe.yaml index 874db48f58..68493a7b84 100644 --- a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-fe.yaml +++ b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-fe.yaml @@ -22,13 +22,11 @@ spec: - /root/ready.py args: - --container-name - - sdc-es - - --container-name - - sdc-cs - - --container-name - sdc-kb - --container-name - sdc-be + - --container-name + - sdc-onboard-backend env: - name: NAMESPACE valueFrom: @@ -37,6 +35,21 @@ spec: fieldPath: metadata.namespace image: "{{ .Values.image.readiness }}" imagePullPolicy: "{{ .Values.pullPolicy }}" + - name: sdc-job-completion + image: "{{ .Values.image.readiness }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + command: + - python + args: + - /root/readiness/sdc_check_job_completion.py + - --job-name + - sdc-config-backend + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace volumes: # - name: filebeat-conf # hostPath: @@ -45,24 +58,15 @@ spec: emptyDir: {} - name: sdc-data-filebeat emptyDir: {} -# - name: sdc-logback -# hostPath: -# path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/sdc/fe/logback.xml -# - name: sdc-sdc-es-es -# hostPath: -# path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-es/ES - name: sdc-environments configMap: name: sdc-environment - name: sdc-localtime hostPath: path: /etc/localtime -# - name: sdc-logs -# hostPath: -# path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs -# - name: sdc-fe-config -# hostPath: -# path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/sdc-fe/FE_2_setup_configuration.rb + - name: sdc-logs + hostPath: + path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs/FE imagePullSecrets: - name: "{{ .Values.nsPrefix }}-docker-registry-key" containers: @@ -77,23 +81,17 @@ spec: fieldRef: fieldPath: status.podIP - name: JAVA_OPTIONS - value: "" + value: "-Xmx256m -Xms256m" volumeMounts: -# - mountPath: /usr/share/elasticsearch/data/ -# name: sdc-sdc-es-es - mountPath: /root/chef-solo/environments/ name: sdc-environments - mountPath: /etc/localtime name: sdc-localtime readOnly: true -# - mountPath: /var/lib/jetty/logs -# name: sdc-logs + - mountPath: /var/lib/jetty/logs + name: sdc-logs # - mountPath: /var/log/onap # name: sdc-logs-2 -# - mountPath: /root/chef-solo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb -# name: sdc-fe-config -# - mountPath: /tmp/logback.xml -# name: sdc-logback lifecycle: postStart: exec: diff --git a/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-onboard.yaml b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-onboard.yaml new file mode 100644 index 0000000000..267b3bb3d2 --- /dev/null +++ b/sdc-os-chef/kubernetes/sdc/templates/deployments/sdc-onboard.yaml @@ -0,0 +1,131 @@ +#{{ if not .Values.disableSdcSdcBe }} +apiVersion: extensions/v1beta1 +kind: Deployment +metadata: + labels: + app: sdc-onboard-backend + name: sdc-onboard-backend + namespace: "{{ .Values.nsPrefix }}-sdc" +spec: + replicas: 1 + strategy: + type: RollingUpdate + rollingUpdate: + maxSurge: 2 + maxUnavailable: 0 + selector: + matchLabels: + app: sdc-onboard-backend + template: + metadata: + labels: + app: sdc-onboard-backend + name: sdc-onboard-backend + spec: + initContainers: + - name: sdc-onboard-init-readiness + image: "{{ .Values.image.readiness }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + command: + - /root/ready.py + args: + - --container-name + - sdc-cs + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + - name: sdc-job-completion + image: "{{ .Values.image.readiness }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + command: + - python + args: + - /root/readiness/sdc_check_job_completion.py + - --job-name + - sdc-onboard-cassandra-init + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + volumeMounts: + - mountPath: /root/readiness + name: sdc-check-job-completion + containers: + - name: sdc-onboard-backend + image: "{{ .Values.image.sdcOnboardBackend }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + ports: + - containerPort: 8445 + - containerPort: 8081 + volumeMounts: + - mountPath: /root/chef-solo/environments/ + name: sdc-environments + - mountPath: /etc/localtime + name: sdc-localtime + readOnly: true + - mountPath: /var/lib/jetty/logs + name: sdc-logs + - mountPath: /var/log/onap + name: sdc-logs-2 + - mountPath: /tmp/logback.xml + name: sdc-logback + env: + - name: ENVNAME + value: "{{ .Values.env.name }}" + - name: HOST_IP + valueFrom: + fieldRef: + fieldPath: status.podIP + - name: SDC_CLUSTER_NAME + value: "SDC-CS-{{ .Values.env.name }}" + - name: SDC_USER + valueFrom: + secretKeyRef: {name: sdc-cs-secret, key: sdc_user} + - name: SDC_PASSWORD + valueFrom: + secretKeyRef: {name: sdc-cs-secret, key: sdc_password} + - name: JAVA_OPTIONS + value: "-Xdebug -agentlib:jdwp=transport=dt_socket,address=4001,server=y,suspend=n -Xmx1g -Xms1g" + - name: cassandra_ssl_enabled + value: "false" + lifecycle: + postStart: + exec: + command: ["/bin/sh", "-c", "export LOG=wait_logback.log; touch $LOG; export SRC=/tmp/logback.xml; export DST=/var/lib/jetty/config/onboarding-be/; while [ ! -e $DST ]; do echo 'Waiting for $DST...' >> $LOG; sleep 5; done; sleep 2; /bin/cp -f $SRC $DST; echo 'Done' >> $LOG"] + readinessProbe: + exec: + command: + - "/var/lib/ready-probe.sh" + initialDelaySeconds: 60 + periodSeconds: 10 + volumes: + - name: filebeat-conf + hostPath: + path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/filebeat/logback/filebeat.yml + - name: sdc-logs-2 + emptyDir: {} + - name: sdc-data-filebeat + emptyDir: {} + - name: sdc-logback + hostPath: + path: /dockerdata-nfs/{{ .Values.nsPrefix }}/log/sdc/onboard-be/logback.xml + - name: sdc-environments + configMap: + name: sdc-environment + - name: sdc-localtime + hostPath: + path: /etc/localtime + - name: sdc-logs + hostPath: + path: /dockerdata-nfs/{{ .Values.nsPrefix }}/sdc/logs/ONBOARD + - name: sdc-check-job-completion + configMap: + name: sdc-check-job-completion + imagePullSecrets: + - name: "{{ .Values.nsPrefix }}-docker-registry-key" +#{{ end }} diff --git a/sdc-os-chef/kubernetes/sdc/templates/jobs/sdc-onboard-cassandra-init.yaml b/sdc-os-chef/kubernetes/sdc/templates/jobs/sdc-onboard-cassandra-init.yaml new file mode 100644 index 0000000000..2cf9ec3fd3 --- /dev/null +++ b/sdc-os-chef/kubernetes/sdc/templates/jobs/sdc-onboard-cassandra-init.yaml @@ -0,0 +1,86 @@ +--- +apiVersion: batch/v1 +kind: Job +metadata: + name: sdc-onboard-cassandra-init + namespace: "{{ .Values.nsPrefix }}-sdc" + labels: + app: sdc-onboard-cassandra-init +spec: + template: + metadata: + name: sdc-onboard-cassandra-init + spec: + initContainers: + - name: sdc-init-cs-readiness + image: "{{ .Values.image.readiness }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + command: + - /root/ready.py + args: + - --container-name + - sdc-cs + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + - name: sdc-job-completion + image: "{{ .Values.image.readiness }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + command: + - python + args: + - /root/readiness/sdc_check_job_completion.py + - --job-name + - sdc-config-cassandra + env: + - name: NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + volumeMounts: + - mountPath: /root/readiness + name: sdc-check-job-completion + + containers: + - name: sdc-onboard-cassandra-init + image: "{{ .Values.image.sdcOnboardBackendInit }}" + imagePullPolicy: "{{ .Values.pullPolicy }}" + volumeMounts: + - mountPath: /root/chef-solo/environments/ + name: sdc-environments + - mountPath: /var/lib/cassandra/ + name: sdc-sdc-cs-cs + env: + - name: ENVNAME + value: "{{ .Values.env.name }}" + - name: CS_HOST_IP + value: sdc-cs + - name: SDC_USER + valueFrom: + secretKeyRef: {name: sdc-cs-secret, key: sdc_user} + - name: SDC_PASSWORD + valueFrom: + secretKeyRef: {name: sdc-cs-secret, key: sdc_password} + - name: CS_PASSWORD + valueFrom: + secretKeyRef: {name: sdc-cs-secret, key: cs_password} + volumes: + - name: sdc-sdc-cs-cs + persistentVolumeClaim: + claimName: sdc-cs-db + - name: sdc-environments + configMap: + name: sdc-environment + - name: sdc-localtime + hostPath: + path: /etc/localtime + - name: sdc-check-job-completion + configMap: + name: sdc-check-job-completion + imagePullSecrets: + - name: "{{ .Values.nsPrefix }}-docker-registry-key" + restartPolicy: Never diff --git a/sdc-os-chef/kubernetes/sdc/templates/services/all-services.yaml b/sdc-os-chef/kubernetes/sdc/templates/services/all-services.yaml index 4100dc24a4..d568e9c317 100644 --- a/sdc-os-chef/kubernetes/sdc/templates/services/all-services.yaml +++ b/sdc-os-chef/kubernetes/sdc/templates/services/all-services.yaml @@ -124,4 +124,36 @@ spec: selector: app: sdc-fe type: NodePort +--- +apiVersion: v1 +kind: Service +metadata: + labels: + app: sdc-onboard-be + name: sdc-onboard-be + namespace: "{{ .Values.nsPrefix }}-sdc" + annotations: + msb.onap.org/service-info: '[ + { + "serviceName": "sdc-onboard-be", + "version": "v1", + "url": "/sdc/v1", + "protocol": "REST", + "port": "8081", + "visualRange":"1" + } + ]' +spec: + ports: + - name: sdc-onboard-port-8445 + nodePort: {{ .Values.nodePortPrefix }}09 + port: 8445 + - name: sdc-onboard-port-8081 + nodePort: {{ .Values.nodePortPrefix }}08 + port: 8081 + selector: + app: sdc-onboard-be + type: NodePort +#{{ end }} +#{{ if not .Values.disableSdcSdcOnboardBE }} #{{ end }} \ No newline at end of file diff --git a/sdc-os-chef/kubernetes/sdc/values.yaml b/sdc-os-chef/kubernetes/sdc/values.yaml index eea6b56707..d871190321 100644 --- a/sdc-os-chef/kubernetes/sdc/values.yaml +++ b/sdc-os-chef/kubernetes/sdc/values.yaml @@ -11,6 +11,8 @@ image: sdcElasticsearchInit: nexus3.onap.org:10001/onap/sdc-init-elasticsearch:1.2-STAGING-latest sdcCassandraInit: nexus3.onap.org:10001/onap/sdc-cassandra-init:1.2-STAGING-latest sdcBackendInit: nexus3.onap.org:10001/onap/sdc-backend-init:1.2-STAGING-latest + sdcOnboardBackendInit: nexus3.onap.org:10001/onap/sdc-onboard-cassandra-init:1.2-STAGING-latest + sdcOnboardBackend: nexus3.onap.org:10001/onap/sdc-onboard-backend:1.2-STAGING-latest filebeat: docker.elastic.co/beats/filebeat:5.5.0 env: diff --git a/sdc-os-chef/pom.xml b/sdc-os-chef/pom.xml index 3425389408..c8c3acd6e0 100644 --- a/sdc-os-chef/pom.xml +++ b/sdc-os-chef/pom.xml @@ -84,13 +84,13 @@ - - docker-staging - - ${project.version}-STAGING-${maven.build.timestamp} - ${project.version}-STAGING-latest - - + + + + + + + docker @@ -131,7 +131,6 @@ ${project.basedir}/sdc-init-elasticsearch ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest @@ -146,7 +145,6 @@ ${project.basedir}/sdc-elasticsearch ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest @@ -161,7 +159,6 @@ ${project.basedir}/sdc-kibana ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest @@ -176,7 +173,6 @@ ${project.basedir}/sdc-cassandra ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest diff --git a/sdc-os-chef/scripts/docker_run.sh b/sdc-os-chef/scripts/docker_run.sh index b7d96d5c62..2c12fffd7d 100755 --- a/sdc-os-chef/scripts/docker_run.sh +++ b/sdc-os-chef/scripts/docker_run.sh @@ -6,6 +6,7 @@ SDC_PASSWORD="Aa1234%^!" JETTY_BASE="/var/lib/jetty" BE_JAVA_OPTIONS="-Xdebug -agentlib:jdwp=transport=dt_socket,address=4000,server=y,suspend=n -Xmx1536m -Xms1536m" FE_JAVA_OPTIONS="-Xdebug -agentlib:jdwp=transport=dt_socket,address=6000,server=y,suspend=n -Xmx256m -Xms256m" +ONBOARD_BE_JAVA_OPTIONS="-Xdebug -agentlib:jdwp=transport=dt_socket,address=4001,server=y,suspend=n -Xmx1g -Xms1g" SIM_JAVA_OPTIONS=" -Xmx128m -Xms128m -Xss1m" API_TESTS_JAVA_OPTIONS="-Xmx512m -Xms512m" UI_TESTS_JAVA_OPTIONS="-Xmx1024m -Xms1024m" @@ -38,6 +39,7 @@ function dir_perms { mkdir -p ${WORKSPACE}/data/logs/BE/SDC/SDC-BE mkdir -p ${WORKSPACE}/data/logs/FE/SDC/SDC-FE mkdir -p ${WORKSPACE}/data/logs/sdc-api-tests/ExtentReport + mkdir -p ${WORKSPACE}/data/logs/ONBOARD/SDC/ONBOARD-BE mkdir -p ${WORKSPACE}/data/logs/sdc-api-tests/target mkdir -p ${WORKSPACE}/data/logs/sdc-ui-tests/ExtentReport mkdir -p ${WORKSPACE}/data/logs/sdc-ui-tests/target @@ -69,19 +71,31 @@ function probe_be { be_stat=false docker exec $1 /var/lib/ready-probe.sh > /dev/null 2>&1 rc=$? -if [[ $rc == 200 ]]; then +if [[ $rc == 0 ]]; then echo DOCKER start finished in $2 seconds be_stat=true fi } +function probe_sdc_onboard_be { + +sdc_onboard_be_stat=false +docker exec $1 /var/lib/ready-probe.sh > /dev/null 2>&1 +rc=$? +if [[ $rc == 0 ]]; then + echo DOCKER start finished in $2 seconds + sdc_onboard_be_stat=true +fi + +} + function probe_fe { fe_stat=false docker exec $1 /var/lib/ready-probe.sh > /dev/null 2>&1 rc=$? -if [[ $rc == 200 ]]; then +if [[ $rc == 0 ]]; then echo DOCKER start finished in $2 seconds fe_stat=true fi @@ -144,6 +158,10 @@ function monitor_docker { elif [ "$1" == "sdc-FE" ]; then probe_fe $1 $TIME if [[ $fe_stat == true ]]; then break; fi + elif [ "$1" == "sdc-onboard-BE" ]; then + probe_sdc_onboard_be $1 $TIME + if [[ $sdc_onboard_be_stat == true ]]; then break; fi + else probe_docker $1 $TIME if [[ $match_result == true ]]; then break; fi @@ -189,6 +207,7 @@ RELEASE=latest LOCAL=false RUNTESTS=false DEBUG_PORT="--publish 4000:4000" +ONBOARD_DEBUG_PORT="--publish 4001:4000" while [ $# -gt 0 ]; do case $1 in @@ -319,6 +338,18 @@ docker_logs sdc-cs-init if [[ $rc != 0 ]]; then exit $rc; fi } +#Onboard Cassandra-init +function sdc-cs-onboard-init { +echo "docker run sdc-cs-onboard-init..." +if [ ${LOCAL} = false ]; then + docker pull ${PREFIX}/sdc-onboard-cassandra-init:${RELEASE} +fi +docker run --name sdc-cs-onboard-init --env RELEASE="${RELEASE}" --env CS_HOST_IP=${IP} --env SDC_USER="${SDC_USER}" --env SDC_PASSWORD="${SDC_PASSWORD}" --env CS_PASSWORD="${CS_PASSWORD}" --env ENVNAME="${DEP_ENV}" --log-driver=json-file --log-opt max-size=100m --log-opt max-file=10 --ulimit memlock=-1:-1 --ulimit nofile=4096:100000 --volume /etc/localtime:/etc/localtime:ro --volume ${WORKSPACE}/data/CS:/var/lib/cassandra --volume ${WORKSPACE}/data/environments:/root/chef-solo/environments --volume ${WORKSPACE}/data/CS-Init:/root/chef-solo/cache ${PREFIX}/sdc-onboard-cassandra-init:${RELEASE} +rc=$? +docker_logs sdc-onboard-cs-init +if [[ $rc != 0 ]]; then exit $rc; fi +} + #Kibana function sdc-kbn { echo "docker run sdc-kibana..." @@ -355,6 +386,23 @@ docker_logs sdc-BE-init if [[ $rc != 0 ]]; then exit $rc; fi } +# Onboard Back-End +function sdc-onboard-BE { + +dir_perms +# Back-End +echo "docker run sdc-onboard-BE ..." +if [ ${LOCAL} = false ]; then + docker pull ${PREFIX}/sdc-onboard-backend:${RELEASE} +else + ADDITIONAL_ARGUMENTS=${ONBOARD_DEBUG_PORT} +fi +docker run --detach --name sdc-onboard-BE --env HOST_IP=${IP} --env ENVNAME="${DEP_ENV}" --env cassandra_ssl_enabled="false" --env SDC_CLUSTER_NAME="SDC-CS-${DEP_ENV}" --env SDC_USER="${SDC_USER}" --env SDC_PASSWORD="${SDC_PASSWORD}" --env JAVA_OPTIONS="${ONBOARD_BE_JAVA_OPTIONS}" --log-driver=json-file --log-opt max-size=100m --log-opt max-file=10 --ulimit memlock=-1:-1 --ulimit nofile=4096:100000 --volume /etc/localtime:/etc/localtime:ro --volume ${WORKSPACE}/data/logs/ONBOARD:/var/lib/jetty/logs --volume ${WORKSPACE}/data/environments:/root/chef-solo/environments --publish 8445:8445 --publish 8081:8081 ${ADDITIONAL_ARGUMENTS} ${PREFIX}/sdc-onboard-backend:${RELEASE} + +echo "please wait while sdc-onboard-BE is starting..." +monitor_docker sdc-onboard-BE +} + # Front-End function sdc-FE { @@ -431,6 +479,8 @@ if [ -z "${DOCKER}" ]; then sdc-cs sdc-cs-init # sdc-kbn + sdc-cs-onboard-init + sdc-onboard-BE sdc-BE sdc-BE-init sdc-FE diff --git a/sdc-os-chef/scripts/k8s/bin_nsenter b/sdc-os-chef/scripts/k8s/bin_nsenter new file mode 100755 index 0000000000000000000000000000000000000000..9137f7145665334afcc1657cc420963312d4249b GIT binary patch literal 90162 zcmeFad3;pW-9LWsOcEvuWQI+`K0pEqkPQJ7)|rsN1cF8g2m%raVX2VBWWrJxqDd^% z7!7r;r3H6tZAGmV&_WOd?4uQNsZ}eu&lnffveYf#_xp3tow)(hr_cBM`~CM^UYT<~ z`*PNM?ww&{e&JM`u50FH(ADM~Iy$(iL*<(OHT@i8|36|4A)Z5}{`JuI|5`HYn0{>wf`;so-JDYn-7=B z-|7H=cL#V^2l{h6@N;|z_|6^ZS=NEwS3AJhc7Wg7f!$6W*!@cf{6FnLKf31y+w0K| z_|rS!&+WjULmlXu(19L%2lxj%(38>u|AG$qKkWdY+JXNscECTl1OCzu{HX%J8@kTD z_5pFB@iMvtJ-_LIzjp`twhr{%(gA*92ly{Lz?XMmH@5?PMhE!59pv-L4(vYP0lv5c z{O>xzmvvzG7ajQ7y#qb*9q>=+0AJGqeoY7Z2Lazz>#Y@)mOxU|%=P+8_)om2w1ns| z{uS^Kx&S_)^lU0EA$yp=7*>0ed847?CpR#T}hD_v3M_m{2rYs*VlE?ZTlEw8A$T3ffIs(igLEh)X4 z`W7!=vTC)qxNQ9@zXpLy_;U5C)iB_%s;(>t=aTB`vMRs92Bg1Y8EO8C)!K6KmuheV zo)EXXtXwmkDy=AAE2bm@Lr+;%Re8l?(*3I{${E0ls*0M*YSzlDVQ9G}$ZG$xiW+!c zSpy6Ftk%|)tzj;fm#(g;E;GV}6N{0Tva0eW;;_G>X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vooD zdZh;a1iC+@;xemg;<#)%jo3TXJbc)4K}ReJPey%;%L=$zr)wrcA8Xum}ts21p$_H?T0>T9oAL}wXS zA#(YnUHw6=OCc*BpmUqq|J2an-~nRs^(a2sas_GNsN@aXR^PbZUB6`=S?;>*2H*do%f4IA3m$KCkqHJjJFCXwiTX+CtDj@r(r z=yYk94s1@k${g6A(bCY zWCNzSY4!a9(uKp@Lx-PN3d*P{S&8EV$#VgPy@aWyG?gS1`C_FQoq`+)3NO1)N2~`Z zcnsXIFlM8Wv0I1YIgkAlD7V^q0FBitVt4<5B3S=CeJ%S9Qs z{iJA+Cl$@GT*=eWyjTxq$(M6(qEt#3sd7~~!M0=yLuDVco`Bi~@058@xR_5#=O$7q zKJz}C(qAA^Jig=Lb&9Aja#$G(RA{K; zLn-67Y~^(?n{$Us>69fCoCjl1b|55cf1%IqP0*4Zs?x4Yd6@{#G_UOQ^5HYNGJCw@ zPGeCSi@~Zv9!`|1EdfiZ%I0X*(iJ$9>`!F_;#`-$!6ery+jN}^YRu-;Vnko%%5Vwr zF7pz@IU1~b-twx)V87?kzC<=$C3&afNtL;k-s=_;<^Gc8ZX9;E$!=op0MFo(7MluW zYo!P_VmOfeuAAJSaCM=tq|TO7**@AOP!@5>bXt0qgI9)12G^z4&+HR2)xxjB!>e^U zJD47(9ga*cwTfahRJn$x%R|9n@-BdOHniawmWA3a_2;RGg_Dk54(6yzv`oI}8#Z6@ h(z8WZE(%WhKq2k+@{YiBb`fnY_XmPQTYx|!{SSBq_+|hA literal 0 HcmV?d00001 diff --git a/sdc-os-chef/scripts/k8s/etc/bash_completion.d/nsenter b/sdc-os-chef/scripts/k8s/etc_nsenter similarity index 100% rename from sdc-os-chef/scripts/k8s/etc/bash_completion.d/nsenter rename to sdc-os-chef/scripts/k8s/etc_nsenter diff --git a/sdc-os-chef/scripts/k8s/kubernetes_run.sh b/sdc-os-chef/scripts/k8s/kubernetes_run.sh index fd9de2e181..7a73c2af3b 100644 --- a/sdc-os-chef/scripts/k8s/kubernetes_run.sh +++ b/sdc-os-chef/scripts/k8s/kubernetes_run.sh @@ -52,8 +52,18 @@ status $? print_header "Dependency - Install ..." echo "[INFO] Install - nsenter" # Use pre compiled nsenter: -sudo cp bin/nsenter /usr/local/bin/nsenter -sudo cp etc/bash_completion.d/nsenter /etc/bash_completion.d/nsenter +if [ -f bin_nsenter ]; then + sudo cp bin_nsenter /usr/local/bin/nsenter +else + echo "[ERROR] File [bin_nsenter] is missing" +fi + +if [ -f etc_nsenter ]; then + sudo cp etc_nsenter /etc/bash_completion.d/nsenter +else + echo "[ERROR] File [etc_nsenter] is missing" +fi + ## In order to build the nsenter use the below instructions: ##./build_nsenter_exec.sh @@ -75,3 +85,12 @@ print_header "SDC - Deploy Pods ..." sh ./deploy_k8s_sdc.sh status $? + +#################### +# SDC LOGS Tree # +#################### +print_header "SDC - Deploy Pods ..." +mkdir -p /dockerdata-nfs/onap/sdc/logs//BE/SDC/SDC-BE +mkdir -p /dockerdata-nfs/onap/sdc/logs/FE/SDC/SDC-FE +mkdir -p /dockerdata-nfs/onap/sdc/logs/ONBOARD/SDC/ONBOARD-BE +chmod -R 777 /dockerdata-nfs/onap/sdc/logs/* diff --git a/sdc-os-chef/sdc-os-common/.gitignore b/sdc-os-chef/sdc-os-common/.gitignore deleted file mode 100644 index febee30092..0000000000 --- a/sdc-os-chef/sdc-os-common/.gitignore +++ /dev/null @@ -1,21 +0,0 @@ -.vagrant -*~ -*# -.#* -\#*# -.*.sw[a-z] -*.un~ - -# Bundler -Gemfile.lock -bin/* -.bundle/* - -# test kitchen -.kitchen/ -.kitchen.local.yml - -# Chef -Berksfile.lock -.zero-knife.rb -Policyfile.lock.json diff --git a/sdc-os-chef/sdc-os-common/.kitchen.yml b/sdc-os-chef/sdc-os-common/.kitchen.yml deleted file mode 100644 index 8df250ec0c..0000000000 --- a/sdc-os-chef/sdc-os-common/.kitchen.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- -driver: - name: vagrant - -provisioner: - name: chef_zero - # You may wish to disable always updating cookbooks in CI or other testing environments. - # For example: - # always_update_cookbooks: <%= !ENV['CI'] %> - always_update_cookbooks: true - -verifier: - name: inspec - -platforms: - - name: ubuntu-16.04 - - name: centos-7.3 - -suites: - - name: default - run_list: - - recipe[sdc-os-common::default] - verifier: - inspec_tests: - - test/smoke/default - attributes: diff --git a/sdc-os-chef/sdc-os-common/Berksfile b/sdc-os-chef/sdc-os-common/Berksfile deleted file mode 100644 index 34fea2166b..0000000000 --- a/sdc-os-chef/sdc-os-common/Berksfile +++ /dev/null @@ -1,3 +0,0 @@ -source 'https://supermarket.chef.io' - -metadata diff --git a/sdc-os-chef/sdc-os-common/README.md b/sdc-os-chef/sdc-os-common/README.md deleted file mode 100644 index eada81117d..0000000000 --- a/sdc-os-chef/sdc-os-common/README.md +++ /dev/null @@ -1,4 +0,0 @@ -# sdc-os-common - -TODO: Enter the cookbook description here. - diff --git a/sdc-os-chef/sdc-os-common/chefignore b/sdc-os-chef/sdc-os-common/chefignore deleted file mode 100644 index 38e7379bb8..0000000000 --- a/sdc-os-chef/sdc-os-common/chefignore +++ /dev/null @@ -1,107 +0,0 @@ -# Put files/directories that should be ignored in this file when uploading -# to a chef-server or supermarket. -# Lines that start with '# ' are comments. - -# OS generated files # -###################### -.DS_Store -Icon? -nohup.out -ehthumbs.db -Thumbs.db - -# SASS # -######## -.sass-cache - -# EDITORS # -########### -\#* -.#* -*~ -*.sw[a-z] -*.bak -REVISION -TAGS* -tmtags -*_flymake.* -*_flymake -*.tmproj -.project -.settings -mkmf.log - -## COMPILED ## -############## -a.out -*.o -*.pyc -*.so -*.com -*.class -*.dll -*.exe -*/rdoc/ - -# Testing # -########### -.watchr -.rspec -spec/* -spec/fixtures/* -test/* -features/* -examples/* -Guardfile -Procfile -.kitchen* -.rubocop.yml -spec/* -Rakefile -.travis.yml -.foodcritic -.codeclimate.yml - -# SCM # -####### -.git -*/.git -.gitignore -.gitmodules -.gitconfig -.gitattributes -.svn -*/.bzr/* -*/.hg/* -*/.svn/* - -# Berkshelf # -############# -Berksfile -Berksfile.lock -cookbooks/* -tmp - -# Policyfile # -############## -Policyfile.rb -Policyfile.lock.json - -# Cookbooks # -############# -CONTRIBUTING* -CHANGELOG* -TESTING* -MAINTAINERS.toml - -# Strainer # -############ -Colanderfile -Strainerfile -.colander -.strainer - -# Vagrant # -########### -.vagrant -Vagrantfile diff --git a/sdc-os-chef/sdc-os-common/metadata.rb b/sdc-os-chef/sdc-os-common/metadata.rb deleted file mode 100644 index ff2506dfc9..0000000000 --- a/sdc-os-chef/sdc-os-common/metadata.rb +++ /dev/null @@ -1,20 +0,0 @@ -name 'sdc-os-common' -maintainer 'The Authors' -maintainer_email 'you@example.com' -license 'All Rights Reserved' -description 'Installs/Configures sdc-os-common' -long_description 'Installs/Configures sdc-os-common' -version '0.1.0' -chef_version '>= 12.1' if respond_to?(:chef_version) - -# The `issues_url` points to the location where issues for this cookbook are -# tracked. A `View Issues` link will be displayed on this cookbook's page when -# uploaded to a Supermarket. -# -# issues_url 'https://github.com//sdc-os-common/issues' - -# The `source_url` points to the development reposiory for this cookbook. A -# `View Source` link will be displayed on this cookbook's page when uploaded to -# a Supermarket. -# -# source_url 'https://github.com//sdc-os-common' diff --git a/sdc-os-chef/sdc-os-common/recipes/default.rb b/sdc-os-chef/sdc-os-common/recipes/default.rb deleted file mode 100644 index 4799ba4470..0000000000 --- a/sdc-os-chef/sdc-os-common/recipes/default.rb +++ /dev/null @@ -1,5 +0,0 @@ -# -# Cookbook:: sdc-os-common -# Recipe:: default -# -# Copyright:: 2017, The Authors, All Rights Reserved. diff --git a/sdc-os-chef/sdc-os-common/spec/spec_helper.rb b/sdc-os-chef/sdc-os-common/spec/spec_helper.rb deleted file mode 100644 index 1dd5126bf6..0000000000 --- a/sdc-os-chef/sdc-os-common/spec/spec_helper.rb +++ /dev/null @@ -1,2 +0,0 @@ -require 'chefspec' -require 'chefspec/berkshelf' diff --git a/sdc-os-chef/sdc-os-common/spec/unit/recipes/default_spec.rb b/sdc-os-chef/sdc-os-common/spec/unit/recipes/default_spec.rb deleted file mode 100644 index bd9841f76e..0000000000 --- a/sdc-os-chef/sdc-os-common/spec/unit/recipes/default_spec.rb +++ /dev/null @@ -1,22 +0,0 @@ -# -# Cookbook:: sdc-os-common -# Spec:: default -# -# Copyright:: 2017, The Authors, All Rights Reserved. - -require 'spec_helper' - -describe 'sdc-os-common::default' do - context 'When all attributes are default, on an Ubuntu 16.04' do - let(:chef_run) do - # for a complete list of available platforms and versions see: - # https://github.com/customink/fauxhai/blob/master/PLATFORMS.md - runner = ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '16.04') - runner.converge(described_recipe) - end - - it 'converges successfully' do - expect { chef_run }.to_not raise_error - end - end -end diff --git a/sdc-os-chef/sdc-os-common/templates/default/BE-configuration.yaml.erb b/sdc-os-chef/sdc-os-common/templates/default/BE-configuration.yaml.erb deleted file mode 100644 index c1ba04d12d..0000000000 --- a/sdc-os-chef/sdc-os-common/templates/default/BE-configuration.yaml.erb +++ /dev/null @@ -1,634 +0,0 @@ -identificationHeaderFields: - - HTTP_IV_USER - - HTTP_CSP_FIRSTNAME - - HTTP_CSP_LASTNAME - - HTTP_IV_REMOTE_ADDRESS - - HTTP_CSP_WSTYPE - - -# catalog backend hostname -beFqdn: <%= @host_ip %> - -# catalog backend http port -beHttpPort: <%= @catalog_port %> - -# catalog backend http context -beContext: /sdc/rest/config/get - -# catalog backend protocol -beProtocol: http - -# catalog backend ssl port -beSslPort: <%= @ssl_port %> -version: 1.0 -released: 2012-11-30 -toscaConformanceLevel: 5.0 -minToscaConformanceLevel: 3.0 - -titanCfgFile: <%= @titan_Path %>/titan.properties -titanInMemoryGraph: false -titanLockTimeout: 1800 -# The interval to try and reconnect to titan DB when it is down during ASDC startup: -titanReconnectIntervalInSeconds: 3 - -# The read timeout towards Titan DB when health check is invoked: -titanHealthCheckReadTimeout: 1 - -# The interval to try and reconnect to Elasticsearch when it is down during ASDC startup: - -esReconnectIntervalInSeconds: 3 -uebHealthCheckReconnectIntervalInSeconds: 15 -uebHealthCheckReadTimeout: 4 - -# Protocols -protocols: - - http - - https - -# Default imports -defaultImports: - - nodes: - file: nodes.yml - - datatypes: - file: data.yml - - capabilities: - file: capabilities.yml - - relationships: - file: relationships.yml - - groups: - file: groups.yml - - policies: - file: policies.yml -# Users -users: - tom: passwd - bob: passwd - - -cassandraConfig: - cassandraHosts: [<%= @cassandra_ip %>] - localDataCenter: <%= @dc1 %> - reconnectTimeout : 30000 - authenticate: true - username: asdc_user - password: Aa1234%^! - ssl: false - truststorePath : /config/.truststore - truststorePassword : Aa123456 - keySpaces: - - { name: dox, replicationStrategy: NetworkTopologyStrategy, replicationInfo: ['<%= @DC_NAME %>','<%= @rep_factor %>']} - - { name: sdcaudit, replicationStrategy: NetworkTopologyStrategy, replicationInfo: ['<%= @DC_NAME %>','<%= @rep_factor %>']} - - { name: sdcartifact, replicationStrategy: NetworkTopologyStrategy, replicationInfo: ['<%= @DC_NAME %>','<%= @rep_factor %>']} - - { name: sdccomponent, replicationStrategy: NetworkTopologyStrategy, replicationInfo: ['<%= @DC_NAME %>','<%= @rep_factor %>']} - - { name: sdcrepository, replicationStrategy: NetworkTopologyStrategy, replicationInfo: ['<%= @dc1 %>', '<%= @rep_factor %>']} - - { name: sdcrepository, replicationStrategy: NetworkTopologyStrategy, replicationInfo: ['<%= @dc1 %>', '<%= @rep_factor %>', '<%= @dc2 %>', '<%= @rep_factor %>']} - -#Application-specific settings of ES -elasticSearch: - # Mapping of index prefix to time-based frame. For example, if below is configured: - # - # - indexPrefix: auditingevents - # creationPeriod: minute - # - # then ES object of type which is mapped to "auditingevents-*" template, and created on 2015-12-23 13:24:54, will enter "auditingevents-2015-12-23-13-24" index. - # Another object created on 2015-12-23 13:25:54, will enter "auditingevents-2015-12-23-13-25" index. - # If creationPeriod: month, both of the above will enter "auditingevents-2015-12" index. - # - # PLEASE NOTE: the timestamps are created in UTC/GMT timezone! This is needed so that timestamps will be correctly presented in Kibana. - # - # Legal values for creationPeriod - year, month, day, hour, minute, none (meaning no time-based behaviour). - # - # If no creationPeriod is configured for indexPrefix, default behavour is creationPeriod: month. - - indicesTimeFrequency: - - indexPrefix: auditingevents - creationPeriod: month - - indexPrefix: monitoring_events - creationPeriod: month -artifactTypes: - - CHEF - - PUPPET - - SHELL - - YANG - - YANG_XML - - HEAT - - BPEL - - DG_XML - - MURANO_PKG - - WORKFLOW - - NETWORK_CALL_FLOW - - TOSCA_TEMPLATE - - TOSCA_CSAR - - AAI_SERVICE_MODEL - - AAI_VF_MODEL - - AAI_VF_MODULE_MODEL - - AAI_VF_INSTANCE_MODEL - - OTHER - - SNMP_POLL - - SNMP_TRAP - - GUIDE - - -licenseTypes: - - User - - Installation - - CPU - -#Deployment artifacts placeHolder -resourceTypes: &allResourceTypes - - VFC - - CP - - VL - - VF - - VFCMT - - Abstract - - CVFC - -# validForResourceTypes usage -# validForResourceTypes: -# - VF -# - VL -deploymentResourceArtifacts: - - -deploymentResourceInstanceArtifacts: - heatEnv: - displayName: "HEAT ENV" - type: HEAT_ENV - description: "Auto-generated HEAT Environment deployment artifact" - fileExtension: "env" - VfHeatEnv: - displayName: "VF HEAT ENV" - type: HEAT_ENV - description: "VF Auto-generated HEAT Environment deployment artifact" - fileExtension: "env" - -#tosca artifacts placeholders -toscaArtifacts: - assetToscaTemplate: - artifactName: -template.yml - displayName: Tosca Template - type: TOSCA_TEMPLATE - description: TOSCA representation of the asset - assetToscaCsar: - artifactName: -csar.csar - displayName: Tosca Model - type: TOSCA_CSAR - description: TOSCA definition package of the asset - -#Informational artifacts placeHolder -excludeResourceCategory: - - Generic -excludeResourceType: - - PNF -informationalResourceArtifacts: - features: - displayName: Features - type: OTHER - capacity: - displayName: Capacity - type: OTHER - vendorTestResult: - displayName: Vendor Test Result - type: OTHER - testScripts: - displayName: Test Scripts - type: OTHER - CloudQuestionnaire: - displayName: Cloud Questionnaire (completed) - type: OTHER - HEATTemplateFromVendor: - displayName: HEAT Template from Vendor - type: HEAT - resourceSecurityTemplate: - displayName: Resource Security Template - type: OTHER - -excludeServiceCategory: - -informationalServiceArtifacts: - serviceArtifactPlan: - displayName: Service Artifact Plan - type: OTHER - summaryOfImpactsToECOMPElements: - displayName: Summary of impacts to ECOMP elements,OSSs, BSSs - type: OTHER - controlLoopFunctions: - displayName: Control Loop Functions - type: OTHER - dimensioningInfo: - displayName: Dimensioning Info - type: OTHER - affinityRules: - displayName: Affinity Rules - type: OTHER - operationalPolicies: - displayName: Operational Policies - type: OTHER - serviceSpecificPolicies: - displayName: Service-specific Policies - type: OTHER - engineeringRules: - displayName: Engineering Rules (ERD) - type: OTHER - distributionInstructions: - displayName: Distribution Instructions - type: OTHER - certificationTestResults: - displayName: TD Certification Test Results - type: OTHER - deploymentVotingRecord: - displayName: Deployment Voting Record - type: OTHER - serviceQuestionnaire: - displayName: Service Questionnaire - type: OTHER - serviceSecurityTemplate: - displayName: Service Security Template - type: OTHER - -serviceApiArtifacts: - configuration: - displayName: Configuration - type: OTHER - instantiation: - displayName: Instantiation - type: OTHER - monitoring: - displayName: Monitoring - type: OTHER - reporting: - displayName: Reporting - type: OTHER - logging: - displayName: Logging - type: OTHER - testing: - displayName: Testing - type: OTHER - - -additionalInformationMaxNumberOfKeys: 50 - -systemMonitoring: - enabled: true - isProxy: false - probeIntervalInSeconds: 15 -defaultHeatArtifactTimeoutMinutes: 60 - -serviceDeploymentArtifacts: - YANG_XML: - acceptedTypes: - - xml - VNF_CATALOG: - acceptedTypes: - - xml - MODEL_INVENTORY_PROFILE: - acceptedTypes: - - xml - MODEL_QUERY_SPEC: - acceptedTypes: - - xml - AAI_SERVICE_MODEL: - acceptedTypes: - - xml - AAI_VF_MODULE_MODEL: - acceptedTypes: - - xml - AAI_VF_INSTANCE_MODEL: - acceptedTypes: - - xml - UCPE_LAYER_2_CONFIGURATION: - acceptedTypes: - - xml - OTHER: - acceptedTypes: - - -resourceDeploymentArtifacts: - HEAT: - acceptedTypes: - - yaml - - yml - validForResourceTypes: *allResourceTypes - HEAT_VOL: - acceptedTypes: - - yaml - - yml - validForResourceTypes: *allResourceTypes - HEAT_NET: - acceptedTypes: - - yaml - - yml - validForResourceTypes: *allResourceTypes - HEAT_NESTED: - acceptedTypes: - - yaml - - yml - validForResourceTypes: *allResourceTypes - HEAT_ARTIFACT: - acceptedTypes: - validForResourceTypes: *allResourceTypes - YANG_XML: - acceptedTypes: - - xml - validForResourceTypes: *allResourceTypes - VNF_CATALOG: - acceptedTypes: - - xml - validForResourceTypes: *allResourceTypes - VF_LICENSE: - acceptedTypes: - - xml - validForResourceTypes: *allResourceTypes - VENDOR_LICENSE: - acceptedTypes: - - xml - validForResourceTypes: *allResourceTypes - MODEL_INVENTORY_PROFILE: - acceptedTypes: - - xml - validForResourceTypes: *allResourceTypes - MODEL_QUERY_SPEC: - acceptedTypes: - - xml - validForResourceTypes: *allResourceTypes - LIFECYCLE_OPERATIONS: - acceptedTypes: - - yaml - - yml - validForResourceTypes: - - VF - - VFC - VES_EVENTS: - acceptedTypes: - - yaml - - yml - validForResourceTypes: *allResourceTypes - PERFORMANCE_COUNTER: - acceptedTypes: - - csv - validForResourceTypes: *allResourceTypes - APPC_CONFIG: - acceptedTypes: - validForResourceTypes: - - VF - #DCAE Artifacts - DCAE_TOSCA: - acceptedTypes: - - yml - - yaml - validForResourceTypes: - - VF - - VFCMT - DCAE_JSON: - acceptedTypes: - - json - validForResourceTypes: - - VF - - VFCMT - DCAE_POLICY: - acceptedTypes: - - emf - validForResourceTypes: - - VF - - VFCMT - DCAE_DOC: - acceptedTypes: - validForResourceTypes: - - VF - - VFCMT - DCAE_EVENT: - acceptedTypes: - validForResourceTypes: - - VF - - VFCMT -#AAI Artifacts - AAI_VF_MODEL: - acceptedTypes: - - xml - validForResourceTypes: - - VF - AAI_VF_MODULE_MODEL: - acceptedTypes: - - xml - validForResourceTypes: - - VF - OTHER: - acceptedTypes: - validForResourceTypes: *allResourceTypes - SNMP_POLL: - acceptedTypes: - validForResourceTypes: *allResourceTypes - SNMP_TRAP: - acceptedTypes: - validForResourceTypes: *allResourceTypes - -resourceInstanceDeploymentArtifacts: - HEAT_ENV: - acceptedTypes: - - env - VF_MODULES_METADATA: - acceptedTypes: - - json - VES_EVENTS: - acceptedTypes: - - yaml - - yml - PERFORMANCE_COUNTER: - acceptedTypes: - - csv -#DCAE_VF Instance Artifacts - DCAE_INVENTORY_TOSCA: - acceptedTypes: - - yml - - yaml - DCAE_INVENTORY_JSON: - acceptedTypes: - - json - DCAE_INVENTORY_POLICY: - acceptedTypes: - - emf - DCAE_INVENTORY_DOC: - acceptedTypes: - DCAE_INVENTORY_BLUEPRINT: - acceptedTypes: - DCAE_INVENTORY_EVENT: - acceptedTypes: - SNMP_POLL: - acceptedTypes: - validForResourceTypes: *allResourceTypes - SNMP_TRAP: - acceptedTypes: - validForResourceTypes: *allResourceTypes - -resourceInformationalArtifacts: - CHEF: - acceptedTypes: - validForResourceTypes: *allResourceTypes - PUPPET: - acceptedTypes: - validForResourceTypes: *allResourceTypes - SHELL: - acceptedTypes: - validForResourceTypes: *allResourceTypes - YANG: - acceptedTypes: - validForResourceTypes: *allResourceTypes - YANG_XML: - acceptedTypes: - validForResourceTypes: *allResourceTypes - HEAT: - acceptedTypes: - validForResourceTypes: *allResourceTypes - BPEL: - acceptedTypes: - validForResourceTypes: *allResourceTypes - DG_XML: - acceptedTypes: - validForResourceTypes: *allResourceTypes - MURANO_PKG: - acceptedTypes: - validForResourceTypes: *allResourceTypes - OTHER: - acceptedTypes: - validForResourceTypes: - - VFC - - CVFC - - CP - - VL - - VF - - VFCMT - - Abstract - - PNF - SNMP_POLL: - acceptedTypes: - validForResourceTypes: *allResourceTypes - SNMP_TRAP: - acceptedTypes: - validForResourceTypes: *allResourceTypes - GUIDE: - acceptedTypes: - validForResourceTypes: - - VF - - VFC - - CVFC - -resourceInformationalDeployedArtifacts: - - -requirementsToFulfillBeforeCert: - -capabilitiesToConsumeBeforeCert: - -unLoggedUrls: - - /sdc2/rest/healthCheck - -cleanComponentsConfiguration: - cleanIntervalInMinutes: 1440 - componentsToClean: - - Resource - - Service - -artifactsIndex: resources - -heatEnvArtifactHeader: - "" -heatEnvArtifactFooter: - "" - -onboarding: - protocol: http - host: <%= @host_ip %> - port: <%= @catalog_port %> - downloadCsarUri: "/onboarding-api/v1.0/vendor-software-products/packages" - healthCheckUri: "/onboarding-api/v1.0/healthcheck" - -dcae: - protocol: http - host: <%= @host_ip %> - port: <%= @catalog_port %> - healthCheckUri: "/dcae/healthCheck" - - -# #GSS IDNS -switchoverDetector: - gBeFqdn: - gFeFqdn: - beVip: 1.2.3.4 - feVip: 1.2.3.4 - beResolveAttempts: 3 - feResolveAttempts: 3 - enabled: false - interval: 60 - changePriorityUser: ecompasdc - changePriorityPassword: ecompasdc123 - publishNetworkUrl: - publishNetworkBody: '{"note":"comment"}' - groups: - beSet: { changePriorityUrl: "", changePriorityBody: '{"name":"","uri":"","no_ad_redirection":false,"v4groups":{"failover_groups":["","","failover_policy":["FAILALL"]},"comment":"","intended_app_proto":"DNS"}'} - feSet: { changePriorityUrl: "", changePriorityBody: '{"name":"","uri":"","no_ad_redirection":false,"v4groups":{"failover_groups":["",""],"failover_policy":["FAILALL"]},"comment":"","intended_app_proto":"DNS"}'} - -applicationL1Cache: - datatypes: - enabled: true - firstRunDelay: 10 - pollIntervalInSec: 60 - -applicationL2Cache: - enabled: false - catalogL1Cache: - enabled: false - resourcesSizeInCache: 300 - servicesSizeInCache: 200 - productsSizeInCache: 100 - queue: - syncIntervalInSecondes: 43200 - waitOnShutDownInMinutes: 10 - numberOfCacheWorkers: 4 - -toscaValidators: - stringMaxLength: 2500 - -disableAudit: false - -vfModuleProperties: - min_vf_module_instances: - forBaseModule: 1 - forNonBaseModule: 0 - max_vf_module_instances: - forBaseModule: 1 - forNonBaseModule: - initial_count: - forBaseModule: 1 - forNonBaseModule: 0 - vf_module_type: - forBaseModule: Base - forNonBaseModule: Expansion - -genericAssetNodeTypes: - VFC: org.openecomp.resource.abstract.nodes.VFC - CVFC: org.openecomp.resource.abstract.nodes.VFC - VF : org.openecomp.resource.abstract.nodes.VF - PNF: org.openecomp.resource.abstract.nodes.PNF - Service: org.openecomp.resource.abstract.nodes.service - -workloadContext: Production - -environmentContext: - defaultValue: General_Revenue-Bearing - validValues: - - Critical_Revenue-Bearing - - Vital_Revenue-Bearing - - Essential_Revenue-Bearing - - Important_Revenue-Bearing - - Needed_Revenue-Bearing - - Useful_Revenue-Bearing - - General_Revenue-Bearing - - Critical_Non-Revenue - - Vital_Non-Revenue - - Essential_Non-Revenue - - Important_Non-Revenue - - Needed_Non-Revenue - - Useful_Non-Revenue - - General_Non-Revenue diff --git a/sdc-os-chef/sdc-os-common/test/smoke/default/default_test.rb b/sdc-os-chef/sdc-os-common/test/smoke/default/default_test.rb deleted file mode 100644 index a1f2595aab..0000000000 --- a/sdc-os-chef/sdc-os-common/test/smoke/default/default_test.rb +++ /dev/null @@ -1,18 +0,0 @@ -# # encoding: utf-8 - -# Inspec test for recipe sdc-os-common::default - -# The Inspec reference, with examples and extensive documentation, can be -# found at http://inspec.io/docs/reference/resources/ - -unless os.windows? - # This is an example test, replace with your own test. - describe user('root'), :skip do - it { should exist } - end -end - -# This is an example test, replace it with your own test. -describe port(80), :skip do - it { should_not be_listening } -end diff --git a/services/activity-spec/pom.xml b/services/activity-spec/pom.xml index 2b3a82a33a..bb0ccb7e5c 100644 --- a/services/activity-spec/pom.xml +++ b/services/activity-spec/pom.xml @@ -25,7 +25,7 @@ 2.1.1 3.1.0 3.0.2 - 0.24.0 + 0.23.0 1.10.19 4.1.3.RELEASE diff --git a/test-apis-ci/pom.xml b/test-apis-ci/pom.xml index c998a28ff1..65974c61ac 100644 --- a/test-apis-ci/pom.xml +++ b/test-apis-ci/pom.xml @@ -562,7 +562,6 @@ ${project.basedir}/sdc-api-tests ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest diff --git a/test-apis-ci/sdc-api-tests/chef-repo/cookbooks/sdc-api-tests/templates/default/sdc-sanity.yaml.erb b/test-apis-ci/sdc-api-tests/chef-repo/cookbooks/sdc-api-tests/templates/default/sdc-sanity.yaml.erb index 8dde3cdefe..3684b38e32 100644 --- a/test-apis-ci/sdc-api-tests/chef-repo/cookbooks/sdc-api-tests/templates/default/sdc-sanity.yaml.erb +++ b/test-apis-ci/sdc-api-tests/chef-repo/cookbooks/sdc-api-tests/templates/default/sdc-sanity.yaml.erb @@ -6,6 +6,14 @@ catalogFeHost: <%= @webportal_ip %> catalogFePort: <%= @webportal_port %> catalogBeHost: <%= @catalogBE_ip %> catalogBePort: <%= @catalogBE_port %> +onboardingBeHost: <%= node['ONBOARDING_BE_VIP'] %> +<% if node[:disableHttp] -%> +sdcHttpMethod: https +onboardingBePort: <%= node['ONBOARDING_BE'][:https_port] %> +<% else %> +sdcHttpMethod: http +onboardingBePort: <%= node['ONBOARDING_BE'][:http_port] %> +<% end -%> disributionClientPort: 8181 esPort: 9200 @@ -30,13 +38,6 @@ cassandraTruststorePassword : Aa123456 cassandraAuditKeySpace: sdcAudit cassandraArtifactKeySpace: sdcArtifact -# catalog backend protocol -<% if node[:disableHttp] -%> -sdcHttpMethod: https -<% else %> -sdcHttpMethod: http -<% end -%> - localDataCenter: DC-Automate01 stopOnClassFailure: false diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/config/Config.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/config/Config.java index 9f7043d509..f251c2dcae 100644 --- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/config/Config.java +++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/config/Config.java @@ -62,6 +62,9 @@ public class Config { private String catalogBePort; private String catalogBeTlsPort; + private String onboardingBeHost; + private String onboardingBePort; + private String neoDBusername; private String neoDBpassword; @@ -113,6 +116,22 @@ public class Config { super(); } + public String getOnboardingBePort() { + return onboardingBePort; + } + + public void setOnboardingBePort(String onboardingBePort) { + this.onboardingBePort = onboardingBePort; + } + + public String getOnboardingBeHost() { + return onboardingBeHost; + } + + public void setOnboardingBeHost(String onboardingBeHost) { + this.onboardingBeHost = onboardingBeHost; + } + public static class TestPackages { List packages; diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtillViaApis.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtillViaApis.java index 8637a9ba7a..5f9ec1bfc8 100644 --- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtillViaApis.java +++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtillViaApis.java @@ -235,7 +235,7 @@ public class OnboardingUtillViaApis { public static Either getVendorSoftwareProduct(String vspId, User user, Boolean validateState) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.GET_VENDOR_SOFTWARE_PRODUCT, config.getCatalogBeHost(), config.getCatalogBePort(), vspId); + String url = String.format(Urls.GET_VENDOR_SOFTWARE_PRODUCT, config.getOnboardingBeHost(), config.getOnboardingBePort(), vspId); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); headersMap.put(HttpHeaderEnum.X_ECOMP_REQUEST_ID_HEADER.getValue(), "123456"); diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtils.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtils.java index c1950dfd08..6c3a3c4cd4 100644 --- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtils.java +++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/OnboardingUtils.java @@ -136,7 +136,7 @@ public class OnboardingUtils { private static RestResponse actionOnComponent(String vspid, String body, String onboardComponent, User user, String componentVersion) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.ACTION_ON_COMPONENT, config.getCatalogBeHost(), config.getCatalogBePort(), onboardComponent, vspid, componentVersion); + String url = String.format(Urls.ACTION_ON_COMPONENT, config.getOnboardingBeHost(), config.getOnboardingBePort(), onboardComponent, vspid, componentVersion); String userId = user.getUserId(); Map headersMap = prepareHeadersMap(userId); diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorLicenseModelRestUtils.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorLicenseModelRestUtils.java index ec368df621..276897924f 100644 --- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorLicenseModelRestUtils.java +++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorLicenseModelRestUtils.java @@ -44,7 +44,7 @@ public class VendorLicenseModelRestUtils { private static RestResponse getVLMComponentByVersion(String vlmId, String vlmVersion, User user) throws Exception{ Config config = Utils.getConfig(); - String url = String.format(Urls.GET_VLM_COMPONENT_BY_VERSION, config.getCatalogBeHost(),config.getCatalogBePort(), vlmId,vlmVersion); + String url = String.format(Urls.GET_VLM_COMPONENT_BY_VERSION, config.getOnboardingBeHost(),config.getOnboardingBePort(), vlmId,vlmVersion); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -102,7 +102,7 @@ public class VendorLicenseModelRestUtils { private static RestResponse actionOnComponent(String vspid, String body, String onboardComponent, User user, String componentVersion) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.ACTION_ON_COMPONENT, config.getCatalogBeHost(), config.getCatalogBePort(), onboardComponent, vspid, componentVersion); + String url = String.format(Urls.ACTION_ON_COMPONENT, config.getOnboardingBeHost(), config.getOnboardingBePort(), onboardComponent, vspid, componentVersion); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -113,7 +113,7 @@ public class VendorLicenseModelRestUtils { private static RestResponse createMethodVendorLicense(String vendorId, String body, String onboardComponent, User user, String componentVersion) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_METHOD, config.getCatalogBeHost(), config.getCatalogBePort(), onboardComponent, vendorId, componentVersion); + String url = String.format(Urls.CREATE_METHOD, config.getOnboardingBeHost(), config.getOnboardingBePort(), onboardComponent, vendorId, componentVersion); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -145,7 +145,7 @@ public class VendorLicenseModelRestUtils { public static RestResponse createVendorLicenseModels_1(String name, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_VENDOR_LISENCE_MODELS, config.getCatalogBeHost(), config.getCatalogBePort()); + String url = String.format(Urls.CREATE_VENDOR_LISENCE_MODELS, config.getOnboardingBeHost(), config.getOnboardingBePort()); String userId = user.getUserId(); JSONObject jObject = new JSONObject(); @@ -164,7 +164,7 @@ public class VendorLicenseModelRestUtils { public static RestResponse createVendorLicenseAgreement_5(String vspid, String versionId, String featureGroupId, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_VENDOR_LISENCE_AGREEMENT, config.getCatalogBeHost(), config.getCatalogBePort(), vspid, versionId); + String url = String.format(Urls.CREATE_VENDOR_LISENCE_AGREEMENT, config.getOnboardingBeHost(), config.getOnboardingBePort(), vspid, versionId); String userId = user.getUserId(); JSONObject licenseTermpObject = new JSONObject(); @@ -188,7 +188,7 @@ public class VendorLicenseModelRestUtils { public static RestResponse createVendorLicenseFeatureGroups_4(String vspid, String versionId, String licenseKeyGroupId, String entitlementPoolId, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_VENDOR_LISENCE_FEATURE_GROUPS, config.getCatalogBeHost(), config.getCatalogBePort(), vspid, versionId); + String url = String.format(Urls.CREATE_VENDOR_LISENCE_FEATURE_GROUPS, config.getOnboardingBeHost(), config.getOnboardingBePort(), vspid, versionId); String userId = user.getUserId(); JSONObject jObject = new JSONObject(); @@ -209,7 +209,7 @@ public class VendorLicenseModelRestUtils { public static RestResponse createVendorEntitlementPool_3(String vspid, String versionId, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_VENDOR_LISENCE_ENTITLEMENT_POOL, config.getCatalogBeHost(), config.getCatalogBePort(), vspid, versionId); + String url = String.format(Urls.CREATE_VENDOR_LISENCE_ENTITLEMENT_POOL, config.getOnboardingBeHost(), config.getOnboardingBePort(), vspid, versionId); String userId = user.getUserId(); JSONObject jEntitlementMetricObject = new JSONObject(); @@ -249,7 +249,7 @@ public class VendorLicenseModelRestUtils { public static RestResponse createVendorKeyGroups_2(String vspid, String versionId, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_VENDOR_LISENCE_KEY_GROUPS, config.getCatalogBeHost(), config.getCatalogBePort(), vspid, versionId); + String url = String.format(Urls.CREATE_VENDOR_LISENCE_KEY_GROUPS, config.getOnboardingBeHost(), config.getOnboardingBePort(), vspid, versionId); String userId = user.getUserId(); JSONObject jOperationalScope = new JSONObject(); @@ -272,7 +272,7 @@ public class VendorLicenseModelRestUtils { public static RestResponse validateUpload(String vspid, User user, String vspVersion) throws Exception { String body = null; Config config = Utils.getConfig(); - String url = String.format(Urls.VALIDATE_UPLOAD, config.getCatalogBeHost(), config.getCatalogBePort(), vspid,vspVersion); + String url = String.format(Urls.VALIDATE_UPLOAD, config.getOnboardingBeHost(), config.getOnboardingBePort(), vspid,vspVersion); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); diff --git a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorSoftwareProductRestUtils.java b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorSoftwareProductRestUtils.java index 51b11da1b2..51e4923a1a 100644 --- a/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorSoftwareProductRestUtils.java +++ b/test-apis-ci/src/main/java/org/openecomp/sdc/ci/tests/utils/general/VendorSoftwareProductRestUtils.java @@ -124,7 +124,7 @@ public class VendorSoftwareProductRestUtils { private static RestResponse deleteArtifactByType(String componentInstanceId, VendorSoftwareProductObject vendorSoftwareProductObject, User user, CvfcTypeEnum snmpType) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.DELETE_AMDOCS_ARTIFACT_BY_TYPE, config.getCatalogBeHost(), config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), componentInstanceId, snmpType.getValue()); + String url = String.format(Urls.DELETE_AMDOCS_ARTIFACT_BY_TYPE, config.getOnboardingBeHost(), config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), componentInstanceId, snmpType.getValue()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -196,27 +196,27 @@ public class VendorSoftwareProductRestUtils { public static RestResponse uploadCvfcArtifact(String filepath, String cvfcType, User user, VendorSoftwareProductObject vendorSoftwareProductObject, String componentInstanceId) throws IOException { Config config = Utils.getConfig(); - String snmpPollUrl = String.format(Urls.UPLOAD_AMDOCS_ARTIFACT, config.getCatalogBeHost(),config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), componentInstanceId, cvfcType); + String snmpPollUrl = String.format(Urls.UPLOAD_AMDOCS_ARTIFACT, config.getOnboardingBeHost(),config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), componentInstanceId, cvfcType); return uploadFile(filepath, null, snmpPollUrl, user); } private static RestResponse uploadSnmpPollArtifact(String filepath, String zipArtifact, VendorSoftwareProductObject vendorSoftwareProductObject, User user, String componentInstanceId) throws IOException { Config config = Utils.getConfig(); - String snmpPollUrl = String.format(Urls.UPLOAD_SNMP_POLL_ARTIFACT, config.getCatalogBeHost(),config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), componentInstanceId); + String snmpPollUrl = String.format(Urls.UPLOAD_SNMP_POLL_ARTIFACT, config.getOnboardingBeHost(),config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), componentInstanceId); return uploadFile(filepath, zipArtifact, snmpPollUrl, user); } private static RestResponse uploadSnmpTrapArtifact(String filepath, String zipArtifact, VendorSoftwareProductObject vendorSoftwareProductObject, User user, String vspComponentId) throws IOException { Config config = Utils.getConfig(); - String snmpTrapUrl = String.format(Urls.UPLOAD_SNMP_POLL_ARTIFACT, config.getCatalogBeHost(),config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), vspComponentId); + String snmpTrapUrl = String.format(Urls.UPLOAD_SNMP_POLL_ARTIFACT, config.getOnboardingBeHost(),config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId(), vspComponentId); return uploadFile(filepath, zipArtifact, snmpTrapUrl, user); } private static RestResponse deleteSnmpArtifact(String componentId, String vspId, User user, SnmpTypeEnum snmpType) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.DELETE_AMDOCS_ARTIFACT_BY_TYPE, config.getCatalogBeHost(),config.getCatalogBePort(), vspId, componentId, snmpType.getValue()); + String url = String.format(Urls.DELETE_AMDOCS_ARTIFACT_BY_TYPE, config.getOnboardingBeHost(),config.getOnboardingBePort(), vspId, componentId, snmpType.getValue()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -248,7 +248,7 @@ public class VendorSoftwareProductRestUtils { private static RestResponse getVSPComponents(VendorSoftwareProductObject vendorSoftwareProductObject, User user) throws Exception{ Config config = Utils.getConfig(); - String url = String.format(Urls.GET_VSP_COMPONENTS, config.getCatalogBeHost(),config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.GET_VSP_COMPONENTS, config.getOnboardingBeHost(),config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); Map headersMap = OnboardingUtils.prepareHeadersMap(user.getUserId()); HttpRequest http = new HttpRequest(); @@ -267,7 +267,7 @@ public class VendorSoftwareProductRestUtils { private static RestResponse getVSPComponentByVersion(VendorSoftwareProductObject vendorSoftwareProductObject, User user) throws Exception{ Config config = Utils.getConfig(); - String url = String.format(Urls.GET_VSP_COMPONENT_BY_VERSION, config.getCatalogBeHost(),config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.GET_VSP_COMPONENT_BY_VERSION, config.getOnboardingBeHost(),config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -279,7 +279,7 @@ public class VendorSoftwareProductRestUtils { private static RestResponse actionOnComponent(String vspid, String body, String onboardComponent, User user, String componentVersion) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.ACTION_ON_COMPONENT, config.getCatalogBeHost(), config.getCatalogBePort(), onboardComponent, vspid, componentVersion); + String url = String.format(Urls.ACTION_ON_COMPONENT, config.getOnboardingBeHost(), config.getOnboardingBePort(), onboardComponent, vspid, componentVersion); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -291,7 +291,7 @@ public class VendorSoftwareProductRestUtils { public static Pair createNewVendorSoftwareProduct(ResourceReqDetails resourceReqDetails, String vspName, AmdocsLicenseMembers amdocsLicenseMembers, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_VENDOR_SOFTWARE_PRODUCT, config.getCatalogBeHost(), config.getCatalogBePort()); + String url = String.format(Urls.CREATE_VENDOR_SOFTWARE_PRODUCT, config.getOnboardingBeHost(), config.getOnboardingBePort()); String userId = user.getUserId(); VendorSoftwareProductObject vendorSoftwareProductObject = new VendorSoftwareProductObject(); LicensingData licensingData = new LicensingData(amdocsLicenseMembers.getVendorLicenseAgreementId(), Arrays.asList(amdocsLicenseMembers.getFeatureGroupId())); @@ -324,7 +324,7 @@ public class VendorSoftwareProductRestUtils { public static RestResponse validateUpload(VendorSoftwareProductObject vendorSoftwareProductObject, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.VALIDATE_UPLOAD, config.getCatalogBeHost(), config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.VALIDATE_UPLOAD, config.getOnboardingBeHost(), config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -336,7 +336,7 @@ public class VendorSoftwareProductRestUtils { public static RestResponse uploadHeatPackage(String filepath, String filename, VendorSoftwareProductObject vendorSoftwareProductObject, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.UPLOAD_HEAT_PACKAGE, config.getCatalogBeHost(), config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.UPLOAD_HEAT_PACKAGE, config.getOnboardingBeHost(), config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); return uploadFile(filepath, filename, url, user); } @@ -421,7 +421,7 @@ public class VendorSoftwareProductRestUtils { public static RestResponse checkinVendorSoftwareProduct(User user, VendorSoftwareProductObject vendorSoftwareProductObject) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.UPDATE_VSP, config.getCatalogBeHost(), config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.UPDATE_VSP, config.getOnboardingBeHost(), config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -467,7 +467,7 @@ public class VendorSoftwareProductRestUtils { private static RestResponse createMethodVendorSoftwareProduct(VendorSoftwareProductObject vendorSoftwareProductObject, String body, String onboardComponent, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.CREATE_METHOD, config.getCatalogBeHost(), config.getCatalogBePort(), onboardComponent, vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.CREATE_METHOD, config.getOnboardingBeHost(), config.getOnboardingBePort(), onboardComponent, vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); @@ -511,7 +511,7 @@ public class VendorSoftwareProductRestUtils { public static RestResponse updateVendorSoftwareProduct(VendorSoftwareProductObject vendorSoftwareProductObject, String body, User user) throws Exception { Config config = Utils.getConfig(); - String url = String.format(Urls.UPDATE_VSP, config.getCatalogBeHost(), config.getCatalogBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); + String url = String.format(Urls.UPDATE_VSP, config.getOnboardingBeHost(), config.getOnboardingBePort(), vendorSoftwareProductObject.getVspId(), vendorSoftwareProductObject.getComponentId()); String userId = user.getUserId(); Map headersMap = OnboardingUtils.prepareHeadersMap(userId); diff --git a/ui-ci/pom.xml b/ui-ci/pom.xml index 9317bccff7..94a8c99a19 100644 --- a/ui-ci/pom.xml +++ b/ui-ci/pom.xml @@ -427,7 +427,6 @@ ${project.basedir}/sdc-ui-tests ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest diff --git a/ui-ci/sdc-ui-tests/chef-repo/cookbooks/sdc-ui-tests/templates/default/sdc-sanity.yaml.erb b/ui-ci/sdc-ui-tests/chef-repo/cookbooks/sdc-ui-tests/templates/default/sdc-sanity.yaml.erb index 98c3dc8b7e..70063e00d5 100644 --- a/ui-ci/sdc-ui-tests/chef-repo/cookbooks/sdc-ui-tests/templates/default/sdc-sanity.yaml.erb +++ b/ui-ci/sdc-ui-tests/chef-repo/cookbooks/sdc-ui-tests/templates/default/sdc-sanity.yaml.erb @@ -1,12 +1,24 @@ url: http://<%= @webportal_ip %>:8285/sdc1 browser: firefox uiSimulator: true -sdcHttpMethod: http + catalogBeHost: <%= @catalogBE_ip %> catalogBePort: <%= @catalogBE_port %> catalogFeHost: <%= @webportal_ip %> catalogFePort: <%= @webportal_port %> +onboardingBeHost: <%= node['ONBOARDING_BE_VIP'] %> +<% if node[:disableHttp] -%> +sdcHttpMethod: https +onboardingBePort: <%= node['ONBOARDING_BE'][:https_port] %> +<% else %> +sdcHttpMethod: http +onboardingBePort: <%= node['ONBOARDING_BE'][:http_port] %> +<% end -%> + + + + esHost: <%= @ES_IP %> esPort: 9200 disributionClientHost: disClient diff --git a/utils/webseal-simulator/pom.xml b/utils/webseal-simulator/pom.xml index 4aa6fa4d7b..9cbee6cfbf 100644 --- a/utils/webseal-simulator/pom.xml +++ b/utils/webseal-simulator/pom.xml @@ -235,7 +235,6 @@ ${basedir}${file.separator}sdc-simulator ${docker.tag} - ${docker.latest.tag} ${parsedVersion.majorVersion}.${parsedVersion.minorVersion}-STAGING-latest -- 2.16.6