[Checkins] SVN: zc.zope3recipes/dev/zc/zope3recipes/ When using a
deployment, include the deployment name in installed rc
Jim Fulton
jim at zope.com
Thu Jan 11 17:38:56 EST 2007
Log message for revision 71945:
When using a deployment, include the deployment name in installed rc
script names.
Changed:
U zc.zope3recipes/dev/zc/zope3recipes/README.txt
U zc.zope3recipes/dev/zc/zope3recipes/recipes.py
-=-
Modified: zc.zope3recipes/dev/zc/zope3recipes/README.txt
===================================================================
--- zc.zope3recipes/dev/zc/zope3recipes/README.txt 2007-01-11 22:31:20 UTC (rev 71944)
+++ zc.zope3recipes/dev/zc/zope3recipes/README.txt 2007-01-11 22:38:56 UTC (rev 71945)
@@ -959,9 +959,12 @@
The control script is in the init.d directory:
>>> ls(root, 'etc', 'init.d')
- - instance
+ - myapp-run-instance
-and the configuration files will be changed to reflect the deployment
+Note that the deployment name is added as a prefix of the control
+script name.
+
+The configuration files have changed to reflect the deployment
locations:
>>> cat(root, 'etc', 'myapp-run', 'instance-zope.conf')
Modified: zc.zope3recipes/dev/zc/zope3recipes/recipes.py
===================================================================
--- zc.zope3recipes/dev/zc/zope3recipes/recipes.py 2007-01-11 22:31:20 UTC (rev 71944)
+++ zc.zope3recipes/dev/zc/zope3recipes/recipes.py 2007-01-11 22:38:56 UTC (rev 71945)
@@ -169,8 +169,9 @@
self.name+'-access.log')
socket_path = os.path.join(run_directory,
self.name+'-zdaemon.sock')
+ rc = deployment + '-' + self.name
creating = [zope_conf_path, zdaemon_conf_path,
- os.path.join(options['bin-directory'], self.name),
+ os.path.join(options['bin-directory'], rc),
]
else:
zope_conf_path = os.path.join(run_directory, 'zope.conf')
@@ -178,8 +179,9 @@
event_log_path = os.path.join(run_directory, 'z3.log')
access_log_path = os.path.join(run_directory, 'access.log')
socket_path = os.path.join(run_directory, 'zdaemon.sock')
+ rc = self.name
creating = [run_directory,
- os.path.join(options['bin-directory'], self.name),
+ os.path.join(options['bin-directory'], rc),
]
if not os.path.exists(run_directory):
os.mkdir(run_directory)
@@ -260,7 +262,7 @@
open(zdaemon_conf_path, 'w').write(str(zdaemon_conf))
zc.buildout.easy_install.scripts(
- [(self.name, 'zc.zope3recipes.ctl', 'main')],
+ [(rc, 'zc.zope3recipes.ctl', 'main')],
ws, options['executable'], options['bin-directory'],
extra_paths = [this_loc],
arguments = ('['
More information about the Checkins
mailing list