Skip to content

[runwsgi] Cannot override [DEFAULT] section entries from the command line #938

@dwt

Description

@dwt

What I did:

Given a zope config like this:

[DEFAULT]
http_port = 8000

[app:zope]
use = egg:Zope#main
zope_conf = %(here)s/zope.conf

[pipeline:main]
pipeline =
    egg:Zope#httpexceptions
    zope

[server:main]
use = egg:waitress#main
host = 127.0.0.1
port = %(http_port)s

I tried overriding that value from the command line by calling runwsgi like this

runwsgi --verbose --debug instances/test/etc/wsgi.ini http_port=8001

I expected the resulting server to run on port 8001 - but it didn't and instead ran on DEFAULT.http_port.

What I expect to happen:

There should be a way to verride values from the command line while allowing a default value from the configuration file.

What actually happened:

Overriding not possible.

What version of Python and Zope/Addons I am using:

% python --version                                                                                                                            :(
Python 3.6.8
% pip list |grep -i zope
Zope                             5.1.1.dev0 /Users/dwt/Code/Projekte/zope4/Zope/src

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions