Schedule icon
Request icon
Switch icon
SlackIncomingWebhook icon
If icon
Log icon

Zot OCI Registry Health & Image Catalog Sentinel

Audit Zot OCI container image registry health, track repository catalog depth, and alert via Slack to prevent Docker and Kubernetes image pull failures.

Categories
Infrastructure

Zot is a production-grade, vendor-neutral OCI (Open Container Initiative) image registry written in Go by the Linux Foundation and Cisco as a fast, secure, and lightweight alternative to Harbor or Docker Distribution. Designed for edge computing, Kubernetes clusters, and enterprise CI/CD environments, Zot provides full support for OCI distribution specs, Helm charts, and multi-architecture container artifacts. In busy CI/CD pipelines, automated build agents push hundreds of transient container tags and ephemeral test images weekly. If the registry distribution endpoint degrades or unmanaged repositories exhaust underlying volume storage, Docker daemon pushes stall and Kubernetes pods fail into ImagePullBackOff loops. This blueprint deploys an automated sentinel that verifies Zot daemon responsiveness, audits repository catalog growth against enterprise quotas, routes Slack alerts, and enforces safe operational safeguards.

How it works

  1. periodic_zot_audit (io.kestra.plugin.core.trigger.Schedule) initiates scheduled monitoring every 15 minutes. Shipped disabled so initial connectivity can be verified manually.
  2. probe_registry_v2_endpoint (io.kestra.plugin.core.http.Request) invokes GET /v2/ to ensure the core OCI distribution specification API is functional and responsive.
  3. probe_catalog_repositories (io.kestra.plugin.core.http.Request) invokes GET /v2/_catalog to inspect all hosted container image repositories.
  4. classify_registry_status (io.kestra.plugin.core.flow.Switch) analyzes probe results:
    • REGISTRY_UNAVAILABLE: Fires if /v2/ returns a non-200 code or network error, triggering an immediate incident notification via io.kestra.plugin.slack.notifications.SlackIncomingWebhook.
    • CATALOG_QUOTA_EXCEEDED: Fires when total hosted repositories exceed max_repository_count, warning the DevOps channel and evaluating safe cleanup logging.
    • HEALTHY: Confirms that the OCI registry is fully responsive and operating with healthy storage headroom.
  5. log_registry_audit_summary (io.kestra.plugin.core.log.Log) writes an immutable record of catalog depth and execution lineage.
  6. Global errors handler catches connection refusals or container crashes, firing an emergency alert to Slack.

What you get

  • Automated surveillance of Zot OCI registry responsiveness and container repository catalog growth.
  • Proactive alerts on Slack before repository bloat exhausts storage volumes and halts deployment pipelines.
  • Safe dry-run guarding: default dry_run: true prevents inadvertent image deletions or mutations during audits.
  • Comprehensive audit trail in Kestra tracking registry health history and repository inventory over time.

Who it's for

  • Platform Engineers and SREs maintaining internal container registries for edge nodes and Kubernetes clusters.
  • DevOps Teams operating continuous delivery pipelines pushing Docker and OCI images continuously.
  • Security and Infrastructure Teams auditing image repository inventories and container storage capacity.

Why orchestrate this with Kestra

Zot serves OCI API endpoints but does not feature native scheduled alerting, webhook routing, or conditional operational workflows. Using custom cron scripts introduces maintenance overhead, hard-coded secrets, and zero execution visibility. Kestra provides a declarative YAML workflow with native scheduling, credential masking, conditional branching, and full execution observability.

Prerequisites

  • A running Zot OCI registry instance (version 1.4.0+) accessible over HTTP. Zot provides an official open-source Docker image (ghcr.io/project-zot/zot-linux-amd64:latest) requiring zero commercial licensing.
  • An incoming Slack webhook URL for operational notifications.

Secrets

  • SLACK_WEBHOOK_URL: Slack incoming webhook URL for registry alerts and incident routing.

Quick start

  1. Start a local Zot OCI container registry container:
    docker run -d --name zot-test -p 5000:5000 ghcr.io/project-zot/zot-linux-amd64:latest
    
  2. Configure SLACK_WEBHOOK_URL in your Kestra namespace secrets.
  3. Import this blueprint into Kestra and run an execution with default inputs (dry_run: true).
  4. Confirm that log_healthy_state records a successful OCI ping and zero repository warnings.
  5. Test alerting by stopping the container (docker stop zot-test) and re-executing the flow to verify alert_zot_network_outage.
  6. Enable periodic_zot_audit to activate continuous 15-minute registry health monitoring.

How to extend

  • Add automated image vulnerability scanning triggers using Trivy via io.kestra.plugin.scripts.shell.Commands.
  • Integrate with PagerDuty using io.kestra.plugin.pagerduty.notifications.PagerDutyAlert for high-severity registry outages.
  • Add automated garbage collection tasks to purge untagged image blobs when storage thresholds are reached.

Links

See How

New to Kestra?

Use blueprints to kickstart your first workflows.