Fix - added local targets to install host

By default when host is started, it should register targets to 'local', only if specific env var is set (OPENPYPE_REMOTE_PUBLISH) it should be 'remote'. This means
farm is using host to collect/validate/extract and publish on behalf of artist.
This commit is contained in:
Petr Kalis 2022-06-08 14:46:16 +02:00
parent e7937931e9
commit 56a3dae94b
4 changed files with 11 additions and 3 deletions

View file

@ -104,6 +104,14 @@ def install_host(host):
MessageHandler.emit = modified_emit
if os.environ.get("OPENPYPE_REMOTE_PUBLISH"):
# target "farm" == rendering on farm, expects OPENPYPE_PUBLISH_DATA
# target "remote" == remote execution, installs host
print("Registering pyblish target: remote")
pyblish.api.register_target("remote")
else:
pyblish.api.register_target("local")
install_openpype_plugins()