diff options
Diffstat (limited to 'cookbooks/aai-traversal/aai-traversal-config')
3 files changed, 21 insertions, 0 deletions
diff --git a/cookbooks/aai-traversal/aai-traversal-config/attributes/aaiEventDMaaPPublisher.rb b/cookbooks/aai-traversal/aai-traversal-config/attributes/aaiEventDMaaPPublisher.rb new file mode 100644 index 0000000..7d20b30 --- /dev/null +++ b/cookbooks/aai-traversal/aai-traversal-config/attributes/aaiEventDMaaPPublisher.rb @@ -0,0 +1,3 @@ +node.default["aai-traversal-config"]["AAI_DMAAP_PROTOCOL"] = 'http' +node.default["aai-traversal-config"]["AAI_DMAAP_HOST_PORT"] = 'localhost:3904' +node.default["aai-traversal-config"]["AAI_DMAAP_TOPIC_NAME"] = 'AAI-EVENT' diff --git a/cookbooks/aai-traversal/aai-traversal-config/recipes/aaiEventDMaaPPublisher.rb b/cookbooks/aai-traversal/aai-traversal-config/recipes/aaiEventDMaaPPublisher.rb new file mode 100644 index 0000000..6b66a6d --- /dev/null +++ b/cookbooks/aai-traversal/aai-traversal-config/recipes/aaiEventDMaaPPublisher.rb @@ -0,0 +1,14 @@ +['aaiEventDMaaPPublisher.properties'].each do |file| + template "#{node['aai-traversal-config']['PROJECT_HOME']}/bundleconfig/etc/appprops/#{file}" do + source "aai-traversal-app-config/aaiEventDMaaPPublisher.properties" + owner "aaiadmin" + group "aaiadmin" + mode "0644" + variables( +:AAI_DMAAP_PROTOCOL => node["aai-traversal-config"]["AAI_DMAAP_PROTOCOL"], +:AAI_DMAAP_HOST_PORT => node["aai-traversal-config"]["AAI_DMAAP_HOST_PORT"], +:AAI_DMAAP_TOPIC_NAME => node["aai-traversal-config"]["AAI_DMAAP_TOPIC_NAME"] + ) + end +end + diff --git a/cookbooks/aai-traversal/aai-traversal-config/templates/default/aai-traversal-app-config/aaiEventDMaaPPublisher.properties b/cookbooks/aai-traversal/aai-traversal-config/templates/default/aai-traversal-app-config/aaiEventDMaaPPublisher.properties new file mode 100644 index 0000000..8ad92cd --- /dev/null +++ b/cookbooks/aai-traversal/aai-traversal-config/templates/default/aai-traversal-app-config/aaiEventDMaaPPublisher.properties @@ -0,0 +1,4 @@ +Protocol=<%= @AAI_DMAAP_PROTOCOL %> +contenttype=application/json +host=<%= @AAI_DMAAP_HOST_PORT %> +topic=<%= @AAI_DMAAP_TOPIC_NAME %> |