summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBarry Warsaw2012-10-31 17:38:40 +0100
committerBarry Warsaw2012-10-31 17:38:40 +0100
commitbd0ef3ad263630ce27af52374780a14c10c0a69a (patch)
tree8a126f73baf901c97103e5e971df461471f0d85a
parente60c151e0148c2f53eabe883f5921378ca6a845c (diff)
parent3189b984e68fafdffba8a5ee57816902eafd5f91 (diff)
downloadmailman-bd0ef3ad263630ce27af52374780a14c10c0a69a.tar.gz
mailman-bd0ef3ad263630ce27af52374780a14c10c0a69a.tar.zst
mailman-bd0ef3ad263630ce27af52374780a14c10c0a69a.zip
-rw-r--r--src/mailman/commands/cli_control.py10
-rw-r--r--src/mailman/docs/NEWS.rst2
2 files changed, 9 insertions, 3 deletions
diff --git a/src/mailman/commands/cli_control.py b/src/mailman/commands/cli_control.py
index 8349feb60..b5a79b820 100644
--- a/src/mailman/commands/cli_control.py
+++ b/src/mailman/commands/cli_control.py
@@ -121,7 +121,11 @@ class Start:
os.setsid()
# Instead of cd'ing to root, cd to the Mailman runtime directory.
# However, before we do that, set an environment variable used by the
- # subprocesses to calculate their path to the $VAR_DIR.
+ # subprocesses to calculate their path to the $VAR_DIR. Before we
+ # chdir() though, calculate the absolute path to the configuration
+ # file.
+ config_path = (os.path.abspath(args.config)
+ if args.config else None)
os.environ['MAILMAN_VAR_DIR'] = config.VAR_DIR
os.chdir(config.VAR_DIR)
# Exec the master watcher.
@@ -131,8 +135,8 @@ class Start:
]
if args.force:
execl_args.append('--force')
- if args.config:
- execl_args.extend(['-C', args.config])
+ if config_path:
+ execl_args.extend(['-C', config_path])
qlog.debug('starting: %s', execl_args)
os.execl(*execl_args)
# We should never get here.
diff --git a/src/mailman/docs/NEWS.rst b/src/mailman/docs/NEWS.rst
index 892cc52c4..392eccea6 100644
--- a/src/mailman/docs/NEWS.rst
+++ b/src/mailman/docs/NEWS.rst
@@ -55,6 +55,8 @@ Commands
* `bin/mailman aliases` loses the `--output`, `--format`, and `--simple`
arguments, and adds a `--directory` argument. This is necessary to support
the Postfix `relay_domains` support.
+ * `bin/mailman start` was passing the wrong relative path to its runner
+ subprocesses when -C was given. LP: #982551
3.0 beta 2 -- "Freeze"