← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~cjwatson/launchpad:remove-launchpad-conf into launchpad:master

 

Colin Watson has proposed merging ~cjwatson/launchpad:remove-launchpad-conf into launchpad:master.

Commit message:
Remove launchpad.conf and all parsing of it

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/+git/launchpad/+merge/405900

It's no longer used with gunicorn.
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~cjwatson/launchpad:remove-launchpad-conf into launchpad:master.
diff --git a/configs/README.txt b/configs/README.txt
index 050b0f7..38e2893 100644
--- a/configs/README.txt
+++ b/configs/README.txt
@@ -23,10 +23,6 @@ make sure you inform the people in charge of those systems. You may wish
 to do this if you are adding a new required config option to
 launchpad-lazr.conf.
 
-The old ZConfig-based launchpad.conf files are still used to define
-servers and log files. These will be replaced when lazr.config is
-bootstrapped into the Zope startup process.
-
 
 == LaunchpadConfig ==
 
diff --git a/configs/development/launchpad.conf b/configs/development/launchpad.conf
deleted file mode 100644
index fe7e088..0000000
--- a/configs/development/launchpad.conf
+++ /dev/null
@@ -1,77 +0,0 @@
-
-# Identify the component configuration used to define the site:
-site-definition zcml/webapp.zcml
-
-# Turn on Zope3 developer mode.
-devmode on
-
-# number of bytecode instructions to execute between checks for
-# interruptions (SIGINTR, thread switches):
-interrupt-check-interval 200
-
-<server>
-  type HTTP
-  address 8085
-</server>
-
-# For debugging purposes, you can use this publisher instead/as well
-# (obviously if it's as well, use a different port number). If there's
-# an exception, Zope will drop into pdb at the point of the exception.
-<server>
-  type PostmortemDebuggingHTTP
-  address 8088
-</server>
-
-<server>
-  type DebugLayerHTTP
-  address 8086
-</server>
-
-<server>
-  type PrivateXMLRPC
-  address 8087
-</server>
-
-# non-persistent in-memory storage
-<zodb>
-  <mappingstorage/>
-</zodb>
-
-<accesslog>
-  # This sets up logging to both a file (access.log) and to standard
-  # output (STDOUT).  The "path" setting can be a relative or absolute
-  # filesystem path or the tokens STDOUT or STDERR.
-
-  <logfile>
-    path logs/launchpad-access.log
-  </logfile>
-
-  <logfile>
-    path STDOUT
-  </logfile>
-</accesslog>
-
-<eventlog>
-  # This sets up logging to both a file (z3.log) and to standard
-  # output (STDOUT).  The "path" setting can be a relative or absolute
-  # filesystem path or the tokens STDOUT or STDERR.
-
-  <logfile>
-    path logs/launchpad.log
-  </logfile>
-
-  <logfile>
-    path STDOUT
-  </logfile>
-</eventlog>
-
-<logger>
-  name zc.tracelog
-  propagate false
-
-  <logfile>
-    format %(message)s
-    path logs/trace.log
-  </logfile>
-
-</logger>
diff --git a/configs/replicated-development/launchpad.conf b/configs/replicated-development/launchpad.conf
deleted file mode 120000
index 394cf64..0000000
--- a/configs/replicated-development/launchpad.conf
+++ /dev/null
@@ -1 +0,0 @@
-../development/launchpad.conf
\ No newline at end of file
diff --git a/configs/test-playground/launchpad.conf b/configs/test-playground/launchpad.conf
deleted file mode 100644
index ec8095a..0000000
--- a/configs/test-playground/launchpad.conf
+++ /dev/null
@@ -1,77 +0,0 @@
-
-# Identify the component configuration used to define the site:
-site-definition zcml/webapp.zcml
-
-# Turn on Zope3 developer mode.
-devmode on
-
-# number of bytecode instructions to execute between checks for
-# interruptions (SIGINTR, thread switches):
-interrupt-check-interval 200
-
-<server>
-  type HTTP
-  address 8085
-</server>
-
-# For debugging purposes, you can use this publisher instead/as well
-# (obviously if it's as well, use a different port number). If there's
-# an exception, Zope will drop into pdb at the point of the exception.
-<server>
-  type PostmortemDebuggingHTTP
-  address 8089
-</server>
-
-<server>
-  type DebugLayerHTTP
-  address 8086
-</server>
-
-<server>
-  type PrivateXMLRPC
-  address 8087
-</server>
-
-# non-persistent in-memory storage
-<zodb>
-  <mappingstorage/>
-</zodb>
-
-<accesslog>
-  # This sets up logging to both a file (access.log) and to standard
-  # output (STDOUT).  The "path" setting can be a relative or absolute
-  # filesystem path or the tokens STDOUT or STDERR.
-
-  <logfile>
-    path logs/launchpad-access.log
-  </logfile>
-
-  <logfile>
-    path STDOUT
-  </logfile>
-</accesslog>
-
-<eventlog>
-  # This sets up logging to both a file (z3.log) and to standard
-  # output (STDOUT).  The "path" setting can be a relative or absolute
-  # filesystem path or the tokens STDOUT or STDERR.
-
-  <logfile>
-    path logs/launchpad.log
-  </logfile>
-
-  <logfile>
-    path STDOUT
-  </logfile>
-</eventlog>
-
-<logger>
-  name zc.tracelog
-  propagate false
-
-  <logfile>
-    format %(message)s
-    path logs/trace.log
-  </logfile>
-
-</logger>
diff --git a/configs/testrunner-appserver/launchpad.conf b/configs/testrunner-appserver/launchpad.conf
deleted file mode 100644
index 2f9ce03..0000000
--- a/configs/testrunner-appserver/launchpad.conf
+++ /dev/null
@@ -1,50 +0,0 @@
-# This configuration file is used by the AppServerLayer tests to simplify
-# configuring Launchpad for successful run of those tests.
-
-# Identify the component configuration used to define the site:
-site-definition zcml/webapp.zcml
-
-# Make this work a little more like production.
-devmode off
-
-# number of bytecode instructions to execute between checks for
-# interruptions (SIGINTR, thread switches):
-interrupt-check-interval 200
-
-<server>
-  type HTTP
-  address 8085
-</server>
-
-<server>
-  type PrivateXMLRPC
-  address 8087
-</server>
-
-# non-persistent in-memory storage
-<zodb>
-  <mappingstorage/>
-</zodb>
-
-<accesslog>
-  <logfile>
-    path logs/test-appserver-layer.log
-  </logfile>
-</accesslog>
-
-<eventlog>
-  <logfile>
-    path logs/test-appserver-layer.log
-  </logfile>
-</eventlog>
-
-<logger>
-  name zc.tracelog
-  propagate false
-
-  <logfile>
-    format %(message)s
-    path logs/test-appserver-layer-trace.log
-  </logfile>
-
-</logger>
diff --git a/configs/testrunner/launchpad.conf b/configs/testrunner/launchpad.conf
deleted file mode 100644
index e1aee02..0000000
--- a/configs/testrunner/launchpad.conf
+++ /dev/null
@@ -1,66 +0,0 @@
-
-# Identify the component configuration used to define the site:
-site-definition zcml/webapp.zcml
-
-# Turn on Zope3 developer mode.
-devmode on
-
-# number of bytecode instructions to execute between checks for
-# interruptions (SIGINTR, thread switches):
-interrupt-check-interval 200
-
-<server>
-  type HTTP
-  address 8085
-</server>
-
-# For debugging purposes, you can use this publisher instead/as well
-# (obviously if it's as well, use a different port number). If there's
-# an exception, Zope will drop into pdb at the point of the exception.
-<server>
-  type PostmortemDebuggingHTTP
-  address 8089
-</server>
-
-<server>
-  type DebugLayerHTTP
-  address 8086
-</server>
-
-<server>
-  type PrivateXMLRPC
-  address 8087
-</server>
-
-# non-persistent in-memory storage
-<zodb>
-  <mappingstorage/>
-</zodb>
-
-<accesslog>
-  # This sets up logging to both a file (access.log) and to standard
-  # output (STDOUT).  The "path" setting can be a relative or absolute
-  # filesystem path or the tokens STDOUT or STDERR.
-
-  <logfile>
-    path logs/launchpad-access.log
-  </logfile>
-
-  <logfile>
-    path STDOUT
-  </logfile>
-</accesslog>
-
-<eventlog>
-  # This sets up logging to both a file (z3.log) and to standard
-  # output (STDOUT).  The "path" setting can be a relative or absolute
-  # filesystem path or the tokens STDOUT or STDERR.
-
-  <logfile>
-    path logs/launchpad.log
-  </logfile>
-
-  <logfile>
-    path STDOUT
-  </logfile>
-</eventlog>
diff --git a/lib/lp/app/browser/launchpad.py b/lib/lp/app/browser/launchpad.py
index ebeb6d5..5ab3e0c 100644
--- a/lib/lp/app/browser/launchpad.py
+++ b/lib/lp/app/browser/launchpad.py
@@ -189,7 +189,7 @@ class NavigationMenuTabs(LaunchpadView):
         menuapi = MenuAPI(self.context)
         self.links = sorted([
             link for link in menuapi.navigation.values()
-            if (link.enabled or config.devmode)],
+            if (link.enabled or config.launchpad.devmode)],
             key=operator.attrgetter('sort_key'))
         self.title = None
         if len(self.links) > 0:
@@ -227,7 +227,7 @@ class LinkView(LaunchpadView):
 
     def render(self):
         """Render the menu link if it's enabled or we're in dev mode."""
-        if self.context.enabled or config.devmode:
+        if self.context.enabled or config.launchpad.devmode:
             # XXX: Tom Berger 2008-04-16 bug=218706:
             # We strip the result of the template rendering
             # since ZPT seems to always insert a line break
diff --git a/lib/lp/app/templates/base-layout-macros.pt b/lib/lp/app/templates/base-layout-macros.pt
index 9b2454a..99be57f 100644
--- a/lib/lp/app/templates/base-layout-macros.pt
+++ b/lib/lp/app/templates/base-layout-macros.pt
@@ -38,7 +38,7 @@
       revision modules/lp.app.versioninfo/revision | string:unknown;
       icingroot string:/+icing/rev${revision};
       combo_url view/combo_url;
-      devmode modules/lp.services.config/config/devmode;
+      devmode modules/lp.services.config/config/launchpad/devmode;
       yui_version view/yui_version;
       yui_console_debug view/yui_console_debug;"
   >
@@ -109,7 +109,7 @@
 
 <metal:page-javascript define-macro="page-javascript"
   tal:define="
-      devmode modules/lp.services.config/config/devmode;">
+      devmode modules/lp.services.config/config/launchpad/devmode;">
   <tal:comment replace="nothing">
     Load and initialize the common script used by all pages.
   </tal:comment>
diff --git a/lib/lp/app/templates/base-layout.pt b/lib/lp/app/templates/base-layout.pt
index 4eb0133..5e2d7a3 100644
--- a/lib/lp/app/templates/base-layout.pt
+++ b/lib/lp/app/templates/base-layout.pt
@@ -5,7 +5,7 @@
   tal:define="
     revision modules/lp.app.versioninfo/revision | string:unknown;
     display_revision modules/lp.app.versioninfo/display_revision | string:unknown;
-    devmode modules/lp.services.config/config/devmode;
+    devmode modules/lp.services.config/config/launchpad/devmode;
     rooturl modules/lp.services.webapp.vhosts/allvhosts/configs/mainsite/rooturl;
     is_demo modules/lp.services.config/config/launchpad/is_demo;
     is_lpnet modules/lp.services.config/config/launchpad/is_lpnet;
diff --git a/lib/lp/app/tests/test_tales.py b/lib/lp/app/tests/test_tales.py
index a3947dd..73a8464 100644
--- a/lib/lp/app/tests/test_tales.py
+++ b/lib/lp/app/tests/test_tales.py
@@ -85,7 +85,7 @@ def test_cookie_scope():
     The 'request/lp:cookie_scope' TALES expression returns a string
     that represents the scope parameters necessary for a cookie to be
     available for the entire Launchpad site.  It takes into account
