]> git.openstreetmap.org Git - chef.git/commitdiff
Stop trying to URI encode passwords
authorTom Hughes <tom@compton.nu>
Sun, 15 Oct 2023 17:58:50 +0000 (18:58 +0100)
committerTom Hughes <tom@compton.nu>
Sun, 15 Oct 2023 17:58:50 +0000 (18:58 +0100)
cookbooks/postgresql/recipes/default.rb

index d2c94d1ed5dae55bcdbda2a9c2bac0e14092c874..1fe903022166d9304704a230fb236f854b227941 100644 (file)
@@ -17,8 +17,6 @@
 # limitations under the License.
 #
 
-require "uri"
-
 include_recipe "apt::postgresql"
 include_recipe "munin"
 include_recipe "prometheus"
@@ -141,7 +139,7 @@ clusters.each do |name, details|
       --collector.stat_wal_receiver
       --collector.statio_user_indexes
     ]
-    environment "DATA_SOURCE_NAME" => "postgres:///#{prometheus_database}?host=/run/postgresql&port=#{details[:port]}&user=prometheus&password=#{URI.encode_www_form_component(passwords['prometheus'])}"
+    environment "DATA_SOURCE_NAME" => "postgres:///#{prometheus_database}?host=/run/postgresql&port=#{details[:port]}&user=prometheus&password=#{passwords['prometheus']}"
     restrict_address_families "AF_UNIX"
     subscribes :restart, "template[/etc/prometheus/exporters/postgres_queries.yml]"
   end