Skip to content

v0.3.0

Choose a tag to compare

@github-actions github-actions released this 29 Oct 13:42
· 76 commits to main since this release
f61315b

A namespaced install mode, the explanation history and notifications to one webhook, the last two
off by default. Breaking: the chart's rbac.scope is required on every install and upgrade.

Added

  • A namespaced install mode (0013. Offer a namespaced install mode: one watch pair and one Role
    per listed namespace, and nothing cluster-wide
    ):
    kausa run --namespace <NAME>, repeatable up to 32 times, watches only those namespaces, with
    one Pod watch and one event watch each; the chart's rbac.scope=namespaced with
    rbac.namespaces grants a Role and a RoleBinding in each listed namespace, passes the same list
    as --namespace, and creates nothing cluster-scoped. The started log line names the watched
    namespaces (namespaces, or null for the whole cluster), and pod watch error and
    event watch error name the namespace of the failing watch (namespace).
  • The explanation history, off by default (0014. Keep each incident's full explanations in a
    namespaced Explanation resource, off by default
    ):
    kausa run --history keeps each explained incident's whole explanations (up to five distinct
    texts, with counts and times) in an Explanation object named kausa.<fingerprint> in its
    namespace, and deletes those older than --history-days (1 to 30, default 7) or beyond 500
    objects. --history needs --endpoint and is refused with --dry-run. The chart's new
    history values (enabled: false, days: 7, installCRD: true, readers.aggregate: true)
    install the CustomResourceDefinition explanations.kausa.fedeam.com
    (charts/kausa/files/explanation-schema.json, v1alpha1), a reader ClusterRole aggregated to
    view, and the rule list, create, patch and delete on explanations, only while kausa
    writes history; turning it off or uninstalling deletes the CustomResourceDefinition and every
    Explanation. New counters kausa_history_writes_total{outcome},
    kausa_history_deleted_total{reason} and kausa_history_sweep_errors_total, and the log lines
    history write failed, history write refused, history sweep failed and history swept.
  • Notifications, off by default (0015. Post each new explanation to one optional webhook, as
    JSON, Slack or Telegram
    ): kausa run --notify-url-file <PATH>
    posts each new explanation, after its Event, to the webhook whose URL is in that file, as the
    documented json body (schema kausa.fedeam.com/notification/v1), a Slack incoming webhook's
    plain text or a Telegram sendMessage (--notify-format json|slack|telegram,
    --notify-telegram-chat-id, --notify-token-file for a bearer token with json,
    --notify-allow-http). Only the namespace's and the top-level owner's real names are sent;
    every other name stays a placeholder, and no field holds a log line or the request (Data sent
    in notifications
    ). Needs --endpoint; refused
    with --dry-run. The chart's new notifications values (enabled: false, format: json,
    existingSecret, urlKey: url, tokenKey, telegramChatId, allowHttp: false) mount the
    Secret that holds the URL, and networkPolicy.notifications (to, ports, TCP 443 by default)
    adds an egress rule; no RBAC change. New counters kausa_notifications_total{outcome} and
    kausa_notifications_retried_total, the log lines notification sent, notification retried,
    notification failed and notification dropped, and a notifications field in the started
    line. The Slack and Telegram formats are not yet tested against the real services.

Changed

  • The chart's rbac.scope is required (cluster or namespaced, no default): every
    helm install sets it, and so does the first helm upgrade of a release installed with an
    earlier chart (v0.2.0 or v0.1.0), --reuse-values included, since its stored values have
    none. --set rbac.scope=cluster keeps the ClusterRole and the whole-cluster watch. Without it,
    or with an invalid list, the chart refuses to render and Helm changes nothing, so a values
    reset can no longer widen a namespaced install to the whole cluster.
  • /readyz answers 200 once every watch has listed: the two of the whole cluster, or the two of
    each watched namespace. A watch refused with 403 drops the records it had brought in (its
    namespace's only) and lists again once access is back.
  • The chart's templates/clusterrole.yaml became templates/rbac.yaml, and its rules moved to the
    kausa.rules helper, which the ClusterRole and every Role render.
  • /metrics lists three more counters, 0 unless the history is on:
    kausa_history_writes_total, kausa_history_deleted_total and
    kausa_history_sweep_errors_total.

Fixed

  • A text of an explanation cut at its limit no longer ends in a space or in part of a
    <redacted:…> marker, and cleaning a cleaned text gives the same text: a character removed
    between two others can no longer leave a pair that Unicode normalization joins.

Install

helm install kausa https://github.com/fedeam/kausa/releases/download/v0.3.0/kausa-0.3.0.tgz \
  -n kausa --create-namespace --set rbac.scope=cluster --set dryRun=true

Image: ghcr.io/fedeam/kausa:0.3.0 (ghcr.io/fedeam/kausa@sha256:cbdaafbef5957ba9b199cdf17665ad81a8200ce1d55240aa5f7cece8eda7f72f), linux/amd64 and linux/arm64.

Verify

With cosign v3 or later and the GitHub CLI:

cosign verify ghcr.io/fedeam/kausa@sha256:cbdaafbef5957ba9b199cdf17665ad81a8200ce1d55240aa5f7cece8eda7f72f \
  --certificate-identity https://github.com/fedeam/kausa/.github/workflows/release.yml@refs/tags/v0.3.0 \
  --certificate-oidc-issuer https://token.actions.githubusercontent.com
gh attestation verify oci://ghcr.io/fedeam/kausa@sha256:cbdaafbef5957ba9b199cdf17665ad81a8200ce1d55240aa5f7cece8eda7f72f --repo fedeam/kausa
gh attestation verify kausa-0.3.0.tgz --repo fedeam/kausa \
  --bundle kausa-0.3.0.intoto.jsonl
cosign verify-blob SHA256SUMS --bundle SHA256SUMS.sigstore.json \
  --certificate-identity https://github.com/fedeam/kausa/.github/workflows/release.yml@refs/tags/v0.3.0 \
  --certificate-oidc-issuer https://token.actions.githubusercontent.com
sha256sum -c SHA256SUMS