Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
Zope
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
Zope
Commits
4c3c975b
Commit
4c3c975b
authored
Feb 20, 2009
by
Hanno Schlichting
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed the specification of `SOFTWARE_HOME` and `ZOPE_HOME` from the standard instance scripts.
parent
909c3558
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
18 additions
and
49 deletions
+18
-49
doc/CHANGES.txt
doc/CHANGES.txt
+4
-0
src/Zope2/utilities/mkzopeinstance.py
src/Zope2/utilities/mkzopeinstance.py
+4
-5
src/Zope2/utilities/skel/bin/runzope.bat.in
src/Zope2/utilities/skel/bin/runzope.bat.in
+2
-5
src/Zope2/utilities/skel/bin/runzope.in
src/Zope2/utilities/skel/bin/runzope.in
+2
-6
src/Zope2/utilities/skel/bin/zopectl.bat.in
src/Zope2/utilities/skel/bin/zopectl.bat.in
+2
-5
src/Zope2/utilities/skel/bin/zopectl.in
src/Zope2/utilities/skel/bin/zopectl.in
+2
-6
src/Zope2/utilities/skel/bin/zopeservice.py.in
src/Zope2/utilities/skel/bin/zopeservice.py.in
+1
-20
src/Zope2/utilities/skel/etc/zope.conf.in
src/Zope2/utilities/skel/etc/zope.conf.in
+0
-1
src/nt_svcutils/service.py
src/nt_svcutils/service.py
+1
-1
No files found.
doc/CHANGES.txt
View file @
4c3c975b
...
...
@@ -23,6 +23,10 @@ Known issues
Restructuring
+++++++++++++
- Removed the specification of `SOFTWARE_HOME` and `ZOPE_HOME` from the
standard instance scripts.
[hannosch]
- Made the specification of `SOFTWARE_HOME` and `ZOPE_HOME` optional. In
addition `INSTANCE_HOME` is no longer required to run the tests of a
source checkout of Zope.
...
...
src/Zope2/utilities/mkzopeinstance.py
View file @
4c3c975b
...
...
@@ -29,7 +29,6 @@ to create a Zope instance home.
import
getopt
import
os
import
shutil
import
sys
import
copyzopeskel
...
...
@@ -81,8 +80,6 @@ def main():
)
instancehome
=
skeltarget
zopehome
=
os
.
path
.
dirname
(
os
.
path
.
dirname
(
script
))
softwarehome
=
os
.
path
.
join
(
zopehome
,
"src"
)
configfile
=
os
.
path
.
join
(
instancehome
,
'etc'
,
'zope.conf'
)
if
skelsrc
is
None
:
# default to using stock Zope skeleton source
...
...
@@ -113,12 +110,14 @@ def main():
# we're on UNIX or we have a nonstandard Windows setup
PYTHON
=
PYTHONW
=
sys
.
executable
import
Zope2
zope2path
=
os
.
path
.
realpath
(
os
.
path
.
dirname
(
Zope2
.
__file__
))
kw
=
{
"PYTHON"
:
PYTHON
,
"PYTHONW"
:
PYTHONW
,
"INSTANCE_HOME"
:
instancehome
,
"SOFTWARE_HOME"
:
softwarehome
,
"ZOPE_HOME"
:
zopehome
,
"ZOPE2PATH"
:
zope2path
,
}
copyzopeskel
.
copyskel
(
skelsrc
,
skeltarget
,
None
,
None
,
**
kw
)
...
...
src/Zope2/utilities/skel/bin/runzope.bat.in
View file @
4c3c975b
@set
ZOPE_HOME=<<ZOPE_HOME
>>
@set
PYTHON=<<PYTHON
>>
@set INSTANCE_HOME=<<INSTANCE_HOME>>
@set PYTHON=%ZOPE_HOME%\bin\python.exe
@set SOFTWARE_HOME=%ZOPE_HOME%\lib\python
@set CONFIG_FILE=%INSTANCE_HOME%\etc\zope.conf
@set PYTHONPATH=%SOFTWARE_HOME%
@set ZOPE_RUN=%SOFTWARE_HOME%\Zope2\Startup\run.py
@set ZOPE_RUN=<<ZOPE2PATH>>\Zope2\Startup\run.py
"%PYTHON%" "%ZOPE_RUN%" -C "%CONFIG_FILE%" %1 %2 %3 %4 %5 %6 %7
src/Zope2/utilities/skel/bin/runzope.in
View file @
4c3c975b
#! /bin/sh
PYTHON
=
"<<PYTHON>>"
ZOPE_HOME
=
"<<ZOPE_HOME>>"
INSTANCE_HOME
=
"<<INSTANCE_HOME>>"
CONFIG_FILE
=
"<<INSTANCE_HOME>>/etc/zope.conf"
SOFTWARE_HOME
=
"<<SOFTWARE_HOME>>"
PYTHONPATH
=
"
$SOFTWARE_HOME
:
$PYTHONPATH
"
export
PYTHONPATH INSTANCE_HOME SOFTWARE_HOME
export
INSTANCE_HOME
ZOPE2PATH
=
`
${
PYTHON
}
-c
"import os, Zope2; print os.path.dirname(Zope2.__file__)"
`
ZOPE_RUN
=
"
$ZOPE2PATH
/Startup/run.py"
ZOPE_RUN
=
"<<ZOPE2PATH>>/Startup/run.py"
exec
"
$PYTHON
"
"
$ZOPE_RUN
"
-C
"
$CONFIG_FILE
"
"
$@
"
src/Zope2/utilities/skel/bin/zopectl.bat.in
View file @
4c3c975b
@set
ZOPE_HOME=<<ZOPE_HOME
>>
@set
PYTHON=<<PYTHON
>>
@set INSTANCE_HOME=<<INSTANCE_HOME>>
@set PYTHON=%ZOPE_HOME%\bin\python.exe
@set SOFTWARE_HOME=%ZOPE_HOME%\lib\python
@set CONFIG_FILE=%INSTANCE_HOME%\etc\zope.conf
@set PYTHONPATH=%SOFTWARE_HOME%
@set ZDCTL=%SOFTWARE_HOME%\Zope2\Startup\zopectl.py
@set ZDCTL=<<ZOPE2PATH>>\Zope2\Startup\zopectl.py
"%PYTHON%" "%ZDCTL%" -C "%CONFIG_FILE%" %1 %2 %3 %4 %5 %6 %7
src/Zope2/utilities/skel/bin/zopectl.in
View file @
4c3c975b
#! /bin/sh
PYTHON
=
"<<PYTHON>>"
ZOPE_HOME
=
"<<ZOPE_HOME>>"
INSTANCE_HOME
=
"<<INSTANCE_HOME>>"
CONFIG_FILE
=
"<<INSTANCE_HOME>>/etc/zope.conf"
SOFTWARE_HOME
=
"<<SOFTWARE_HOME>>"
PYTHONPATH
=
"
$SOFTWARE_HOME
:
$PYTHONPATH
"
export
PYTHONPATH INSTANCE_HOME SOFTWARE_HOME
export
INSTANCE_HOME
ZOPE2PATH
=
`
${
PYTHON
}
-c
"import os, Zope2; print os.path.dirname(Zope2.__file__)"
`
ZDCTL
=
"
$ZOPE2PATH
/Startup/zopectl.py"
ZDCTL
=
"<<ZOPE2PATH>>/Startup/zopectl.py"
exec
"
$PYTHON
"
"
$ZDCTL
"
-C
"
$CONFIG_FILE
"
"
$@
"
src/Zope2/utilities/skel/bin/zopeservice.py.in
View file @
4c3c975b
...
...
@@ -82,33 +82,14 @@ import sys, os
# these are replacements from mkzopeinstance
PYTHON = r'<<PYTHON>>'
SOFTWARE_HOME=r'<<SOFTWARE_HOME>>'
INSTANCE_HOME = r'<<INSTANCE_HOME>>'
ZOPE_HOME = r'<<ZOPE_HOME>>'
ZOPE_RUN = r'
%s\Zope2\Startup\run.py' % SOFTWARE_HOME
ZOPE_RUN = r'
<<ZOPE2PATH>>\Zope2\Startup\run.py'
CONFIG_FILE= os.path.join(INSTANCE_HOME, 'etc', 'zope.conf')
PYTHONSERVICE_EXE=r'%s\bin\PythonService.exe' % ZOPE_HOME
# Setup the environment, so sub-processes see these variables
for check_dir in (os.path.join(SOFTWARE_HOME, 'third_party', 'docutils', 'extras'),
os.path.join(SOFTWARE_HOME, 'third_party', 'docutils'),
SOFTWARE_HOME,
):
parts = os.environ.get("PYTHONPATH", "").split(os.pathsep)
if check_dir not in parts:
parts = filter(None, [check_dir] + parts)
os.environ["PYTHONPATH"] = os.pathsep.join(parts)
os.environ["INSTANCE_HOME"] = INSTANCE_HOME
# Ensure SOFTWARE_HOME is on our current sys.path so we can import the
# nt_svcutils package. Note we don't need the docutils dirs in sys.path, as
# only Zope itself (our child process) uses it, and that happens via
# PYTHONPATH
if SOFTWARE_HOME not in sys.path:
sys.path.insert(0, SOFTWARE_HOME)
from nt_svcutils.service import Service
servicename = 'Zope_%s' % str(hash(INSTANCE_HOME.lower()))
...
...
src/Zope2/utilities/skel/etc/zope.conf.in
View file @
4c3c975b
...
...
@@ -23,7 +23,6 @@
# ZConfig "defines" used for later textual substitution
%define INSTANCE <<INSTANCE_HOME>>
%define ZOPE <<ZOPE_HOME>>
# Directive: instancehome
#
...
...
src/nt_svcutils/service.py
View file @
4c3c975b
...
...
@@ -372,5 +372,5 @@ class Service(win32serviceutil.ServiceFramework):
# Real __main__ bootstrap code is in the instance's service module.
if
__name__
==
'__main__'
:
print
"This is a framework module - you don't run it directly."
print
"See your
$SOFTWARE_HOME
\
b
i
n directory for the service script."
print
"See your
installatio
n directory for the service script."
sys
.
exit
(
1
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment