Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 257daa7

Browse files
authoredApr 23, 2025··
Require Erlang/OTP 25 for cacerts (#741)
1 parent 14a8a58 commit 257daa7

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed
 

‎.github/workflows/ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ jobs:
4444
- version: 14
4545

4646
pair:
47-
- elixir: 1.12
48-
otp: 24.3
47+
- elixir: 1.13
48+
otp: 25.3
4949
include:
5050
- pg:
5151
version: 14

‎lib/postgrex/protocol.ex

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,13 +93,14 @@ defmodule Postgrex.Protocol do
9393
{nil, opts}
9494

9595
{true, opts} ->
96-
Logger.warning(
97-
"setting ssl: true on your database connection offers only limited protection, " <>
98-
"as the server's certificate is not verified. Set \"ssl: [cacertfile: path/to/file]\" instead"
99-
)
96+
case Keyword.pop(opts, :ssl_opts) do
97+
{nil, _opts} ->
98+
[cacerts: :public_key.cacerts_get()] ++ default_ssl_opts()
10099

101-
# Read ssl_opts for backwards compatibility
102-
Keyword.pop(opts, :ssl_opts, [])
100+
{ssl_opts, opts} ->
101+
Logger.warning(":ssl_opts is deprecated, pass opts to :ssl instead")
102+
{ssl_opts, opts}
103+
end
103104

104105
{ssl_opts, opts} when is_list(ssl_opts) ->
105106
{Keyword.merge(default_ssl_opts(), ssl_opts), opts}

‎mix.exs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@ defmodule Postgrex.Mixfile do
22
use Mix.Project
33

44
@source_url "https://github.com/elixir-ecto/postgrex"
5-
@version "0.20.0"
5+
@version "0.21.0-dev"
66

77
def project do
88
[
99
app: :postgrex,
1010
version: @version,
11-
elixir: "~> 1.11",
11+
elixir: "~> 1.13",
1212
deps: deps(),
1313
name: "Postgrex",
1414
description: "PostgreSQL driver for Elixir",

0 commit comments

Comments
 (0)
Please sign in to comment.