# HG changeset patch # User Paul Boddie # Date 1455028732 0 # Node ID eb14e37b12e0446be9342011ed069207782a2aa6 # Parent d69a4520413174a2971be490afe639c93975d088 Added the url_complete setting for wikifarms using complete site URLs. diff -r d69a45204131 -r eb14e37b12e0 moinsetup.py --- a/moinsetup.py Tue Feb 09 15:30:38 2016 +0100 +++ b/moinsetup.py Tue Feb 09 14:38:52 2016 +0000 @@ -417,7 +417,7 @@ site_config_names = ( "web_app_dir", "web_site_dir", "web_static_dir", - "url_path", "static_url_path" + "url_complete", "url_path", "static_url_path" ) # NOTE: Potentially detect Web server credentials. @@ -436,7 +436,7 @@ web_app_dir=None, web_static_dir=None, web_site_dir=None, web_user=None, web_group=None, common_dir=None, farm_config=None, site_config=None, - url_path=None, static_url_path=None, + url_complete=None, url_path=None, static_url_path=None, superuser=None, site_name=None, site_identifier=None, front_page_name=None, theme_default=None): @@ -470,6 +470,9 @@ 'common_dir' setting) * site_config - optional: a specific configuration file location (overrides the 'common_dir' setting) + * url_complete - optional: the complete URL at which the Wiki + will be made available by a wikifarm (such as + https://moinmo.in/ or http://my.wiki/Mine) * url_path - the URL path at which the Wiki will be made available (such as / or /mywiki) * static_url_path - optional: the URL path at which static resources @@ -504,6 +507,8 @@ if not self.web_app_dir: raise TypeError, "The 'web_app_dir' setting must be specified." + self.url_complete = url_complete + # Strip any trailing "/" from the URL path. if not url_path: @@ -1631,7 +1636,7 @@ path = self._set_pythonpath() installer = join(self.prefix_site_packages, "MoinMoin", "packages.py") - cmd = "%s %s i %s %s" % (sys.executable, installer, package_filename, self.url_path) + cmd = "%s %s i %s %s" % (sys.executable, installer, package_filename, self.url_complete or self.url_path) os.system(cmd) self._reset_pythonpath(path)