-    the request URL and the cookie_domains setting in launchpad.conf.
+    the request URL and the cookie_domains setting in launchpad-lazr.conf.
 
         >>> from lp.app.browser.tales import RequestAPI
         >>> def cookie_scope(url):
diff --git a/lib/lp/bugs/doc/bugattachments.txt b/lib/lp/bugs/doc/bugattachments.txt
index 3925204..3e58d5f 100644
--- a/lib/lp/bugs/doc/bugattachments.txt
+++ b/lib/lp/bugs/doc/bugattachments.txt
@@ -148,7 +148,7 @@ and work with that:
     Cannot upload empty file.
 
 It's possible to limit the maximum size of the attachments by setting
-max_attachment_size in launchpad.conf. The default value for the
+max_attachment_size in launchpad-lazr.conf. The default value for the
 testrunner is 1024, so let's create a file larger than that and try to
 upload it:
 
diff --git a/lib/lp/bugs/doc/externalbugtracker.txt b/lib/lp/bugs/doc/externalbugtracker.txt
index 2dceb45..815d9db 100644
--- a/lib/lp/bugs/doc/externalbugtracker.txt
+++ b/lib/lp/bugs/doc/externalbugtracker.txt
@@ -663,12 +663,12 @@ Configuration Options
 ---------------------
 
 All ExternalBugTrackers have a batch_query_threshold attribute which is
-set by configuration options in launchpad.conf. This attribute is used
+set by configuration options in launchpad-lazr.conf. This attribute is used
 to decide whether or not bugs are exported from the remote server as a
 batch (where possible) or individually.
 
 The batch_query_threshold for a vanilla ExternalBugTracker should be the
-same as that specified in launchpad.conf. We use a test version of
+same as that specified in launchpad-lazr.conf. We use a test version of
 ExternalBugTracker here that doesn't actually do anything besides
 fulfill the implementation requirements of IExternalBugTracker.
 
diff --git a/lib/lp/bugs/stories/bugs/xx-bug-comment-attach-file.txt b/lib/lp/bugs/stories/bugs/xx-bug-comment-attach-file.txt
index 5d9b1e6..7d38b84 100644
--- a/lib/lp/bugs/stories/bugs/xx-bug-comment-attach-file.txt
+++ b/lib/lp/bugs/stories/bugs/xx-bug-comment-attach-file.txt
@@ -71,7 +71,7 @@ You cannot upload an empty attachment.
     Cannot upload empty file.
 
 The size of uploaded files is limited with the max_attachment_size
-option in launchpad.conf. In our example, the size is limited to 1024.
+option in launchpad-lazr.conf. In our example, the size is limited to 1024.
 
     >>> from lp.services.config import config
 
diff --git a/lib/lp/services/config/__init__.py b/lib/lp/services/config/__init__.py
index 2368d4a..0a0df59 100644
--- a/lib/lp/services/config/__init__.py
+++ b/lib/lp/services/config/__init__.py
@@ -14,7 +14,6 @@ __metaclass__ = type
 
 
 import glob
-import logging
 import os
 import random
 import sys
@@ -22,10 +21,6 @@ import sys
 from lazr.config import ImplicitTypeSchema
 from lazr.config.interfaces import ConfigErrors
 import six
