OpenShift

Deployment

Back to listBack

OpenShift notifications in Zulip

This SDK integration targets the legacy OpenShift v2 gear and .openshift/action_hooks environment. It does not configure OpenShift 4; modern clusters need a separately verified pipeline step or message API adapter.

  1. Create a bot and deployments channel in your own organization.
  2. Install the zulip Python SDK and matching integrations/openshift scripts.
  3. Configure zulip_openshift_config.py: ZULIP_USER, ZULIP_API_KEY, ZULIP_SITE (your organization HTTPS URL), and optionally ZULIP_API_PATH.
  4. Configure deployment_notice_destination: defaults route main, master and test-post-receive to stream deployments with the branch as subject. Returning None suppresses a notification.
  5. In a compatible v2 environment, install executable post_deploy as .openshift/action_hooks/post_deploy. The inspected SDK has no post-receive file; do not symlink that nonexistent path.
  6. Test a deployment and verify its channel message and application link.

The script reads the second line of gear deployments and environment variables OPENSHIFT_APP_NAME and OPENSHIFT_APP_DNS. format_deployment_message controls the body. It calls /api/v1/messages, not /api/v1/external/openshift; webhook event filters do not apply. The script does not check the send_message result.

Testing

In a compatible environment, push a test deployment on test-post-receive before changing main, then check a real deployment notification. See OpenShift v2 action hooks.

Logos are trademarks of their respective owners. None of the integrations on this page are created by, affiliated with, or supported by the companies represented by the logos.