Skip to content

Harbor: model the new per-component replicas fields (upstream cozystack#4880) #70

Open

Description

@mattia-eleuteri

Upstream cozystack/cozystack#4880 adds a replicas field to four components of the harbor app: nginx.replicas, portal.replicas, core.replicas and registry.replicas. Above one replica the chart also adds a PodDisruptionBudget and spreads the replicas by the platform's globalAppTopologySpreadConstraints (or softly across zones and nodes when it is unset), so these are the knobs that make the registry survive the loss of a node or zone.

The provider models Harbor by hand, internal/provider/harbor_schema.go plus the model and its expand/flatten pair in harbor_model.go, so once the chart ships, these fields can't be set or read through Terraform.

Shape: an Optional integer under each of nginx, portal, core and registry, chart default 1. nginx and portal are new objects in the schema; core and registry already exist with resources and resourcesPreset. If the provider restates the default, it has to be 1; otherwise expand can leave the field out and let the API apply it.

The same PR only rewords the descriptions of database.replicas and redis.replicas (spread above one replica); their type and default do not change.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions