Description
Hosting and administrative tasks for Zope application server / Plone server.
The command for Zope tasks is bin/instance in buildout based Plones.
List available command:
bin/instance help
For older Plone releases, the command is zopectl.
You need to do this when you forget admin password or the database is damaged.
Add user with Zope Manager permissions:
bin/instance adduser <user_name> <user_password>
Add to [instance] in buildout.cfg:
zope-conf-additional=
<environment>
TZ Europe/Helsinki
</environment>
You might want to keep your production buildout.cfg and development configuration in sync automatically as possible.
A good idea is to use same buildout.cfg on every environment. If conditional things, like setting debug mode on, are needed, you can extend the buildout sections, which in turn create “additional Zopes” under bin/ folder:
[instance]
recipe = plone.recipe.zope2instance
zope2-location = ${zope2:location}
user = admin:x
http-address = 8080
debug-mode = off
verbose-security = off
...
environment=
PTS_LANGUAGES=en fi
#
# Create a launcher script which will start one Zope instance in debug mode
#
[debug-instance]
# Extend the main production instance
<= instance
# Here override specific settings to make the instance run in debug mode
debug-mode = on
verbose-security = on
event-log-level = DEBUG
And now you can start your development Zope as:
bin/debug-instance fg
And your main Zope instance stays in production mode:
bin/instance
ノート
Using fg switch foces Zope always into debug mode, but does not concern log level.
Zope has a component called VirtualHostMonster which does the virtual host mapping inside the Zope.
In the case you have set virtual hosting rules so that Zope does no longer allow you to access the management interface, you can add _SUPPRESS_ACCESSRULE” to the URL to disable VirtualHostMonster.
Zope application server offers copying parts of the tree structure via import/export feature. Exported file is basically a Python pickle containing the chosen node and all child nodes.
Importable .zexp files must be placed on /parts/instance/import buildout folder on the server. If you are using clustered ZEO set-up, always run imports through a specific front-end instance by using direct port access. Note that parts folder structure is pruned on each buildout run.
When files are placed on the server to correct folder, Import/Export tab in ZMI will pick them up in the selection drop down. You do not need to restart Zope.
More information