Thread: "make check" and pg_hba.conf
Is there a way to get "make check" to install a custom pg_hba.conf for its temporary installation? Something like pre-prending the line:
local all password_user md5
To the default pg_hba.conf?
Thanks,
Jeff
Jeff Janes <jeff.janes@gmail.com> writes: > Is there a way to get "make check" to install a custom pg_hba.conf for its > temporary installation? Something like pre-prending the line: > local all password_user md5 > To the default pg_hba.conf? No. Why would you want that? External connections to the test DB seem like exactly what you *don't* want, for reproducibility's sake. Also, this seems like it's overlapping with the use case for making an installation and using make installcheck. regards, tom lane
On Tue, Oct 18, 2016 at 2:28 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
Jeff Janes <jeff.janes@gmail.com> writes:
> Is there a way to get "make check" to install a custom pg_hba.conf for its
> temporary installation? Something like pre-prending the line:
> local all password_user md5
> To the default pg_hba.conf?
No. Why would you want that? External connections to the test DB seem
like exactly what you *don't* want, for reproducibility's sake.
I would want to do that so that the code dealing with password-based logins doesn't go completely untested by "make check", like it currently is.
I don't see how connecting to an obscure unix socket with a password is more "external" than connecting to the same obscure linux socket without a password.
Cheers,
Jeff
Jeff Janes <jeff.janes@gmail.com> writes: > On Tue, Oct 18, 2016 at 2:28 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote: >> No. Why would you want that? External connections to the test DB seem >> like exactly what you *don't* want, for reproducibility's sake. > I would want to do that so that the code dealing with password-based logins > doesn't go completely untested by "make check", like it currently is. Well, unless you create a user with a password and use that password to log in, you're not performing much of a test. Getting the hba entry in there seems to me to be about the least of the worries for making a usable test case. regards, tom lane
On 10/18/16 6:31 PM, Jeff Janes wrote: > I would want to do that so that the code dealing with password-based > logins doesn't go completely untested by "make check", like it currently is. Write a TAP test for it. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services