diff --git a/jobs/metricsgateway/monit b/jobs/metricsgateway/monit deleted file mode 100644 index d69ade6980..0000000000 --- a/jobs/metricsgateway/monit +++ /dev/null @@ -1,5 +0,0 @@ -check process metricsgateway - with pidfile /var/vcap/sys/run/bpm/metricsgateway/metricsgateway.pid - start program "/var/vcap/jobs/bpm/bin/bpm start metricsgateway" - stop program "/var/vcap/jobs/bpm/bin/bpm stop metricsgateway" - group vcap \ No newline at end of file diff --git a/jobs/metricsgateway/spec b/jobs/metricsgateway/spec deleted file mode 100644 index cd9a204ec9..0000000000 --- a/jobs/metricsgateway/spec +++ /dev/null @@ -1,129 +0,0 @@ ---- -name: metricsgateway -templates: - bpm-pre-start.erb: bin/bpm-pre-start - bpm.yml.erb: config/bpm.yml - metricsgateway.yml.erb: config/metricsgateway.yml - - healthendpoint_ca.crt.erb: config/certs/healthendpoint/ca.crt - healthendpoint.crt.erb: config/certs/healthendpoint/server.crt - healthendpoint.key.erb: config/certs/healthendpoint/server.key - - metricsserver_client_ca.crt.erb: config/certs/metricsserver_client/ca.crt - metricsserver_client.crt.erb: config/certs/metricsserver_client/server.crt - metricsserver_client.key.erb: config/certs/metricsserver_client/server.key - - reverselogproxy_client_ca.crt.erb: config/certs/reverselogproxy_client/ca.crt - reverselogproxy_client.crt.erb: config/certs/reverselogproxy_client/client.crt - reverselogproxy_client.key.erb: config/certs/reverselogproxy_client/client.key - - policy_db_ca.crt.erb: config/certs/policy_db/ca.crt - policy_db.crt.erb: config/certs/policy_db/crt - policy_db.key.erb: config/certs/policy_db/key - -packages: - - openjdk-17 - - db - - metricsgateway - - common - -consumes: -- name: metricsserver - type: metricsserver - -properties: - autoscaler.metricsgateway.logging.level: - description: "The level of logging" - default: "info" - autoscaler.metricsgateway.envelop_chan_size: - description: "The channel size to transport envelope from nozzles to emitters" - default: 500 - autoscaler.metricsgateway.nozzle_count: - description: "The go-loggregator client count in a metricsgateway" - default: 3 - autoscaler.metricsgateway.app_manager.app_refresh_interval: - description: "The time interval to refresh cached application from policy database" - default: 60s - - autoscaler.metricsgateway.emitter.buffer_size: - description: "The size of channel in each emitter to store envelopes before sending to metricsserver" - default: 500 - autoscaler.metricsgateway.emitter.keep_alive_interval: - description: "The time interval of keep alive for the websocket connection between emitter and metricsserver" - default: 5s - autoscaler.metricsgateway.emitter.handshake_timeout: - description: "The timeout of webscoket handshake between emitter and metricsserver" - default: 1s - autoscaler.metricsgateway.emitter.max_setup_retry_count: - description: "The maximum retry times to set up a websocket connection between emitter and metricsserver" - default: 5 - autoscaler.metricsgateway.emitter.max_close_retry_count: - description: "The maximum retry times to close a websocket connection between emitter and metricsserver" - default: 5 - autoscaler.metricsgateway.emitter.retry_delay: - description: "The duration between two websocket retrying" - default: 10s - autoscaler.metricsgateway.emitter.metricsserver_client.cert: - description: "PEM-encoded tls client certificate to connect to metricsserver" - autoscaler.metricsgateway.emitter.metricsserver_client.key: - description: "PEM-encoded tls client key to connect to metricsserver" - autoscaler.metricsgateway.emitter.metricsserver_client.ca_cert: - description: "PEM-encoded ca certificate of metricsserver" - autoscaler.metricsgateway.nozzle.rlp_addr: - description: "The address of ReverseLogProxy" - autoscaler.metricsgateway.nozzle.shard_id: - description: "The shard id for nozzle to fetch envelopes from ReverseLogProxy" - default: "CF_AUTOSCALER" - autoscaler.metricsgateway.nozzle.loggregator_rlp_tls.cert: - description: "PEM-encoded tls client certificate to connect to ReverseLogProxy" - autoscaler.metricsgateway.nozzle.loggregator_rlp_tls.key: - description: "PEM-encoded tls client key to connect to ReverseLogProxy" - autoscaler.metricsgateway.nozzle.loggregator_rlp_tls.ca_cert: - description: "PEM-encoded ca certificate of ReverseLogProxy" - - autoscaler.policy_db.address: - description: "IP address on which the policydb server will listen" - default: "autoscalerpostgres.service.cf.internal" - autoscaler.policy_db.databases: - description: "The list of databases used in policydb database including name" - autoscaler.policy_db.db_scheme: - description: "Database scheme to be used to access policydb" - autoscaler.policy_db.port: - description: "Port on which the policydb server will listen" - autoscaler.policy_db.roles: - description: "The list of database roles used in policydb database including name/password" - autoscaler.policy_db.tls.ca: - default: '' - description: 'PEM-encoded ca certificate of tls database server' - autoscaler.policy_db.tls.certificate: - default: '' - description: 'PEM-encoded certificate of tls database client' - autoscaler.policy_db.tls.private_key: - default: '' - description: 'PEM-encoded key of tls database client' - autoscaler.policy_db.sslmode: - default: disable - description: "The sslmode to connect to postgres server" - - autoscaler.policy_db_connection_config.max_open_connections: - default: 20 - autoscaler.policy_db_connection_config.max_idle_connections: - default: 10 - autoscaler.policy_db_connection_config.connection_max_lifetime: - default: 60s - - autoscaler.metricsgateway.health.port: - description: "The listening port of health endpoint" - default: 6503 - autoscaler.metricsgateway.health.ca_cert: - description: "PEM-encoded CA certificate for the health endpoint" - autoscaler.metricsgateway.health.server_cert: - description: "PEM-encoded server certificate for the health endpoint" - autoscaler.metricsgateway.health.server_key: - description: "PEM-encoded server key for the health endpoint" - autoscaler.metricsgateway.health.username: - description: "the username of health endpoint" - default: '' - autoscaler.metricsgateway.health.password: - description: "the password of health endpoint" - default: '' diff --git a/jobs/metricsgateway/templates/bpm-pre-start.erb b/jobs/metricsgateway/templates/bpm-pre-start.erb deleted file mode 100644 index ea9a571191..0000000000 --- a/jobs/metricsgateway/templates/bpm-pre-start.erb +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash - -source /var/vcap/packages/common/dns-helper.sh - -export PATH=/var/vcap/packages/openjdk-17/bin:$PATH diff --git a/jobs/metricsgateway/templates/bpm.yml.erb b/jobs/metricsgateway/templates/bpm.yml.erb deleted file mode 100644 index 1cd16104ce..0000000000 --- a/jobs/metricsgateway/templates/bpm.yml.erb +++ /dev/null @@ -1,11 +0,0 @@ -processes: - - name: metricsgateway - executable: /var/vcap/packages/metricsgateway/metricsgateway - args: - - -c - - /var/vcap/jobs/metricsgateway/config/metricsgateway.yml - env: - DT_MONITOR: true - DT_APPLICATIONID: metricsgateway - hooks: - pre_start: /var/vcap/jobs/metricsgateway/bin/bpm-pre-start diff --git a/jobs/metricsgateway/templates/healthendpoint.crt.erb b/jobs/metricsgateway/templates/healthendpoint.crt.erb deleted file mode 100644 index c2d7a747bc..0000000000 --- a/jobs/metricsgateway/templates/healthendpoint.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsgateway.health.server_cert") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/healthendpoint.key.erb b/jobs/metricsgateway/templates/healthendpoint.key.erb deleted file mode 100644 index 4209051e45..0000000000 --- a/jobs/metricsgateway/templates/healthendpoint.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsgateway.health.server_key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/healthendpoint_ca.crt.erb b/jobs/metricsgateway/templates/healthendpoint_ca.crt.erb deleted file mode 100644 index 6b4ac56d20..0000000000 --- a/jobs/metricsgateway/templates/healthendpoint_ca.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsgateway.health.ca_cert") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/metricsgateway.yml.erb b/jobs/metricsgateway/templates/metricsgateway.yml.erb deleted file mode 100644 index 7ada15e5dc..0000000000 --- a/jobs/metricsgateway/templates/metricsgateway.yml.erb +++ /dev/null @@ -1,88 +0,0 @@ -<% - def p_arr(property) - p(property,nil) || [] - end - - def build_db_url(db_name, job_name) - db_scheme = p("autoscaler.#{db_name}.db_scheme") - db_address = p("autoscaler.#{db_name}.address") - db_port = p("autoscaler.#{db_name}.port") - db_roles = p_arr("autoscaler.#{db_name}.roles") - db_dbs = p_arr("autoscaler.#{db_name}.databases") - db_role = db_roles.find { |role| role['tag'] == db_name.tr('_', '') } || db_roles.find { |role| role['tag'] == 'default' } - db_database = db_dbs.find { |database| database['tag'] == db_name.tr('_', '') } || db_dbs.find { |database| database['tag'] == 'default' } - - if db_scheme == "postgres" - db_url = "#{db_scheme}://#{ERB::Util.url_encode(db_role['name'])}:#{ERB::Util.url_encode(db_role['password'])}@#{db_address}:#{db_port}/#{db_database['name']}?application_name=#{job_name}&sslmode=" + p("autoscaler.#{db_name}.sslmode") - else - db_url = "#{db_role['name']}:#{db_role['password']}@tcp(#{db_address}:#{db_port})/#{db_database['name']}?tls=" + p("autoscaler.#{db_name}.sslmode") - end - append_db_tls_configs(db_name, db_url, job_name) - end - - def append_db_tls_configs(db_name, db_url, job_name) - unless p("autoscaler.#{db_name}.tls.ca") == "" - db_url = "#{db_url}&sslrootcert=/var/vcap/jobs/#{job_name}/config/certs/#{db_name}/ca.crt" - end - unless p("autoscaler.#{db_name}.tls.certificate") == "" - db_url = "#{db_url}&sslcert=/var/vcap/jobs/#{job_name}/config/certs/#{db_name}/crt" - end - unless p("autoscaler.#{db_name}.tls.private_key") == "" - db_url = "#{db_url}&sslkey=/var/vcap/jobs/#{job_name}/config/certs/#{db_name}/key" - end - db_url -end - -########################################### -# Template Main # -########################################### - job_name = 'metricsgateway' - policy_db_url = build_db_url('policy_db', job_name) - - metricsserver_sorted_instances=link("metricsserver").instances.sort_by {|i|i.address} - metricsserver_addrs=metricsserver_sorted_instances.map{|i| "'wss://#{i.address}:#{link("metricsserver").p('autoscaler.metricsserver.collector.port')}'"} - metricsserver_nodeAddrs="[" + metricsserver_addrs.join(",") +"]" - -%> - - -logging: - level: <%= p("autoscaler.metricsgateway.logging.level") %> -envelop_chan_size: <%= p("autoscaler.metricsgateway.envelop_chan_size") %> -nozzle_count: <%= p("autoscaler.metricsgateway.nozzle_count") %> -metric_server_addrs: <%= metricsserver_nodeAddrs %> -app_manager: - app_refresh_interval: <%= p("autoscaler.metricsgateway.app_manager.app_refresh_interval") %> - policy_db: - url: <%= policy_db_url %> - max_open_connections: <%= p("autoscaler.policy_db_connection_config.max_open_connections") %> - max_idle_connections: <%= p("autoscaler.policy_db_connection_config.max_idle_connections") %> - connection_max_lifetime: <%= p("autoscaler.policy_db_connection_config.connection_max_lifetime") %> -emitter: - metrics_server_client_tls: - key_file: /var/vcap/jobs/metricsgateway/config/certs/metricsserver_client/server.key - cert_file: /var/vcap/jobs/metricsgateway/config/certs/metricsserver_client/server.crt - ca_file: /var/vcap/jobs/metricsgateway/config/certs/metricsserver_client/ca.crt - buffer_size: <%= p("autoscaler.metricsgateway.emitter.buffer_size") %> - keep_alive_interval: <%= p("autoscaler.metricsgateway.emitter.keep_alive_interval") %> - handshake_timeout: <%= p("autoscaler.metricsgateway.emitter.handshake_timeout") %> - max_setup_retry_count: <%= p("autoscaler.metricsgateway.emitter.max_setup_retry_count") %> - max_close_retry_count: <%= p("autoscaler.metricsgateway.emitter.max_close_retry_count") %> - retry_delay: <%= p("autoscaler.metricsgateway.emitter.retry_delay") %> -nozzle: - rlp_client_tls: - key_file: /var/vcap/jobs/metricsgateway/config/certs/reverselogproxy_client/client.key - cert_file: /var/vcap/jobs/metricsgateway/config/certs/reverselogproxy_client/client.crt - ca_file: /var/vcap/jobs/metricsgateway/config/certs/reverselogproxy_client/ca.crt - rlp_addr: <%= p("autoscaler.metricsgateway.nozzle.rlp_addr") %> - shard_id: <%= p("autoscaler.metricsgateway.nozzle.shard_id") %> -health: - port: <%= p("autoscaler.metricsgateway.health.port") %> - username: <%= p("autoscaler.metricsgateway.health.username") %> - password: <%= p("autoscaler.metricsgateway.health.password") %> - <% if_p("autoscaler.metricsgateway.health.ca_cert", "autoscaler.metricsgateway.health.server_cert", "autoscaler.metricsgateway.health.server_key") do %> - tls: - ca_file: /var/vcap/jobs/metricsgateway/config/certs/healthendpoint/ca.crt - cert_file: /var/vcap/jobs/metricsgateway/config/certs/healthendpoint/server.crt - key_file: /var/vcap/jobs/metricsgateway/config/certs/healthendpoint/server.key - <% end %> diff --git a/jobs/metricsgateway/templates/metricsserver_client.crt.erb b/jobs/metricsgateway/templates/metricsserver_client.crt.erb deleted file mode 100644 index 20490221e4..0000000000 --- a/jobs/metricsgateway/templates/metricsserver_client.crt.erb +++ /dev/null @@ -1,4 +0,0 @@ -<% if_p("autoscaler.metricsgateway.emitter.metricsserver_client.cert") do |value| %> -<%= value %> -<% end %> - diff --git a/jobs/metricsgateway/templates/metricsserver_client.key.erb b/jobs/metricsgateway/templates/metricsserver_client.key.erb deleted file mode 100644 index c33b098552..0000000000 --- a/jobs/metricsgateway/templates/metricsserver_client.key.erb +++ /dev/null @@ -1,4 +0,0 @@ -<% if_p("autoscaler.metricsgateway.emitter.metricsserver_client.key") do |value| %> -<%= value %> -<% end %> - diff --git a/jobs/metricsgateway/templates/metricsserver_client_ca.crt.erb b/jobs/metricsgateway/templates/metricsserver_client_ca.crt.erb deleted file mode 100644 index 2f3791bf1e..0000000000 --- a/jobs/metricsgateway/templates/metricsserver_client_ca.crt.erb +++ /dev/null @@ -1,4 +0,0 @@ -<% if_p("autoscaler.metricsgateway.emitter.metricsserver_client.ca_cert") do |value| %> -<%= value %> -<% end %> - diff --git a/jobs/metricsgateway/templates/policy_db.crt.erb b/jobs/metricsgateway/templates/policy_db.crt.erb deleted file mode 100644 index 3c19ec6240..0000000000 --- a/jobs/metricsgateway/templates/policy_db.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.policy_db.tls.certificate") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/policy_db.key.erb b/jobs/metricsgateway/templates/policy_db.key.erb deleted file mode 100644 index 6063d669f7..0000000000 --- a/jobs/metricsgateway/templates/policy_db.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.policy_db.tls.private_key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/policy_db_ca.crt.erb b/jobs/metricsgateway/templates/policy_db_ca.crt.erb deleted file mode 100644 index cd61f88ecd..0000000000 --- a/jobs/metricsgateway/templates/policy_db_ca.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.policy_db.tls.ca") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/reverselogproxy_client.crt.erb b/jobs/metricsgateway/templates/reverselogproxy_client.crt.erb deleted file mode 100644 index c0f50b7e5d..0000000000 --- a/jobs/metricsgateway/templates/reverselogproxy_client.crt.erb +++ /dev/null @@ -1,4 +0,0 @@ -<% if_p("autoscaler.metricsgateway.nozzle.loggregator_rlp_tls.cert") do |value| %> -<%= value %> -<% end %> - diff --git a/jobs/metricsgateway/templates/reverselogproxy_client.key.erb b/jobs/metricsgateway/templates/reverselogproxy_client.key.erb deleted file mode 100644 index 0188da43b6..0000000000 --- a/jobs/metricsgateway/templates/reverselogproxy_client.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsgateway.nozzle.loggregator_rlp_tls.key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsgateway/templates/reverselogproxy_client_ca.crt.erb b/jobs/metricsgateway/templates/reverselogproxy_client_ca.crt.erb deleted file mode 100644 index fdc37adde9..0000000000 --- a/jobs/metricsgateway/templates/reverselogproxy_client_ca.crt.erb +++ /dev/null @@ -1,4 +0,0 @@ -<% if_p("autoscaler.metricsgateway.nozzle.loggregator_rlp_tls.ca_cert") do |value| %> -<%= value %> -<% end %> - diff --git a/jobs/metricsserver/monit b/jobs/metricsserver/monit deleted file mode 100644 index be48818df7..0000000000 --- a/jobs/metricsserver/monit +++ /dev/null @@ -1,5 +0,0 @@ -check process metricsserver - with pidfile /var/vcap/sys/run/bpm/metricsserver/metricsserver.pid - start program "/var/vcap/jobs/bpm/bin/bpm start metricsserver" - stop program "/var/vcap/jobs/bpm/bin/bpm stop metricsserver" - group vcap \ No newline at end of file diff --git a/jobs/metricsserver/spec b/jobs/metricsserver/spec deleted file mode 100644 index a0dc33d4e0..0000000000 --- a/jobs/metricsserver/spec +++ /dev/null @@ -1,171 +0,0 @@ ---- -name: metricsserver -templates: - bpm-pre-start.erb: bin/bpm-pre-start - bpm.yml.erb: config/bpm.yml - metricsserver.yml.erb: config/metricsserver.yml - liquibase.properties: bin/liquibase.properties - - metricsserver_ca.crt.erb: config/certs/metricsserver/ca.crt - metricsserver_server.crt.erb: config/certs/metricsserver/server.crt - metricsserver_server.key.erb: config/certs/metricsserver/server.key - - healthendpoint_ca.crt.erb: config/certs/healthendpoint/ca.crt - healthendpoint.crt.erb: config/certs/healthendpoint/server.crt - healthendpoint.key.erb: config/certs/healthendpoint/server.key - - policy_db_ca.crt.erb: config/certs/policy_db/ca.crt - policy_db.crt.erb: config/certs/policy_db/crt - policy_db.key.erb: config/certs/policy_db/key - - appinstancemetrics_db_ca.crt.erb: config/certs/instancemetrics_db/ca.crt - appinstancemetrics_db.crt.erb: config/certs/instancemetrics_db/crt - appinstancemetrics_db.key.erb: config/certs/instancemetrics_db/key - -packages: - - openjdk-17 - - db - - metricsserver - - common - - changeloglockcleaner - -provides: -- name: metricsserver - type: metricsserver - properties: - - autoscaler.metricsserver.server.port - - autoscaler.metricsserver.collector.port - -consumes: -- name: metricsserver - type: metricsserver - -properties: - autoscaler.policy_db.address: - description: "IP address on which the policydb server will listen" - default: "autoscalerpostgres.service.cf.internal" - autoscaler.policy_db.databases: - description: "The list of databases used in policydb database including name" - autoscaler.policy_db.db_scheme: - description: "Database scheme to be used to access policydb" - autoscaler.policy_db.port: - description: "Port on which the policydb server will listen" - autoscaler.policy_db.roles: - description: "The list of database roles used in policydb database including name/password" - autoscaler.policy_db.tls.ca: - default: '' - description: 'PEM-encoded ca certificate of tls database server' - autoscaler.policy_db.tls.certificate: - default: '' - description: 'PEM-encoded certificate of tls database client' - autoscaler.policy_db.tls.private_key: - default: '' - description: 'PEM-encoded key of tls database client' - autoscaler.policy_db.sslmode: - default: disable - description: "The sslmode to connect to postgres server" - - autoscaler.instancemetrics_db.address: - description: "IP address on which the instancemetricsdb server will listen" - default: "autoscalerpostgres.service.cf.internal" - autoscaler.instancemetrics_db.databases: - description: "The list of databases used in instancemetricsdb database including name" - autoscaler.instancemetrics_db.db_scheme: - description: "Database scheme to be used to access instancemetricsdb" - autoscaler.instancemetrics_db.port: - description: "Port on which the instancemetricsdb server will listen" - autoscaler.instancemetrics_db.roles: - description: "The list of database roles used in instancemetricsdb database including name/password" - autoscaler.instancemetrics_db.tls.ca: - default: '' - description: 'PEM-encoded ca certificate for TLS database server' - autoscaler.instancemetrics_db.tls.certificate: - default: '' - description: 'PEM-encoded certificate for TLS database client' - autoscaler.instancemetrics_db.tls.private_key: - default: '' - description: 'PEM-encoded key for TLS database client' - autoscaler.instancemetrics_db.sslmode: - default: disable - description: "The sslmode to connect to postgres server" - - - autoscaler.instancemetrics_db_connection_config.max_open_connections: - default: 20 - autoscaler.instancemetrics_db_connection_config.max_idle_connections: - default: 10 - autoscaler.instancemetrics_db_connection_config.connection_max_lifetime: - default: 60s - - autoscaler.policy_db_connection_config.max_open_connections: - default: 20 - autoscaler.policy_db_connection_config.max_idle_connections: - default: 10 - autoscaler.policy_db_connection_config.connection_max_lifetime: - default: 60s - - autoscaler.metricsserver.logging.level: - description: "The level of logging" - default: "info" - - autoscaler.metricsserver.server.port: - description: "The listening port of http server" - default: 6103 - autoscaler.metricsserver.http_client_timeout: - description: "Http client timeout for metricsserver to communicate with other autoscaler components" - default: 60s - autoscaler.metricsserver.ca_cert: - description: "PEM-encoded CA certificate" - autoscaler.metricsserver.server_cert: - description: "PEM-encoded server certificate" - autoscaler.metricsserver.server_key: - description: "PEM-encoded server key" - autoscaler.metricsserver.collector.port: - description: "The listening port of websocket server" - default: 7103 - autoscaler.metricsserver.collector.keep_alive_time: - description: "Keep alive duration of the websocket between metricsserver and emitter" - default: 60s - autoscaler.metricsserver.collector.refresh_interval: - description: "The time interval to refresh app policies from policy database" - default: 60s - autoscaler.metricsserver.collector.collect_interval: - description: "The time interval to collect container metrics from loggregator" - default: 30s - autoscaler.metricsserver.collector.save_interval: - description: "The time interval to save metrics in database" - default: 5s - autoscaler.metricsserver.collector.persist_metrics: - description: "Whether to persist instancemetrics into database" - default: true - autoscaler.metricsserver.collector.envelope_processor_count: - description: "The envelope processor count to convert envelopes to app instance metrics" - default: 5 - autoscaler.metricsserver.collector.metric_cache_size_per_app: - description: "The instance metrics cache size for each application" - default: 1000 - autoscaler.metricsserver.collector.envelope_channel_size: - description: "The size of envelop channel to transport envelopes from websocket server to an envelope processor" - default: 1000 - autoscaler.metricsserver.collector.metric_channel_size: - description: "The size of channel to transport instance metric from envelope processors to cache" - default: 1000 - - autoscaler.metricsserver.health.port: - description: "The listening port of health endpoint" - default: 6303 - autoscaler.metricsserver.health.ca_cert: - description: "PEM-encoded CA certificate for the health endpoint" - autoscaler.metricsserver.health.server_cert: - description: "PEM-encoded server certificate for the health endpoint" - autoscaler.metricsserver.health.server_key: - description: "PEM-encoded server key for the health endpoint" - autoscaler.metricsserver.health.username: - description: "the username of health endpoint" - default: '' - autoscaler.metricsserver.health.password: - description: "the password of health endpoint" - default: '' - autoscaler.changeloglock_timeout_seconds: - default: 180 - description: "Liquibase changelog lock timeout duration in seconds" diff --git a/jobs/metricsserver/templates/appinstancemetrics_db.crt.erb b/jobs/metricsserver/templates/appinstancemetrics_db.crt.erb deleted file mode 100644 index bccd1b5ffe..0000000000 --- a/jobs/metricsserver/templates/appinstancemetrics_db.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.instancemetrics_db.tls.certificate") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/appinstancemetrics_db.key.erb b/jobs/metricsserver/templates/appinstancemetrics_db.key.erb deleted file mode 100644 index 9d64259e6a..0000000000 --- a/jobs/metricsserver/templates/appinstancemetrics_db.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.instancemetrics_db.tls.private_key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/appinstancemetrics_db_ca.crt.erb b/jobs/metricsserver/templates/appinstancemetrics_db_ca.crt.erb deleted file mode 100644 index d4e13326b9..0000000000 --- a/jobs/metricsserver/templates/appinstancemetrics_db_ca.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.instancemetrics_db.tls.ca") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/bpm-pre-start.erb b/jobs/metricsserver/templates/bpm-pre-start.erb deleted file mode 100644 index 6b61ec4446..0000000000 --- a/jobs/metricsserver/templates/bpm-pre-start.erb +++ /dev/null @@ -1,64 +0,0 @@ -#!/bin/bash - -<% - def p_arr(property) - p(property,nil) || [] - end - - role = p_arr('autoscaler.instancemetrics_db.roles').find { |role| role['tag'] == 'instancemetricsdb' or role['tag'] == 'default' } - database = p_arr('autoscaler.instancemetrics_db.databases').find { |database| database['tag'] == 'instancemetricsdb' or database['tag'] == 'default' } -%> -source /var/vcap/packages/common/dns-helper.sh -source /var/vcap/packages/common/retry-helper.sh -source /var/vcap/packages/common/cert-helper.sh - -export PATH=/var/vcap/packages/openjdk-17/bin:$PATH - -HOST='<%= p("autoscaler.instancemetrics_db.address") %>' -DBNAME='<%= database['name'] %>' -USER='<%= role['name'] %>' -PASSWORD='<%= role['password'] %>' -PORT='<%= p("autoscaler.instancemetrics_db.port") %>' -SSLMODE='<%= p("autoscaler.instancemetrics_db.sslmode") %>' -<% if p('autoscaler.instancemetrics_db.db_scheme') == "postgres" %> -JDBCDBURL="jdbc:postgresql://$HOST:$PORT/$DBNAME?sslmode=$SSLMODE" -DBURI="postgres://$USER:$PASSWORD@$HOST:$PORT/$DBNAME?sslmode=$SSLMODE" -<% unless p('autoscaler.instancemetrics_db.tls.ca') == "" %> -JDBCDBURL=$JDBCDBURL"&sslrootcert=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/ca.crt" -DBURI=$DBURI"&sslrootcert=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/ca.crt" -<% end %> -<% # TODO Refactor this block -unless p("autoscaler.instancemetrics_db.tls.certificate") == "" %> -JDBCDBURL=$JDBCDBURL"&sslcert=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/crt" -DBURI=$DBURI"&sslcert=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/crt" -<% end %> -<% unless p("autoscaler.instancemetrics_db.tls.private_key") == "" %> - declare -r rsa_key_file=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/key - declare -r pk8_file=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/key.pk8 - convert_to_pk8 "$rsa_key_file" "$pk8_file" - JDBCDBURL=$JDBCDBURL"&sslkey=$pk8_file" - DBURI=$DBURI"&sslkey=$rsa_key_file" -<% end %> -# mysql case -<% else %> -JDBCDBURL="jdbc:mysql://$HOST:$PORT/$DBNAME?autoReconnect=true" -DBURI="$USER:$PASSWORD@tcp($HOST:$PORT)/$DBNAME?tls=$SSLMODE" -<% unless p('autoscaler.instancemetrics_db.tls.ca') == "" %> - declare -r instancemetrics_db_trust_store=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/cacerts - /var/vcap/packages/common/init-db-truststore.sh appinstancemetrics_db /var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/ca.crt "$instancemetrics_db_trust_store" - JDBCDBURL=$JDBCDBURL"&useSSL=true&requireSSL=true&verifyServerCertificate=true&enabledTLSProtocols=TLSv1.2&trustCertificateKeyStorePassword=123456&trustCertificateKeyStoreUrl=file:$instancemetrics_db_trust_store&trustCertificateKeyStoreType=pkcs12" - DBURI=$DBURI"&sslrootcert=/var/vcap/jobs/metricsserver/config/certs/instancemetrics_db/ca.crt" -<% end %> -<% end %> - -detect_dns $HOST $PORT - -/var/vcap/packages/changeloglockcleaner/changeloglockcleaner -d "$DBURI" -e <%= p("autoscaler.changeloglock_timeout_seconds") %> - -<% if p('autoscaler.instancemetrics_db.db_scheme') == "postgres" %> -retry java -cp "/var/vcap/packages/db/target/lib/*:/var/vcap/packages/metricsserver" liquibase.integration.commandline.Main --url "$JDBCDBURL" --username=$USER --password=$PASSWORD \ ---driver=org.postgresql.Driver --changeLogFile=metricscollector.db.changelog.yml update -<% else %> -retry java -cp "/var/vcap/packages/db/target/lib/*:/var/vcap/packages/metricsserver" liquibase.integration.commandline.Main --url "$JDBCDBURL" --username=$USER --password=$PASSWORD \ ---driver=com.mysql.cj.jdbc.Driver --changeLogFile=metricscollector.db.changelog.yml update -<% end %> diff --git a/jobs/metricsserver/templates/bpm.yml.erb b/jobs/metricsserver/templates/bpm.yml.erb deleted file mode 100644 index 09bd35b6bf..0000000000 --- a/jobs/metricsserver/templates/bpm.yml.erb +++ /dev/null @@ -1,11 +0,0 @@ -processes: - - name: metricsserver - executable: /var/vcap/packages/metricsserver/metricsserver - args: - - -c - - /var/vcap/jobs/metricsserver/config/metricsserver.yml - env: - DT_MONITOR: true - DT_APPLICATIONID: metricsserver - hooks: - pre_start: /var/vcap/jobs/metricsserver/bin/bpm-pre-start diff --git a/jobs/metricsserver/templates/healthendpoint.crt.erb b/jobs/metricsserver/templates/healthendpoint.crt.erb deleted file mode 100644 index 5ae94caaef..0000000000 --- a/jobs/metricsserver/templates/healthendpoint.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsserver.health.server_cert") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/healthendpoint.key.erb b/jobs/metricsserver/templates/healthendpoint.key.erb deleted file mode 100644 index 693519b384..0000000000 --- a/jobs/metricsserver/templates/healthendpoint.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsserver.health.server_key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/healthendpoint_ca.crt.erb b/jobs/metricsserver/templates/healthendpoint_ca.crt.erb deleted file mode 100644 index d4c40e255e..0000000000 --- a/jobs/metricsserver/templates/healthendpoint_ca.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsserver.health.ca_cert") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/liquibase.properties b/jobs/metricsserver/templates/liquibase.properties deleted file mode 100644 index 163e3b1d97..0000000000 --- a/jobs/metricsserver/templates/liquibase.properties +++ /dev/null @@ -1 +0,0 @@ -liquibase.hub.mode=off diff --git a/jobs/metricsserver/templates/metricsserver.yml.erb b/jobs/metricsserver/templates/metricsserver.yml.erb deleted file mode 100644 index 3d79c62f23..0000000000 --- a/jobs/metricsserver/templates/metricsserver.yml.erb +++ /dev/null @@ -1,100 +0,0 @@ -<% - def p_arr(property) - p(property,nil) || [] - end - - def build_db_url(db_name, job_name) - db_scheme = p("autoscaler.#{db_name}.db_scheme") - db_address = p("autoscaler.#{db_name}.address") - db_port = p("autoscaler.#{db_name}.port") - db_roles = p_arr("autoscaler.#{db_name}.roles") - db_dbs = p_arr("autoscaler.#{db_name}.databases") - db_role = db_roles.find { |role| role['tag'] == db_name.tr('_', '') } || db_roles.find { |role| role['tag'] == 'default' } - db_database = db_dbs.find { |database| database['tag'] == db_name.tr('_', '') } || db_dbs.find { |database| database['tag'] == 'default' } - - if db_scheme == "postgres" - db_url = "#{db_scheme}://#{ERB::Util.url_encode(db_role['name'])}:#{ERB::Util.url_encode(db_role['password'])}@#{db_address}:#{db_port}/#{db_database['name']}?application_name=#{job_name}&sslmode=" + p("autoscaler.#{db_name}.sslmode") - else - db_url = "#{db_role['name']}:#{db_role['password']}@tcp(#{db_address}:#{db_port})/#{db_database['name']}?tls=" + p("autoscaler.#{db_name}.sslmode") - end - append_db_tls_configs(db_name, db_url, job_name) - end - - def append_db_tls_configs(db_name, db_url, job_name) - unless p("autoscaler.#{db_name}.tls.ca") == "" - db_url = "#{db_url}&sslrootcert=/var/vcap/jobs/#{job_name}/config/certs/#{db_name}/ca.crt" - end - unless p("autoscaler.#{db_name}.tls.certificate") == "" - db_url = "#{db_url}&sslcert=/var/vcap/jobs/#{job_name}/config/certs/#{db_name}/crt" - end - unless p("autoscaler.#{db_name}.tls.private_key") == "" - db_url = "#{db_url}&sslkey=/var/vcap/jobs/#{job_name}/config/certs/#{db_name}/key" - end - db_url -end - -########################################### -# Template Main # -########################################### - job_name = 'metricsserver' - instance_metrics_db_url = build_db_url('instancemetrics_db', job_name) - policy_db_url = build_db_url('policy_db', job_name) - - sorted_instances=link("metricsserver").instances.sort_by {|i|i.address} - nodeIndex=sorted_instances.index(sorted_instances.find{|i|i.id == spec.id}) - addrs=sorted_instances.map{|i| "'#{i.address}'"} - nodeAddrs="[" + addrs.join(",") +"]" - -%> - -logging: - level: <%= p("autoscaler.metricsserver.logging.level") %> -http_client_timeout: <%= p("autoscaler.metricsserver.http_client_timeout") %> -node_addrs: <%= nodeAddrs %> -node_index: <%= nodeIndex %> -db: - policy_db: - url: <%= policy_db_url %> - max_open_connections: <%= p("autoscaler.policy_db_connection_config.max_open_connections") %> - max_idle_connections: <%= p("autoscaler.policy_db_connection_config.max_idle_connections") %> - connection_max_lifetime: <%= p("autoscaler.policy_db_connection_config.connection_max_lifetime") %> - instance_metrics_db: - url: <%= instance_metrics_db_url %> - max_open_connections: <%= p("autoscaler.instancemetrics_db_connection_config.max_open_connections") %> - max_idle_connections: <%= p("autoscaler.instancemetrics_db_connection_config.max_idle_connections") %> - connection_max_lifetime: <%= p("autoscaler.instancemetrics_db_connection_config.connection_max_lifetime") %> -collector: - port: <%= p("autoscaler.metricsserver.collector.port") %> - keep_alive_time: <%= p("autoscaler.metricsserver.collector.keep_alive_time") %> - refresh_interval: <%= p("autoscaler.metricsserver.collector.refresh_interval") %> - collect_interval: <%= p("autoscaler.metricsserver.collector.collect_interval") %> - save_interval: <%= p("autoscaler.metricsserver.collector.save_interval") %> - persist_metrics: <%= p("autoscaler.metricsserver.collector.persist_metrics") %> - envelope_processor_count: <%= p("autoscaler.metricsserver.collector.envelope_processor_count") %> - metric_cache_size_per_app: <%= p("autoscaler.metricsserver.collector.metric_cache_size_per_app") %> - envelope_channel_size: <%= p("autoscaler.metricsserver.collector.envelope_channel_size") %> - metric_channel_size: <%= p("autoscaler.metricsserver.collector.metric_channel_size") %> - tls: - key_file: /var/vcap/jobs/metricsserver/config/certs/metricsserver/server.key - cert_file: /var/vcap/jobs/metricsserver/config/certs/metricsserver/server.crt - ca_file: /var/vcap/jobs/metricsserver/config/certs/metricsserver/ca.crt - -server: - port: <%= p("autoscaler.metricsserver.server.port") %> - tls: - key_file: /var/vcap/jobs/metricsserver/config/certs/metricsserver/server.key - cert_file: /var/vcap/jobs/metricsserver/config/certs/metricsserver/server.crt - ca_file: /var/vcap/jobs/metricsserver/config/certs/metricsserver/ca.crt -health: - port: <%= p("autoscaler.metricsserver.health.port") %> - username: <%= p("autoscaler.metricsserver.health.username") %> - password: <%= p("autoscaler.metricsserver.health.password") %> - <% if_p("autoscaler.metricsserver.health.ca_cert", "autoscaler.metricsserver.health.server_cert", "autoscaler.metricsserver.health.server_key") do %> - tls: - ca_file: /var/vcap/jobs/metricsserver/config/certs/healthendpoint/ca.crt - cert_file: /var/vcap/jobs/metricsserver/config/certs/healthendpoint/server.crt - key_file: /var/vcap/jobs/metricsserver/config/certs/healthendpoint/server.key - <% end %> - - - diff --git a/jobs/metricsserver/templates/metricsserver_ca.crt.erb b/jobs/metricsserver/templates/metricsserver_ca.crt.erb deleted file mode 100644 index 3949634603..0000000000 --- a/jobs/metricsserver/templates/metricsserver_ca.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsserver.ca_cert") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/metricsserver_server.crt.erb b/jobs/metricsserver/templates/metricsserver_server.crt.erb deleted file mode 100644 index 8ea61f8eb6..0000000000 --- a/jobs/metricsserver/templates/metricsserver_server.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsserver.server_cert") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/metricsserver_server.key.erb b/jobs/metricsserver/templates/metricsserver_server.key.erb deleted file mode 100644 index c2efd20bb0..0000000000 --- a/jobs/metricsserver/templates/metricsserver_server.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.metricsserver.server_key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/policy_db.crt.erb b/jobs/metricsserver/templates/policy_db.crt.erb deleted file mode 100644 index 3c19ec6240..0000000000 --- a/jobs/metricsserver/templates/policy_db.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.policy_db.tls.certificate") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/policy_db.key.erb b/jobs/metricsserver/templates/policy_db.key.erb deleted file mode 100644 index 6063d669f7..0000000000 --- a/jobs/metricsserver/templates/policy_db.key.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.policy_db.tls.private_key") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/jobs/metricsserver/templates/policy_db_ca.crt.erb b/jobs/metricsserver/templates/policy_db_ca.crt.erb deleted file mode 100644 index cd61f88ecd..0000000000 --- a/jobs/metricsserver/templates/policy_db_ca.crt.erb +++ /dev/null @@ -1,3 +0,0 @@ -<% if_p("autoscaler.policy_db.tls.ca") do |value| %> -<%= value %> -<% end %> \ No newline at end of file diff --git a/packages/metricsgateway/packaging b/packages/metricsgateway/packaging deleted file mode 100644 index 74291ff3c3..0000000000 --- a/packages/metricsgateway/packaging +++ /dev/null @@ -1,12 +0,0 @@ -set -e -x - -export GOROOT=$(readlink -nf /var/vcap/packages/golang-1-linux) -export PATH=$GOROOT/bin:$PATH -export GOPATH=${BOSH_COMPILE_TARGET} -export GOCACHE=/tmp/gocache - -pushd ${BOSH_COMPILE_TARGET}/autoscaler - GOPROXY=off make build-metricsgateway -popd - -cp -a ${BOSH_COMPILE_TARGET}/autoscaler/build/metricsgateway ${BOSH_INSTALL_TARGET} diff --git a/packages/metricsgateway/spec b/packages/metricsgateway/spec deleted file mode 100644 index 31f59047ec..0000000000 --- a/packages/metricsgateway/spec +++ /dev/null @@ -1,224 +0,0 @@ ---- -name: metricsgateway - -dependencies: -- golang-1-linux - -files: -- autoscaler/* -- autoscaler/vendor/* -- autoscaler/cf/* # gosub -- autoscaler/db/* # gosub -- autoscaler/db/sqldb/* # gosub -- autoscaler/healthendpoint/* # gosub -- autoscaler/helpers/* # gosub -- autoscaler/metricsforwarder/server/common/* # gosub -- autoscaler/metricsgateway/* # gosub -- autoscaler/metricsgateway/cmd/metricsgateway/* # gosub -- autoscaler/metricsgateway/config/* # gosub -- autoscaler/metricsgateway/helpers/* # gosub -- autoscaler/models/* # gosub -- autoscaler/routes/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/cfhttp/v2/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/clock/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/go-diodes/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/go-loggregator/v9/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/go-loggregator/v9/rpc/loggregator_v2/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/lager/v3/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/lager/v3/internal/truncate/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/tlsconfig/* # gosub -- autoscaler/vendor/filippo.io/edwards25519/* # gosub -- autoscaler/vendor/filippo.io/edwards25519/field/* # gosub -- autoscaler/vendor/github.com/beorn7/perks/quantile/* # gosub -- autoscaler/vendor/github.com/cespare/xxhash/v2/* # gosub -- autoscaler/vendor/github.com/go-logr/logr/* # gosub -- autoscaler/vendor/github.com/go-logr/logr/funcr/* # gosub -- autoscaler/vendor/github.com/go-logr/stdr/* # gosub -- autoscaler/vendor/github.com/go-sql-driver/mysql/* # gosub -- autoscaler/vendor/github.com/golang/protobuf/proto/* # gosub -- autoscaler/vendor/github.com/gorilla/mux/* # gosub -- autoscaler/vendor/github.com/gorilla/websocket/* # gosub -- autoscaler/vendor/github.com/hashicorp/go-cleanhttp/* # gosub -- autoscaler/vendor/github.com/hashicorp/go-retryablehttp/* # gosub -- autoscaler/vendor/github.com/jackc/pgpassfile/* # gosub -- autoscaler/vendor/github.com/jackc/pgservicefile/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/iobufpool/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/pgio/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/sanitize/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/stmtcache/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgconn/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgconn/ctxwatch/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgconn/internal/bgreader/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgproto3/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgtype/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgxpool/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/stdlib/* # gosub -- autoscaler/vendor/github.com/jackc/puddle/v2/* # gosub -- autoscaler/vendor/github.com/jackc/puddle/v2/internal/genstack/* # gosub -- autoscaler/vendor/github.com/jmoiron/sqlx/* # gosub -- autoscaler/vendor/github.com/jmoiron/sqlx/reflectx/* # gosub -- autoscaler/vendor/github.com/nu7hatch/gouuid/* # gosub -- autoscaler/vendor/github.com/openzipkin/zipkin-go/idgenerator/* # gosub -- autoscaler/vendor/github.com/openzipkin/zipkin-go/model/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/collectors/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/internal/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/promhttp/* # gosub -- autoscaler/vendor/github.com/prometheus/client_model/go/* # gosub -- autoscaler/vendor/github.com/prometheus/common/expfmt/* # gosub -- autoscaler/vendor/github.com/prometheus/common/internal/bitbucket.org/ww/goautoneg/* # gosub -- autoscaler/vendor/github.com/prometheus/common/model/* # gosub -- autoscaler/vendor/github.com/prometheus/procfs/* # gosub -- autoscaler/vendor/github.com/prometheus/procfs/internal/fs/* # gosub -- autoscaler/vendor/github.com/prometheus/procfs/internal/util/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/grouper/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/http_server/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/sigmon/* # gosub -- autoscaler/vendor/github.com/uptrace/opentelemetry-go-extra/otelsql/* # gosub -- autoscaler/vendor/github.com/uptrace/opentelemetry-go-extra/otelsqlx/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/attribute/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/baggage/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/codes/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/attribute/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/baggage/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/global/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/metric/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/metric/embedded/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/propagation/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/instrumentation/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/internal/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/internal/env/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/resource/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/trace/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/internal/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.10.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.21.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.24.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/trace/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/trace/embedded/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/trace/noop/* # gosub -- autoscaler/vendor/golang.org/x/crypto/bcrypt/* # gosub -- autoscaler/vendor/golang.org/x/crypto/blowfish/* # gosub -- autoscaler/vendor/golang.org/x/crypto/pbkdf2/* # gosub -- autoscaler/vendor/golang.org/x/exp/maps/* # gosub -- autoscaler/vendor/golang.org/x/net/context/* # gosub -- autoscaler/vendor/golang.org/x/net/http/httpguts/* # gosub -- autoscaler/vendor/golang.org/x/net/http2/* # gosub -- autoscaler/vendor/golang.org/x/net/http2/hpack/* # gosub -- autoscaler/vendor/golang.org/x/net/idna/* # gosub -- autoscaler/vendor/golang.org/x/net/internal/socks/* # gosub -- autoscaler/vendor/golang.org/x/net/internal/timeseries/* # gosub -- autoscaler/vendor/golang.org/x/net/proxy/* # gosub -- autoscaler/vendor/golang.org/x/net/trace/* # gosub -- autoscaler/vendor/golang.org/x/sync/semaphore/* # gosub -- autoscaler/vendor/golang.org/x/sys/unix/* # gosub -- autoscaler/vendor/golang.org/x/sys/windows/* # gosub -- autoscaler/vendor/golang.org/x/sys/windows/registry/* # gosub -- autoscaler/vendor/golang.org/x/text/cases/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/language/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/language/compact/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/tag/* # gosub -- autoscaler/vendor/golang.org/x/text/language/* # gosub -- autoscaler/vendor/golang.org/x/text/runes/* # gosub -- autoscaler/vendor/golang.org/x/text/secure/bidirule/* # gosub -- autoscaler/vendor/golang.org/x/text/secure/precis/* # gosub -- autoscaler/vendor/golang.org/x/text/transform/* # gosub -- autoscaler/vendor/golang.org/x/text/unicode/bidi/* # gosub -- autoscaler/vendor/golang.org/x/text/unicode/norm/* # gosub -- autoscaler/vendor/golang.org/x/text/width/* # gosub -- autoscaler/vendor/google.golang.org/genproto/googleapis/rpc/status/* # gosub -- autoscaler/vendor/google.golang.org/grpc/* # gosub -- autoscaler/vendor/google.golang.org/grpc/attributes/* # gosub -- autoscaler/vendor/google.golang.org/grpc/backoff/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/base/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/grpclb/state/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/roundrobin/* # gosub -- autoscaler/vendor/google.golang.org/grpc/binarylog/grpc_binarylog_v1/* # gosub -- autoscaler/vendor/google.golang.org/grpc/channelz/* # gosub -- autoscaler/vendor/google.golang.org/grpc/codes/* # gosub -- autoscaler/vendor/google.golang.org/grpc/connectivity/* # gosub -- autoscaler/vendor/google.golang.org/grpc/credentials/* # gosub -- autoscaler/vendor/google.golang.org/grpc/credentials/insecure/* # gosub -- autoscaler/vendor/google.golang.org/grpc/encoding/* # gosub -- autoscaler/vendor/google.golang.org/grpc/encoding/proto/* # gosub -- autoscaler/vendor/google.golang.org/grpc/grpclog/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/backoff/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/balancer/gracefulswitch/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/balancerload/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/binarylog/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/buffer/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/channelz/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/credentials/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/envconfig/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpclog/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpcrand/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpcsync/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpcutil/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/idle/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/metadata/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/pretty/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/dns/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/dns/internal/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/passthrough/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/unix/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/serviceconfig/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/status/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/syscall/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/transport/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/transport/networktype/* # gosub -- autoscaler/vendor/google.golang.org/grpc/keepalive/* # gosub -- autoscaler/vendor/google.golang.org/grpc/metadata/* # gosub -- autoscaler/vendor/google.golang.org/grpc/peer/* # gosub -- autoscaler/vendor/google.golang.org/grpc/resolver/* # gosub -- autoscaler/vendor/google.golang.org/grpc/resolver/dns/* # gosub -- autoscaler/vendor/google.golang.org/grpc/serviceconfig/* # gosub -- autoscaler/vendor/google.golang.org/grpc/stats/* # gosub -- autoscaler/vendor/google.golang.org/grpc/status/* # gosub -- autoscaler/vendor/google.golang.org/grpc/tap/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/protodelim/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/protojson/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/prototext/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/protowire/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/descfmt/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/descopts/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/detrand/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/editiondefaults/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/editionssupport/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/defval/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/json/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/messageset/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/tag/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/text/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/errors/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/filedesc/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/filetype/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/flags/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/genid/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/impl/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/order/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/pragma/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/set/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/strs/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/version/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/proto/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/protoadapt/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/reflect/protodesc/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/reflect/protoreflect/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/reflect/protoregistry/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/runtime/protoiface/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/runtime/protoimpl/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/descriptorpb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/gofeaturespb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/known/anypb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/known/durationpb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/known/timestamppb/* # gosub -- autoscaler/vendor/gopkg.in/yaml.v3/* # gosub diff --git a/packages/metricsserver/packaging b/packages/metricsserver/packaging deleted file mode 100644 index aa8ada9230..0000000000 --- a/packages/metricsserver/packaging +++ /dev/null @@ -1,13 +0,0 @@ -set -e -x - -export GOROOT=$(readlink -nf /var/vcap/packages/golang-1-linux) -export PATH=$GOROOT/bin:$PATH -export GOPATH=${BOSH_COMPILE_TARGET} -export GOCACHE=/tmp/gocache - -pushd ${BOSH_COMPILE_TARGET}/autoscaler - GOPROXY=off make build-metricsserver -popd - -cp -a ${BOSH_COMPILE_TARGET}/autoscaler/build/metricsserver ${BOSH_INSTALL_TARGET} -cp -a ${BOSH_COMPILE_TARGET}/autoscaler/metricsserver/db/metricscollector.db.changelog.yml ${BOSH_INSTALL_TARGET} diff --git a/packages/metricsserver/spec b/packages/metricsserver/spec deleted file mode 100644 index e5f8b6d283..0000000000 --- a/packages/metricsserver/spec +++ /dev/null @@ -1,230 +0,0 @@ ---- -name: metricsserver - -dependencies: -- golang-1-linux - -files: -- autoscaler/* -- autoscaler/vendor/* -- autoscaler/metricsserver/db/* -- autoscaler/cf/* # gosub -- autoscaler/collection/* # gosub -- autoscaler/db/* # gosub -- autoscaler/db/sqldb/* # gosub -- autoscaler/envelopeprocessor/* # gosub -- autoscaler/healthendpoint/* # gosub -- autoscaler/helpers/* # gosub -- autoscaler/helpers/handlers/* # gosub -- autoscaler/metricsforwarder/server/common/* # gosub -- autoscaler/metricsserver/cmd/metricsserver/* # gosub -- autoscaler/metricsserver/collector/* # gosub -- autoscaler/metricsserver/config/* # gosub -- autoscaler/models/* # gosub -- autoscaler/routes/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/cfhttp/v2/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/clock/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/go-loggregator/v9/rpc/loggregator_v2/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/lager/v3/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/lager/v3/internal/truncate/* # gosub -- autoscaler/vendor/code.cloudfoundry.org/tlsconfig/* # gosub -- autoscaler/vendor/dario.cat/mergo/* # gosub -- autoscaler/vendor/filippo.io/edwards25519/* # gosub -- autoscaler/vendor/filippo.io/edwards25519/field/* # gosub -- autoscaler/vendor/github.com/beorn7/perks/quantile/* # gosub -- autoscaler/vendor/github.com/cespare/xxhash/v2/* # gosub -- autoscaler/vendor/github.com/felixge/httpsnoop/* # gosub -- autoscaler/vendor/github.com/go-logr/logr/* # gosub -- autoscaler/vendor/github.com/go-logr/logr/funcr/* # gosub -- autoscaler/vendor/github.com/go-logr/stdr/* # gosub -- autoscaler/vendor/github.com/go-sql-driver/mysql/* # gosub -- autoscaler/vendor/github.com/golang/protobuf/proto/* # gosub -- autoscaler/vendor/github.com/gorilla/mux/* # gosub -- autoscaler/vendor/github.com/gorilla/websocket/* # gosub -- autoscaler/vendor/github.com/hashicorp/go-cleanhttp/* # gosub -- autoscaler/vendor/github.com/hashicorp/go-retryablehttp/* # gosub -- autoscaler/vendor/github.com/jackc/pgpassfile/* # gosub -- autoscaler/vendor/github.com/jackc/pgservicefile/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/iobufpool/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/pgio/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/sanitize/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/internal/stmtcache/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgconn/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgconn/ctxwatch/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgconn/internal/bgreader/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgproto3/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgtype/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/pgxpool/* # gosub -- autoscaler/vendor/github.com/jackc/pgx/v5/stdlib/* # gosub -- autoscaler/vendor/github.com/jackc/puddle/v2/* # gosub -- autoscaler/vendor/github.com/jackc/puddle/v2/internal/genstack/* # gosub -- autoscaler/vendor/github.com/jmoiron/sqlx/* # gosub -- autoscaler/vendor/github.com/jmoiron/sqlx/reflectx/* # gosub -- autoscaler/vendor/github.com/nu7hatch/gouuid/* # gosub -- autoscaler/vendor/github.com/openzipkin/zipkin-go/idgenerator/* # gosub -- autoscaler/vendor/github.com/openzipkin/zipkin-go/model/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/collectors/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/internal/* # gosub -- autoscaler/vendor/github.com/prometheus/client_golang/prometheus/promhttp/* # gosub -- autoscaler/vendor/github.com/prometheus/client_model/go/* # gosub -- autoscaler/vendor/github.com/prometheus/common/expfmt/* # gosub -- autoscaler/vendor/github.com/prometheus/common/internal/bitbucket.org/ww/goautoneg/* # gosub -- autoscaler/vendor/github.com/prometheus/common/model/* # gosub -- autoscaler/vendor/github.com/prometheus/procfs/* # gosub -- autoscaler/vendor/github.com/prometheus/procfs/internal/fs/* # gosub -- autoscaler/vendor/github.com/prometheus/procfs/internal/util/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/grouper/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/http_server/* # gosub -- autoscaler/vendor/github.com/tedsuo/ifrit/sigmon/* # gosub -- autoscaler/vendor/github.com/uptrace/opentelemetry-go-extra/otelsql/* # gosub -- autoscaler/vendor/github.com/uptrace/opentelemetry-go-extra/otelsqlx/* # gosub -- autoscaler/vendor/go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux/* # gosub -- autoscaler/vendor/go.opentelemetry.io/contrib/instrumentation/github.com/gorilla/mux/otelmux/internal/semconvutil/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/attribute/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/baggage/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/codes/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/attribute/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/baggage/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/internal/global/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/metric/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/metric/embedded/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/propagation/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/instrumentation/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/internal/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/internal/env/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/resource/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/sdk/trace/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/internal/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.10.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.20.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.21.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/semconv/v1.24.0/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/trace/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/trace/embedded/* # gosub -- autoscaler/vendor/go.opentelemetry.io/otel/trace/noop/* # gosub -- autoscaler/vendor/golang.org/x/crypto/bcrypt/* # gosub -- autoscaler/vendor/golang.org/x/crypto/blowfish/* # gosub -- autoscaler/vendor/golang.org/x/crypto/pbkdf2/* # gosub -- autoscaler/vendor/golang.org/x/exp/maps/* # gosub -- autoscaler/vendor/golang.org/x/net/context/* # gosub -- autoscaler/vendor/golang.org/x/net/http/httpguts/* # gosub -- autoscaler/vendor/golang.org/x/net/http2/* # gosub -- autoscaler/vendor/golang.org/x/net/http2/hpack/* # gosub -- autoscaler/vendor/golang.org/x/net/idna/* # gosub -- autoscaler/vendor/golang.org/x/net/internal/socks/* # gosub -- autoscaler/vendor/golang.org/x/net/internal/timeseries/* # gosub -- autoscaler/vendor/golang.org/x/net/proxy/* # gosub -- autoscaler/vendor/golang.org/x/net/trace/* # gosub -- autoscaler/vendor/golang.org/x/sync/semaphore/* # gosub -- autoscaler/vendor/golang.org/x/sys/unix/* # gosub -- autoscaler/vendor/golang.org/x/sys/windows/* # gosub -- autoscaler/vendor/golang.org/x/sys/windows/registry/* # gosub -- autoscaler/vendor/golang.org/x/text/cases/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/language/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/language/compact/* # gosub -- autoscaler/vendor/golang.org/x/text/internal/tag/* # gosub -- autoscaler/vendor/golang.org/x/text/language/* # gosub -- autoscaler/vendor/golang.org/x/text/runes/* # gosub -- autoscaler/vendor/golang.org/x/text/secure/bidirule/* # gosub -- autoscaler/vendor/golang.org/x/text/secure/precis/* # gosub -- autoscaler/vendor/golang.org/x/text/transform/* # gosub -- autoscaler/vendor/golang.org/x/text/unicode/bidi/* # gosub -- autoscaler/vendor/golang.org/x/text/unicode/norm/* # gosub -- autoscaler/vendor/golang.org/x/text/width/* # gosub -- autoscaler/vendor/google.golang.org/genproto/googleapis/rpc/status/* # gosub -- autoscaler/vendor/google.golang.org/grpc/* # gosub -- autoscaler/vendor/google.golang.org/grpc/attributes/* # gosub -- autoscaler/vendor/google.golang.org/grpc/backoff/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/base/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/grpclb/state/* # gosub -- autoscaler/vendor/google.golang.org/grpc/balancer/roundrobin/* # gosub -- autoscaler/vendor/google.golang.org/grpc/binarylog/grpc_binarylog_v1/* # gosub -- autoscaler/vendor/google.golang.org/grpc/channelz/* # gosub -- autoscaler/vendor/google.golang.org/grpc/codes/* # gosub -- autoscaler/vendor/google.golang.org/grpc/connectivity/* # gosub -- autoscaler/vendor/google.golang.org/grpc/credentials/* # gosub -- autoscaler/vendor/google.golang.org/grpc/credentials/insecure/* # gosub -- autoscaler/vendor/google.golang.org/grpc/encoding/* # gosub -- autoscaler/vendor/google.golang.org/grpc/encoding/proto/* # gosub -- autoscaler/vendor/google.golang.org/grpc/grpclog/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/backoff/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/balancer/gracefulswitch/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/balancerload/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/binarylog/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/buffer/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/channelz/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/credentials/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/envconfig/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpclog/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpcrand/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpcsync/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/grpcutil/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/idle/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/metadata/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/pretty/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/dns/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/dns/internal/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/passthrough/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/resolver/unix/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/serviceconfig/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/status/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/syscall/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/transport/* # gosub -- autoscaler/vendor/google.golang.org/grpc/internal/transport/networktype/* # gosub -- autoscaler/vendor/google.golang.org/grpc/keepalive/* # gosub -- autoscaler/vendor/google.golang.org/grpc/metadata/* # gosub -- autoscaler/vendor/google.golang.org/grpc/peer/* # gosub -- autoscaler/vendor/google.golang.org/grpc/resolver/* # gosub -- autoscaler/vendor/google.golang.org/grpc/resolver/dns/* # gosub -- autoscaler/vendor/google.golang.org/grpc/serviceconfig/* # gosub -- autoscaler/vendor/google.golang.org/grpc/stats/* # gosub -- autoscaler/vendor/google.golang.org/grpc/status/* # gosub -- autoscaler/vendor/google.golang.org/grpc/tap/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/protodelim/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/protojson/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/prototext/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/encoding/protowire/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/descfmt/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/descopts/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/detrand/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/editiondefaults/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/editionssupport/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/defval/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/json/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/messageset/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/tag/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/encoding/text/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/errors/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/filedesc/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/filetype/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/flags/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/genid/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/impl/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/order/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/pragma/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/set/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/strs/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/internal/version/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/proto/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/protoadapt/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/reflect/protodesc/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/reflect/protoreflect/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/reflect/protoregistry/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/runtime/protoiface/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/runtime/protoimpl/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/descriptorpb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/gofeaturespb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/known/anypb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/known/durationpb/* # gosub -- autoscaler/vendor/google.golang.org/protobuf/types/known/timestamppb/* # gosub -- autoscaler/vendor/gopkg.in/yaml.v3/* # gosub diff --git a/spec/jobs/metricsforwarder/metricsforwarder_spec.rb b/spec/jobs/metricsforwarder/metricsforwarder_spec.rb deleted file mode 100644 index 4c64b52f61..0000000000 --- a/spec/jobs/metricsforwarder/metricsforwarder_spec.rb +++ /dev/null @@ -1,118 +0,0 @@ -require "rspec" -require "json" -require "bosh/template/test" -require "rspec/file_fixtures" -require "yaml" - -describe "metricsforwarder" do - let(:release) { Bosh::Template::Test::ReleaseDir.new(File.join(File.dirname(__FILE__), "../../..")) } - let(:job) { release.job("metricsforwarder") } - let(:template) { job.template("config/metricsforwarder.yml") } - let(:properties) { YAML.safe_load(fixture("metricsforwarder.yml").read) } - let(:rendered_template) { YAML.safe_load(template.render(properties)) } - - context "config/metricsforwarder.yml" do - it "supports syslog forwarding" do - properties["autoscaler"]["metricsforwarder"] = { - "syslog" => { - "server_address" => "syslog-server" - } - } - - expect(rendered_template).to include( - { - "syslog" => { - "server_address" => "syslog-server", - "port" => 6067, - "tls" => { - "key_file" => "/var/vcap/jobs/metricsforwarder/config/certs/syslog_client/client.key", - "cert_file" => "/var/vcap/jobs/metricsforwarder/config/certs/syslog_client/client.crt", - "ca_file" => "/var/vcap/jobs/metricsforwarder/config/certs/syslog_client/ca.crt" - } - } - } - ) - end - - it "does not set username nor password if not configured" do - properties["autoscaler"]["metricsforwarder"] = { - "health" => { - "port" => 1234 - } - } - - expect(rendered_template["health"]) - .to include( - {"port" => 1234} - ) - end - - it "check metricsforwarder basic auth username and password" do - properties["autoscaler"]["metricsforwarder"] = { - "health" => { - "port" => 1234, - "username" => "test-user", - "password" => "test-user-password" - } - } - - expect(rendered_template["health"]) - .to include( - {"port" => 1234, - "username" => "test-user", - "password" => "test-user-password"} - ) - end - - it "has a cred helper impl by default" do - expect(rendered_template).to include({ - "cred_helper_impl" => "default" - }) - end - - it "has a cred helper impl configured for stored procedures" do - properties["autoscaler"]["metricsforwarder"] = { - "cred_helper" => { - "impl" => "stored_procedure", - "stored_procedure_config" => { - "schema_name" => "SCHEMA", - "create_binding_credential_procedure_name" => "CREATE_BINDING_CREDENTIAL", - "drop_binding_credential_procedure_name" => "DROP_BINDING_CREDENTIAL", - "drop_all_binding_credential_procedure_name" => "DROP_ALL_BINDING_CREDENTIALS", - "validate_binding_credential_procedure_name" => "VALIDATE_BINDING_CREDENTIALS" - } - } - } - - expect(rendered_template).to include( - { - "cred_helper_impl" => "stored_procedure", - "stored_procedure_binding_credential_config" => { - "schema_name" => "SCHEMA", - "create_binding_credential_procedure_name" => "CREATE_BINDING_CREDENTIAL", - "drop_binding_credential_procedure_name" => "DROP_BINDING_CREDENTIAL", - "drop_all_binding_credential_procedure_name" => "DROP_ALL_BINDING_CREDENTIALS", - "validate_binding_credential_procedure_name" => "VALIDATE_BINDING_CREDENTIALS" - } - } - ) - end - - context "uses tls" do - context "policy_db" do - it "includes the ca, cert and key in url when configured" do - rendered_template["db"]["policy_db"]["url"].tap do |url| - check_if_certs_in_url(url, "policy_db") - end - end - - it "does not include the ca, cert and key in url when not configured" do - properties["autoscaler"]["policy_db"]["tls"] = nil - rendered_template["db"]["policy_db"]["url"].tap do |url| - check_if_certs_not_in_url(url, "policy_db") - end - end - end - end - end -end diff --git a/spec/jobs/metricsgateway/metricsgateway_spec.rb b/spec/jobs/metricsgateway/metricsgateway_spec.rb deleted file mode 100644 index 924942d083..0000000000 --- a/spec/jobs/metricsgateway/metricsgateway_spec.rb +++ /dev/null @@ -1,69 +0,0 @@ -require "rspec" -require "json" -require "bosh/template/test" -require "yaml" -require "rspec/file_fixtures" - -describe "metricsgateway" do - let(:release) { Bosh::Template::Test::ReleaseDir.new(File.join(File.dirname(__FILE__), "../../..")) } - let(:job) { release.job("metricsgateway") } - let(:template) { job.template("config/metricsgateway.yml") } - let(:properties) { YAML.safe_load(fixture("metricsgateway.yml").read) } - let(:links) { [Bosh::Template::Test::Link.new(name: "metricsserver")] } - let(:rendered_template) { YAML.safe_load(template.render(properties, consumes: links)) } - - context "config/metricsgateway.yml" do - it "does not set username nor password if not configured" do - properties["autoscaler"]["metricsgateway"] = { - "health" => { - "port" => 1234 - }, - "nozzle" => { - "rlp_addr" => "localhost" - } - } - - expect(rendered_template["health"]) - .to include( - {"port" => 1234} - ) - end - - it "check metricsgateway basic auth username and password" do - properties["autoscaler"]["metricsgateway"] = { - "health" => { - "port" => 1234, - "username" => "test-user", - "password" => "test-user-password" - }, - "nozzle" => { - "rlp_addr" => "localhost" - } - } - - expect(rendered_template["health"]) - .to include( - {"port" => 1234, - "username" => "test-user", - "password" => "test-user-password"} - ) - end - - context "apiserver uses tls" do - context "policy_db" do - it "includes the ca, cert and key in url when configured" do - rendered_template["app_manager"]["policy_db"]["url"].tap do |url| - check_if_certs_in_url(url, "policy_db") - end - end - - it "does not include the ca, cert and key in url when not configured" do - properties["autoscaler"]["policy_db"]["tls"] = nil - rendered_template["app_manager"]["policy_db"]["url"].tap do |url| - check_if_certs_not_in_url(url, "policy_db") - end - end - end - end - end -end