Commit 7d4a92f6 authored by Richard Jones's avatar Richard Jones

Make ZEO instances that actually work:

 - the scripts won't be in the user's $PATH, so override that lookup
   in from mkzeoinst.py in the mkzeoinstance script
 - the scripts won't be executable, so prepend commands with $python
parent 8a622f0b
...@@ -25,13 +25,17 @@ if softwarehome not in sys.path: ...@@ -25,13 +25,17 @@ if softwarehome not in sys.path:
from ZEO.mkzeoinst import ZEOInstanceBuilder from ZEO.mkzeoinst import ZEOInstanceBuilder
class InstanceBuilder(ZEOInstanceBuilder): class InstanceBuilder(ZEOInstanceBuilder):
def get_params(self, *args, **kw): def get_params(self, home, port):
params = ZEOInstanceBuilder.get_params(self, *args, **kw) return {
sw = os.path.join(softwarehome, "lib", "python") "package": "zeo",
params["server"] = os.path.join(sw, "ZEO", "runzeo.py") "PACKAGE": "ZEO",
params["zdrun"] = os.path.join(sw, "zdaemon", "zdrun.py") "home": home,
params["zdctl"] = os.path.join(sw, "zdaemon", "zdctl.py") "port": port,
return params "python": sys.executable,
"server": os.path.join(softwarehome, "ZEO", "runzeo.py"),
"zdrun": os.path.join(softwarehome, "zdaemon", "zdrun.py"),
"zdctl": os.path.join(softwarehome, "zdaemon", "zdctl.py"),
}
if __name__ == "__main__": if __name__ == "__main__":
InstanceBuilder().run() InstanceBuilder().run()
...@@ -1061,3 +1061,4 @@ distutils.core.setup( ...@@ -1061,3 +1061,4 @@ distutils.core.setup(
"bin/mkzeoinstance", "bin/mkzopeinstance"], "bin/mkzeoinstance", "bin/mkzopeinstance"],
distclass=ZopeDistribution, distclass=ZopeDistribution,
) )
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment