From aa18f704660d60f3b4a85bd177876f6be469047b Mon Sep 17 00:00:00 2001 From: Chris Fraser Date: Tue, 12 Jun 2018 05:00:48 -0700 Subject: [PATCH] If set, use LD_LIBRARY_PATH when starting postgres (#698) Fixes #697 --- patroni/postmaster.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patroni/postmaster.py b/patroni/postmaster.py index aa5f3050..fe46c0e1 100644 --- a/patroni/postmaster.py +++ b/patroni/postmaster.py @@ -137,7 +137,7 @@ class PostmasterProcess(psutil.Process): # of init process to take care about postmaster. # In order to make everything portable we can't use fork&exec approach here, so we will call # ourselves and pass list of arguments which must be used to start postgres. - env = {p: os.environ[p] for p in ('PATH', 'LC_ALL', 'LANG') if p in os.environ} + env = {p: os.environ[p] for p in ('PATH', 'LD_LIBRARY_PATH', 'LC_ALL', 'LANG') if p in os.environ} try: proc = PostmasterProcess._from_pidfile(data_dir) if proc and not proc._is_postmaster_process():