File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
cookbooks/postgresql/recipes Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 1717# limitations under the License.
1818#
1919
20+ require "uri"
21+
2022include_recipe "apt::postgresql"
2123include_recipe "munin"
2224include_recipe "prometheus"
131133 labels "cluster" => name
132134 scrape_interval "1m"
133135 scrape_timeout "1m"
134- user "postgres"
135136 options %w[
136137 --collector.database_wraparound
137138 --collector.long_running_transactions
140141 --collector.stat_wal_receiver
141142 --collector.statio_user_indexes
142143 ]
143- environment "DATA_SOURCE_NAME" => "postgres:///#{ prometheus_database } ?host=/run/postgresql&port=#{ details [ :port ] } "
144+ environment "DATA_SOURCE_NAME" => "postgres:///#{ prometheus_database } ?host=/run/postgresql&port=#{ details [ :port ] } &user=prometheus&password= #{ URI . encode_www_form_component ( passwords [ 'prometheus' ] ) } "
144145 restrict_address_families "AF_UNIX"
145- remove_ipc false
146146 subscribes :restart , "template[/etc/prometheus/exporters/postgres_queries.yml]"
147147 end
148148
You can’t perform that action at this time.
0 commit comments