-from six.moves.urllib.parse import (
-    urlparse,
-    urlunparse,
-    )
 
 from lp.services.osutils import open_for_writing
 from lp.services.propertycache import (
@@ -125,12 +120,6 @@ class LaunchpadConfig:
             self._process_name = process_name
         self._instance_name = instance_name
         self.root = TREE_ROOT
-        # Allow overriding Zope's config file.
-        # XXX pappacena 2021-01-21: We allow overriding this at runtime so
-        # we can do a painless transition to gunicorn. Once we are fully
-        # running gunicorn instead of zope server, this shouldn't be
-        # necessary anymore.
-        self._zope_config_file = None
 
     def _make_process_name(self):
         if getattr(sys, 'argv', None) is None:
@@ -245,25 +234,6 @@ class LaunchpadConfig:
                 text = f.read()
             self._config.push(path, text)
 
-    @property
-    def zope_config_file(self):
-        """Return the path to the ZConfig file for this instance."""
-        if self._zope_config_file is not None:
-            return self._zope_config_file
-        return os.path.join(self.config_dir, 'launchpad.conf')
-
-    @zope_config_file.setter
-    def zope_config_file(self, value):
-        self._zope_config_file = value
-
-    @property
-    def devmode(self):
-        """Devmode from launchpad-lazr.conf.
-
-        Copied here for ease of access.
-        """
-        return self.launchpad.devmode
-
     def generate_overrides(self):
         """Ensure correct config.zcml overrides will be called.
 
@@ -323,115 +293,6 @@ class LaunchpadConfig:
 config = LaunchpadConfig()
 
 
-def url(value):
-    '''ZConfig validator for urls
-
-    We enforce the use of protocol.
-
-    >>> url('http://localhost:8086')
-    'http://localhost:8086'
-    >>> url('im-a-file-but-not-allowed')
-    Traceback (most recent call last):
-        [...]
-    ValueError: No protocol in URL
-    '''
-    bits = urlparse(value)
-    if not bits[0]:
-        raise ValueError('No protocol in URL')
-    value = urlunparse(bits)
-    return value
-
-
-def urlbase(value):
-    """ZConfig validator for url bases
-
-    url bases are valid urls that can be appended to using urlparse.urljoin.
-
-    url bases always end with '/'
-
-    >>> urlbase('http://localhost:8086')
-    'http://localhost:8086/'
-    >>> urlbase('http://localhost:8086/')
-    'http://localhost:8086/'
-
-    URL fragments, queries and parameters are not allowed
-
-    >>> urlbase('http://localhost:8086/#foo')
-    Traceback (most recent call last):
-        [...]
-    ValueError: URL fragments not allowed
-    >>> urlbase('http://localhost:8086/?foo')
-    Traceback (most recent call last):
-        [...]
-    ValueError: URL query not allowed
-    >>> urlbase('http://localhost:8086/;blah=64')
-    Traceback (most recent call last):
-        [...]
-    ValueError: URL parameters not allowed
-
-    We insist on the protocol being specified, to avoid dealing with defaults
-    >>> urlbase('foo')
-    Traceback (most recent call last):
-        [...]
-    ValueError: No protocol in URL
-
-    File URLs specify paths to directories
-
-    >>> urlbase('file://bork/bork/bork')
-    'file://bork/bork/bork/'
-    """
-    value = url(value)
-    scheme, location, path, parameters, query, fragment = urlparse(value)
-    if parameters:
-        raise ValueError('URL parameters not allowed')
-    if query:
-        raise ValueError('URL query not allowed')
-    if fragment:
-        raise ValueError('URL fragments not allowed')
-    if not value.endswith('/'):
-        value = value + '/'
-    return value
-
-
-def commalist(value):
-    """ZConfig validator for a comma separated list"""
-    return [v.strip() for v in value.split(',')]
-
-
-def loglevel(value):
-    """ZConfig validator for log levels.
-
-    Input is a string ('info','debug','warning','error','fatal' etc.
-    as per logging module), and output is the integer value.
-
-    >>> import logging
-    >>> loglevel("info") == logging.INFO
-    True
-    >>> loglevel("FATAL") == logging.FATAL
-    True
-    >>> loglevel("foo")
-    Traceback (most recent call last):
-    ...
-    ValueError: ...
-    """
-    value = value.upper().strip()
-    if value == 'DEBUG':
-        return logging.DEBUG
-    elif value == 'INFO':
-        return logging.INFO
-    elif value == 'WARNING' or value == 'WARN':
-        return logging.WARNING
-    elif value == 'ERROR':
-        return logging.ERROR
-    elif value == 'FATAL':
-        return logging.FATAL
-    else:
-        raise ValueError(
-                "Invalid log level %s. "
-                "Should be DEBUG, CRITICAL, ERROR, FATAL, INFO, WARNING "
-                "as per logging module." % value)
-
-
 class DatabaseConfigOverrides(object):
     pass
 
diff --git a/lib/lp/services/config/tests/test_config.py b/lib/lp/services/config/tests/test_config.py
index 34921fd..ff81da8 100644
--- a/lib/lp/services/config/tests/test_config.py
+++ b/lib/lp/services/config/tests/test_config.py
@@ -12,10 +12,6 @@ from doctest import (
     ELLIPSIS,
     NORMALIZE_WHITESPACE,
     )
-try:
-    from importlib import resources
-except ImportError:
-    import importlib_resources as resources
 import os
 import unittest
 
@@ -24,7 +20,6 @@ from lazr.config import ConfigSchema
 from lazr.config.interfaces import ConfigErrors
 import scandir
 import testtools
-import ZConfig
 
 import lp.services.config
 from lp.services.config.fixture import ConfigUseFixture
@@ -33,23 +28,10 @@ from lp.services.config.fixture import ConfigUseFixture
 EXCLUDED_CONFIGS = ['lpnet-template']
 
 # Calculate some landmark paths.
-with resources.path('zope.app.server', 'schema.xml') as schema_file:
-    schema = ZConfig.loadSchema(str(schema_file))
-
 here = os.path.dirname(lp.services.config.__file__)
 lazr_schema_file = os.path.join(here, 'schema-lazr.conf')
 
 
-def make_test(config_file, description):
-    def test_function():
-        root, handlers = ZConfig.loadConfig(schema, config_file)
-    # Hack the config file name into test_function's __name__ so that the test
-    # -vv output is more informative. Unfortunately, FunctionTestCase's
-    # description argument doesn't do what we want.
-    test_function.__name__ = description
-    return unittest.FunctionTestCase(test_function)
-
-
 def make_config_test(config_file, description):
     """Return a class to test a single lazr.config file.
 
@@ -111,8 +93,6 @@ class TestLaunchpadConfig(testtools.TestCase):
                 [launchpad]
                 config_overlay_dir: ../%s
                 """ % os.path.basename(overlay_dir.path))
-        os.symlink(
-            '../testrunner/launchpad.conf', config_dir.join('launchpad.conf'))
 
         config = lp.services.config.config
 
@@ -160,11 +140,7 @@ def test_suite():
                 del dirnames[:]  # Don't look in subdirectories.
                 continue
             for filename in filenames:
-                if filename == 'launchpad.conf':
-                    config_file = os.path.join(dirpath, filename)
-                    description = os.path.relpath(config_file, config_dir)
-                    suite.addTest(make_test(config_file, description))
-                elif filename.endswith('-lazr.conf'):
+                if filename.endswith('-lazr.conf'):
                     # Test the lazr.config conf files.
                     config_file = os.path.join(dirpath, filename)
                     description = os.path.relpath(config_file, config_dir)
diff --git a/lib/lp/services/config/tests/test_config_lookup.py b/lib/lp/services/config/tests/test_config_lookup.py
index 8c160ab..ec4290c 100644
--- a/lib/lp/services/config/tests/test_config_lookup.py
+++ b/lib/lp/services/config/tests/test_config_lookup.py
@@ -90,13 +90,10 @@ class ConfigTestCase(TestCase):
             self.temp_config_root_dir, instance_name)
         os.mkdir(instance_config_dir)
 
-        # Create empty config files.
+        # Create an empty config file.
         open(
             os.path.join(instance_config_dir, 'launchpad-lazr.conf'),
             'w').close()
-        open(
-            os.path.join(instance_config_dir, 'launchpad.conf'),
-            'w').close()
         return instance_config_dir
 
 
diff --git a/lib/lp/services/config/tests/test_fixture.py b/lib/lp/services/config/tests/test_fixture.py
index 639d292..5f27e47 100644
--- a/lib/lp/services/config/tests/test_fixture.py
+++ b/lib/lp/services/config/tests/test_fixture.py
@@ -35,7 +35,6 @@ class TestConfigFixture(TestCase):
     def test_copies_and_derives(self):
         fixture = ConfigFixture('testtestconfig', 'testrunner')
         to_copy = [
-            'launchpad.conf',
             'test-process-lazr.conf',
             ]
         fixture.setUp()
diff --git a/lib/lp/services/webapp/authentication.py b/lib/lp/services/webapp/authentication.py
index 01e5e53..8204f41 100644
--- a/lib/lp/services/webapp/authentication.py
+++ b/lib/lp/services/webapp/authentication.py
@@ -150,7 +150,7 @@ class PlacelessAuthUtility:
     def unauthorized(self, id, request):
         """See IAuthentication."""
         a = ILoginPassword(request)
-        # TODO maybe configure the realm from zconfigure.
+        # TODO maybe configure the realm from launchpad-lazr.conf.
         a.needLogin(realm="launchpad")
 
     def getPrincipal(self, id):
diff --git a/lib/lp/services/webapp/doc/canonical_url.txt b/lib/lp/services/webapp/doc/canonical_url.txt
index b08a560..a4d8f21 100644
--- a/lib/lp/services/webapp/doc/canonical_url.txt
+++ b/lib/lp/services/webapp/doc/canonical_url.txt
@@ -258,7 +258,8 @@ and the objects it is inside of (or in other words, hierarchically below).
     >>> print(canonical_url(town_instance))
     http://launchpad.test/countries/England/+towns/London
 
-We can see that this is the mainsite rooturl as configured in launchpad.conf.
+We can see that this is the mainsite rooturl as configured in
+launchpad-lazr.conf.
 
     >>> from lp.services.webapp.vhosts import allvhosts
     >>> print(allvhosts.configs['mainsite'].rooturl)
diff --git a/lib/lp/services/webapp/doc/test_adapter.txt b/lib/lp/services/webapp/doc/test_adapter.txt
index bd8d2e0..f74065a 100644
--- a/lib/lp/services/webapp/doc/test_adapter.txt
+++ b/lib/lp/services/webapp/doc/test_adapter.txt
@@ -160,7 +160,7 @@ memory on logging.
 Statement Timeout
 =================
 
-The timeout is set in launchpad.conf file.  By default it is unset,
+The timeout is set in launchpad-lazr.conf.  By default it is unset,
 which corresponds to no timeout:
 
     >>> print(config.database.db_statement_timeout)
diff --git a/lib/lp/services/webapp/login.py b/lib/lp/services/webapp/login.py
index aca7b07..0e914f5 100644
--- a/lib/lp/services/webapp/login.py
+++ b/lib/lp/services/webapp/login.py
@@ -151,8 +151,8 @@ class BasicLoginPage(BrowserPage):
 
 def register_basiclogin(event):
     # The +basiclogin page should only be enabled for development and tests,
-    # but we can't rely on config.devmode because it's turned off for
-    # AppServerLayer tests, so we (ab)use the config switch for the test
+    # but we can't rely on config.launchpad.devmode because it's turned off
+    # for AppServerLayer tests, so we (ab)use the config switch for the test
     # OpenID provider, which has similar requirements.
     if config.launchpad.enable_test_openid_provider:
         getSiteManager().registerAdapter(
diff --git a/lib/lp/services/webapp/publisher.py b/lib/lp/services/webapp/publisher.py
index 6b76a7e..9fb9659 100644
--- a/lib/lp/services/webapp/publisher.py
+++ b/lib/lp/services/webapp/publisher.py
@@ -402,7 +402,7 @@ class LaunchpadView(UserAttributeCache):
         # We need to import here otherwise sitecustomize can't get imported,
         # likely due to some non-obvious circular import issues.
         from lp.services.config import config
-        return 'true' if config.devmode else 'false'
+        return 'true' if config.launchpad.devmode else 'false'
 
     @property
     def combo_url(self):
@@ -410,7 +410,7 @@ class LaunchpadView(UserAttributeCache):
         # Circular imports, natch.
         from lp.services.config import config
         combo_url = '/+combo'
-        if not config.devmode:
+        if not config.launchpad.devmode:
             combo_url += '/rev%s' % versioninfo.revision
         return combo_url
 
@@ -694,7 +694,7 @@ def canonical_url(
 
     :param request: The web request; if not provided, canonical_url attempts
         to guess at the current request, using the protocol, host, and port
-        taken from the root_url given in launchpad.conf.
+        taken from the root_url given in launchpad-lazr.conf.
     :param path_only_if_possible: If the protocol and hostname can be omitted
         for the current request, return a url containing only the path.
     :param view_name: Provide the canonical url for the specified view,
diff --git a/lib/lp/services/webapp/vhosts.py b/lib/lp/services/webapp/vhosts.py
index 8d8c1ff..0580f7a 100644
--- a/lib/lp/services/webapp/vhosts.py
+++ b/lib/lp/services/webapp/vhosts.py
@@ -30,7 +30,7 @@ class VirtualHostConfig:
     def _hostnameStrToList(althostnames):
         """Return list of hostname strings given a string of althostnames.
 
-        This is to parse althostnames from the launchpad.conf file.
+        This is to parse althostnames from the launchpad-lazr.conf file.
 
         Basically, it's a comma separated list, but we're quite flexible
         about what is accepted.  See the examples in the following doctest.
@@ -70,10 +70,10 @@ class AllVirtualHostsConfiguration:
     """
 
     def __init__(self):
-        """Initialize all virtual host settings from launchpad.conf.
+        """Initialize all virtual host settings from launchpad-lazr.conf.
 
         launchpad_conf_vhosts: The virtual_hosts config item from
-        launchpad.conf.
+        launchpad-lazr.conf.
 
         """
         self._has_vhost_data = False
diff --git a/requirements/launchpad.txt b/requirements/launchpad.txt
index 33d58a2..2904d84 100644
--- a/requirements/launchpad.txt
+++ b/requirements/launchpad.txt
@@ -170,12 +170,10 @@ WSGIProxy2==0.4.6
 wsgiref==0.1.2
 z3c.pt==3.2.0
 z3c.ptcompat==2.2.0
-zope.app.applicationcontrol==4.0.0
 zope.app.appsetup==4.1.0
 zope.app.http==4.0.1
 zope.app.publication==4.3.1
 zope.app.publisher==4.2.0
-zope.app.server==4.0.0
 zope.app.wsgi==4.3.0
 zope.server==4.0.2
 # lp:~launchpad-committers/zope.session:launchpad
diff --git a/scripts/gina.py b/scripts/gina.py
index 68ab92a..151c1bc 100755
--- a/scripts/gina.py
+++ b/scripts/gina.py
@@ -36,7 +36,7 @@ class Gina(LaunchpadCronScript):
 
     def add_my_options(self):
         self.parser.add_option("-a", "--all", action="store_true",
-            help="Run all sections defined in launchpad.conf (in order)",
+            help="Run all sections defined in launchpad-lazr.conf (in order)",
             dest="all", default=False)
         self.parser.add_option("-l", "--list-targets", action="store_true",
             help="List configured import targets", dest="list_targets",
diff --git a/setup.py b/setup.py
index 058a287..09fb9f4 100644
--- a/setup.py
+++ b/setup.py
@@ -255,7 +255,6 @@ setup(
         'zope.app.http',
         'zope.app.publication',
         'zope.app.publisher',
-        'zope.app.server',
         'zope.app.wsgi[testlayer]',
         'zope.authentication',
         'zope.browser',
diff --git a/utilities/lsconf.py b/utilities/lsconf.py
index 8eab198..7d7a62a 100755
--- a/utilities/lsconf.py
+++ b/utilities/lsconf.py
@@ -3,7 +3,7 @@
 # Copyright 2009 Canonical Ltd.  This software is licensed under the
 # GNU Affero General Public License version 3 (see the file LICENSE).
 
-"""Create lazr.config schema and confs from ZConfig data."""
+"""List an environment's lazr configuration."""
 
 from __future__ import absolute_import, print_function