Skip to content

Commit

Permalink
Stop trying to URI encode passwords
Browse files Browse the repository at this point in the history
  • Loading branch information
tomhughes committed Oct 15, 2023
1 parent a07b42e commit 3c04971
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions cookbooks/postgresql/recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@
# limitations under the License.
#

require "uri"

include_recipe "apt::postgresql"
include_recipe "munin"
include_recipe "prometheus"
Expand Down Expand Up @@ -141,7 +139,7 @@
--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
Expand Down

0 comments on commit 3c04971

Please sign in to comment.