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
0a9afd9d
Commit
0a9afd9d
authored
Jul 18, 2016
by
Hanno Schlichting
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed nt_svcutils support from zopectl.
parent
732f633c
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
3 additions
and
109 deletions
+3
-109
CHANGES.rst
CHANGES.rst
+3
-1
setup.py
setup.py
+0
-4
sources.cfg
sources.cfg
+0
-1
src/Zope2/Startup/zopectl.py
src/Zope2/Startup/zopectl.py
+0
-102
versions.cfg
versions.cfg
+0
-1
No files found.
CHANGES.rst
View file @
0a9afd9d
...
@@ -106,7 +106,9 @@ Features Added
...
@@ -106,7 +106,9 @@ Features Added
Restructuring
Restructuring
+++++++++++++
+++++++++++++
- Python 2.6 is no longer supported. Use Python 2.7.
- Removed nt_svcutils support from zopectl.
- Python 2.6 is no longer supported. Use Python 2.7.
- Products.SiteErrorLog: Is now a separated package.
- Products.SiteErrorLog: Is now a separated package.
...
...
setup.py
View file @
0a9afd9d
...
@@ -13,14 +13,10 @@
...
@@ -13,14 +13,10 @@
##############################################################################
##############################################################################
import
os
import
os
import
sys
from
setuptools
import
setup
,
find_packages
from
setuptools
import
setup
,
find_packages
additional_install_requires
=
[]
additional_install_requires
=
[]
if
sys
.
platform
[:
3
].
lower
()
==
"win"
:
additional_install_requires
+=
[
'nt_svcutils'
]
here
=
os
.
path
.
abspath
(
os
.
path
.
dirname
(
__file__
))
here
=
os
.
path
.
abspath
(
os
.
path
.
dirname
(
__file__
))
...
...
sources.cfg
View file @
0a9afd9d
...
@@ -16,7 +16,6 @@ five.globalrequest = git ${remotes:github}/five.globalrequest pushurl=${remotes:
...
@@ -16,7 +16,6 @@ five.globalrequest = git ${remotes:github}/five.globalrequest pushurl=${remotes:
initgroups = git ${remotes:github}/initgroups pushurl=${remotes:github_push}/initgroups
initgroups = git ${remotes:github}/initgroups pushurl=${remotes:github_push}/initgroups
Missing = git ${remotes:github}/Missing pushurl=${remotes:github_push}/Missing
Missing = git ${remotes:github}/Missing pushurl=${remotes:github_push}/Missing
MultiMapping = git ${remotes:github}/MultiMapping pushurl=${remotes:github_push}/MultiMapping
MultiMapping = git ${remotes:github}/MultiMapping pushurl=${remotes:github_push}/MultiMapping
nt_svcutils = git ${remotes:github}/nt_svcutils pushurl=${remotes:github_push}/nt_svcutils
Persistence = git ${remotes:github}/Persistence pushurl=${remotes:github_push}/Persistence
Persistence = git ${remotes:github}/Persistence pushurl=${remotes:github_push}/Persistence
Products.OFSP = git ${remotes:github}/Products.OFSP pushurl=${remotes:github_push}/Products.OFSP
Products.OFSP = git ${remotes:github}/Products.OFSP pushurl=${remotes:github_push}/Products.OFSP
Products.ZCatalog = git ${remotes:github}/Products.ZCatalog pushurl=${remotes:github_push}/Products.ZCatalog branch=master
Products.ZCatalog = git ${remotes:github}/Products.ZCatalog pushurl=${remotes:github_push}/Products.ZCatalog branch=master
...
...
src/Zope2/Startup/zopectl.py
View file @
0a9afd9d
...
@@ -58,43 +58,6 @@ if sys.version_info > (3, 0):
...
@@ -58,43 +58,6 @@ if sys.version_info > (3, 0):
WIN
=
False
WIN
=
False
if
sys
.
platform
[:
3
].
lower
()
==
"win"
:
if
sys
.
platform
[:
3
].
lower
()
==
"win"
:
WIN
=
True
WIN
=
True
import
pywintypes
import
win32service
import
win32serviceutil
from
nt_svcutils
import
service
def
do_windows
(
command
):
def
inner
(
self
,
arg
):
name
=
self
.
get_service_name
()
display_name
=
'Zope instance at '
+
self
.
options
.
directory
# This class exists only so we can take advantage of
# win32serviceutil.HandleCommandLine, it is never
# instantiated.
class
InstanceService
(
service
.
Service
):
_svc_name_
=
name
_svc_display_name_
=
display_name
_svc_description_
=
"A Zope application instance running as a service"
# getopt sucks :-(
argv
=
[
sys
.
argv
[
0
]]
argv
.
extend
(
arg
.
split
())
argv
.
append
(
command
)
# we need to supply this manually as HandleCommandLine guesses wrong
serviceClassName
=
os
.
path
.
splitext
(
service
.
__file__
)[
0
]
+
'.Service'
err
=
win32serviceutil
.
HandleCommandLine
(
InstanceService
,
serviceClassName
,
argv
=
argv
,
)
self
.
InstanceClass
=
InstanceService
return
err
return
inner
def
string_list
(
arg
):
def
string_list
(
arg
):
...
@@ -238,71 +201,6 @@ class ZopeCmd(ZDCmd):
...
@@ -238,71 +201,6 @@ class ZopeCmd(ZDCmd):
args
=
[
opt
,
svalue
]
args
=
[
opt
,
svalue
]
return
args
return
args
# START OF WINDOWS ONLY STUFF
if
WIN
:
def
get_service_name
(
self
):
return
'Zope'
+
str
(
hash
(
self
.
options
.
directory
.
lower
()))
def
get_status
(
self
):
sn
=
self
.
get_service_name
()
try
:
stat
=
win32serviceutil
.
QueryServiceStatus
(
sn
)[
1
]
self
.
zd_up
=
1
except
pywintypes
.
error
as
err
:
if
err
[
0
]
==
1060
:
# Service not installed
stat
=
win32service
.
SERVICE_STOPPED
self
.
zd_up
=
0
else
:
raise
self
.
zd_pid
=
(
stat
==
win32service
.
SERVICE_RUNNING
)
and
-
1
or
0
self
.
zd_status
=
"args=%s"
%
self
.
options
.
program
do_start
=
do_windows
(
'start'
)
do_stop
=
do_windows
(
'stop'
)
do_restart
=
do_windows
(
'restart'
)
# Add extra commands to install and remove the Windows service
def
do_install
(
self
,
arg
):
err
=
do_windows
(
'install'
)(
self
,
arg
)
if
not
err
:
# If we installed successfully, put info in registry for the
# real Service class to use:
command
=
'"%s" -C "%s"'
%
(
# This gives us the instance script for buildout instances
# and the install script for classic instances.
os
.
path
.
join
(
os
.
path
.
split
(
sys
.
argv
[
0
])[
0
],
'runzope'
),
self
.
options
.
configfile
)
self
.
InstanceClass
.
setReg
(
'command'
,
command
)
# This is unfortunately needed because runzope.exe is a
# setuptools generated .exe that spawns off a sub process,
# so pid would give us the wrong event name.
self
.
InstanceClass
.
setReg
(
'pid_filename'
,
self
.
options
.
configroot
.
pid_filename
)
return
err
def
help_install
(
self
):
print
(
"install -- Installs Zope as a Windows service."
)
do_remove
=
do_windows
(
'remove'
)
def
help_remove
(
self
):
print
(
"remove -- Removes the Zope Windows service."
)
do_windebug
=
do_windows
(
'debug'
)
def
help_windebug
(
self
):
print
(
"windebug -- Runs the Zope Windows service "
"in the foreground, in debug mode."
)
# END OF WINDOWS ONLY STUFF
def
get_startup_cmd
(
self
,
python
,
more
):
def
get_startup_cmd
(
self
,
python
,
more
):
cmdline
=
(
'%s -c "from Zope2 import configure;'
cmdline
=
(
'%s -c "from Zope2 import configure;'
'configure(%r);'
%
'configure(%r);'
%
...
...
versions.cfg
View file @
0a9afd9d
...
@@ -13,7 +13,6 @@ ExtensionClass = 4.1.2
...
@@ -13,7 +13,6 @@ ExtensionClass = 4.1.2
initgroups = 2.13.0
initgroups = 2.13.0
Missing = 3.1
Missing = 3.1
MultiMapping = 3.0
MultiMapping = 3.0
nt-svcutils = 2.13.0
Persistence = 3.0a1
Persistence = 3.0a1
Products.OFSP = 2.13.2
Products.OFSP = 2.13.2
Products.ZCatalog = 3.2
Products.ZCatalog = 3.2
...
...
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