10000 chore: set local TCP connections to 'trust' · robeng1/postgres@0332b87 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0332b87

Browse files
committed
chore: set local TCP connections to 'trust'
- solves the following issue: - citusdata/pg_cron#66 (comment)
1 parent 99da1a3 commit 0332b87

File tree

1 file changed

+35
-2
lines changed

1 file changed

+35
-2
lines changed

ansible/vars.yml

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,46 @@ postgresql_ext_postgis_version: 3
1515
postgresql_shared_preload_libraries:
1616
[pg_stat_statements, pgaudit, plpgsql, plpgsql_check, pg_cron]
1717

18-
postgresql_pg_hba_custom:
18+
postgresql_pg_hba_default:
19+
- {
20+
type: local,
21+
database: all,
22+
user: all,
23+
address: "",
24+
method: "{{ postgresql_default_auth_method }}",
25+
comment: '"local" is for Unix domain socket connections only'
26+
}
27+
- {
28+
type: host,
29+
database: all,
30+
user: all,
31+
address: "127.0.0.1/32",
32+
method: "trust",
33+
comment: "IPv4 local connections:"
34+
}
35+
- {
36+
type: host,
37+
database: all,
38+
user: all,
39+
address: "::1/128",
40+
method: "{{ postgresql_default_auth_method_hosts }}",
41+
comment: "IPv6 local connections:"
42+
}
43+
- {
44+
type: local,
45+
database: all,
46+
user: "{{ postgresql_admin_user }}",
47+
address: "",
48+
method: "peer map=root_as_{{ postgresql_admin_user }}",
49+
comment: "Local root Unix user, passwordless access"
50+
}
1951
- {
2052
type: "host",
2153
database: "all",
2254
user: "all",
2355
address: "0.0.0.0/0",
24-
method: "md5",
56+
method: "{{ postgresql_default_auth_method_hosts }}",
57+
comment: "IPv4 external connections"
2558
}
2659

2760
pgtap_release: "1.1.0"

0 commit comments

Comments
 (0)
0