From ba229230144f00d35d55e31a80ca2576bd831448 Mon Sep 17 00:00:00 2001 From: Tal Gitelman Date: Mon, 7 Aug 2017 17:59:54 +0300 Subject: [SDC] sync Change-Id: I150c22c816c52cc142e8d0f3c92e5df7ecea4e3c Signed-off-by: Tal Gitelman --- .../sdc-catalog-be/recipes/BE_1_cleanup_jettydir.rb | 9 --------- .../sdc-catalog-be/recipes/BE_4_setup_configuration.rb | 14 -------------- .../sdc-catalog-fe/recipes/FE_1_cleanup_jettydir.rb | 8 ++++++++ .../sdc-catalog-fe/recipes/FE_2_setup_configuration.rb | 14 ++++++++++++++ .../templates/default/FE-onboarding-configuration.yaml.erb | 5 +++++ sdc-os-chef/sdc-frontend/startup.sh | 2 +- 6 files changed, 28 insertions(+), 24 deletions(-) create mode 100644 sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb (limited to 'sdc-os-chef') diff --git a/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_1_cleanup_jettydir.rb b/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_1_cleanup_jettydir.rb index 70e4bd06fb..d989eb20bb 100644 --- a/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_1_cleanup_jettydir.rb +++ b/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_1_cleanup_jettydir.rb @@ -46,12 +46,3 @@ directory "BE_create_catalog-be" do mode '0755' action :create end - - -directory "BE_create_catalog-be" do - path "/var/lib/jetty/config/onboarding-be" - owner 'jetty' - group 'jetty' - mode '0755' - action :create -end \ No newline at end of file diff --git a/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_4_setup_configuration.rb b/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_4_setup_configuration.rb index 2dd430ce7a..d76e95de1d 100644 --- a/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_4_setup_configuration.rb +++ b/sdc-os-chef/sdc-backend/chef-repo/cookbooks/sdc-catalog-be/recipes/BE_4_setup_configuration.rb @@ -53,20 +53,6 @@ cookbook_file "ArtifactGenerator" do end -template "onboarding-be-config" do - path "/#{jetty_base}/config/onboarding-be/onboarding_configuration.yaml" - source "BE-onboarding-configuration.yaml.erb" - owner "m98835" - group "mechid" - mode "0755" - variables({ - :catalog_ip => node['HOST_IP'], - :catalog_port => node['BE'][:http_port], - :ssl_port => node['BE'][:https_port] -}) -end - - cookbook_file "/#{jetty_base}/etc/keystore" do source "keystore" owner "jetty" diff --git a/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_1_cleanup_jettydir.rb b/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_1_cleanup_jettydir.rb index 29301a9418..25983700d2 100644 --- a/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_1_cleanup_jettydir.rb +++ b/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_1_cleanup_jettydir.rb @@ -47,3 +47,11 @@ directory "FE_create_catalog-fe" do action :create end + +directory "FE_create_catalog-fe" do + path "/var/lib/jetty/config/onboarding-fe" + owner 'jetty' + group 'jetty' + mode '0755' + action :create +end \ No newline at end of file diff --git a/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb b/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb index 64d71768cd..165d10c1f2 100644 --- a/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb +++ b/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/recipes/FE_2_setup_configuration.rb @@ -11,3 +11,17 @@ template "catalog-fe-config" do :ssl_port => node['BE'][:https_port] }) end + + +template "onboarding-fe-config" do + path "/#{jetty_base}/config/onboarding-fe/onboarding_configuration.yaml" + source "FE-onboarding-configuration.yaml.erb" + owner "jetty" + group "jetty" + mode "0755" + variables({ + :catalog_ip => node['HOST_IP'], + :catalog_port => node['BE'][:http_port], + :ssl_port => node['BE'][:https_port] +}) +end \ No newline at end of file diff --git a/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb b/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb new file mode 100644 index 0000000000..4646661dfb --- /dev/null +++ b/sdc-os-chef/sdc-frontend/chef-repo/cookbooks/sdc-catalog-fe/templates/default/FE-onboarding-configuration.yaml.erb @@ -0,0 +1,5 @@ +notifications: + pollingIntervalMsec: 2000 + selectionSize: 100 + beHost: <%= @catalog_ip %> + beHttpPort: <%= @catalog_port %> \ No newline at end of file diff --git a/sdc-os-chef/sdc-frontend/startup.sh b/sdc-os-chef/sdc-frontend/startup.sh index ee6e7f528a..82f01576ef 100644 --- a/sdc-os-chef/sdc-frontend/startup.sh +++ b/sdc-os-chef/sdc-frontend/startup.sh @@ -5,7 +5,7 @@ cd /root/chef-solo echo "normal['HOST_IP'] = \"${HOST_IP}\"" > /root/chef-solo/cookbooks/sdc-catalog-fe/attributes/default.rb chef-solo -c solo.rb -E ${CHEFNAME} -sed -i '/^set -e/aJAVA_OPTIONS=\"-XX:MaxPermSize=256m -Xmx1500m -Dconfig.home=${JETTY_BASE}\/config -Dlog.home=${JETTY_BASE}\/logs -Dlogback.configurationFile=${JETTY_BASE}\/config\/catalog-fe\/logback.xml -Dconfiguration.yaml=${JETTY_BASE}\/config\/catalog-fe\/configuration.yaml\"' /docker-entrypoint.sh +sed -i '/^set -e/aJAVA_OPTIONS=\"-XX:MaxPermSize=256m -Xmx1500m -Dconfig.home=${JETTY_BASE}\/config -Dlog.home=${JETTY_BASE}\/logs -Dlogback.configurationFile=${JETTY_BASE}\/config\/catalog-fe\/logback.xml -Dconfiguration.yaml=${JETTY_BASE}\/config\/catalog-fe\/configuration.yaml -Donboarding_configuration.yaml=${JETTY_BASE}\/config\/onboarding-fe\/onboarding_configuration.yaml\"' /docker-entrypoint.sh sed -i '/^set -e/aTMPDIR=${JETTY_BASE}\/temp' /docker-entrypoint.sh cd /var/lib/jetty -- cgit 1.2.3-korg