Skip to content

Add vtysh.conf file to image - #3

Merged
russellb merged 1 commit into
openshift:masterfrom
mccv1r0:vtysh
Nov 2, 2021
Merged

Add vtysh.conf file to image#3
russellb merged 1 commit into
openshift:masterfrom
mccv1r0:vtysh

Conversation

@mccv1r0

@mccv1r0 mccv1r0 commented Nov 1, 2021

Copy link
Copy Markdown
Contributor

Add vtysh.conf file to image
Signed-off-by: Michael Cambria mcambria@redhat.com

Comment thread vtysh.conf Outdated
Signed-off-by: Michael Cambria <mcambria@redhat.com>
@msherif1234

Copy link
Copy Markdown
Contributor

/lgtm

@msherif1234

Copy link
Copy Markdown
Contributor

/approve

@russellb
russellb merged commit 9e07bfc into openshift:master Nov 2, 2021
@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Nov 2, 2021
fedepaol added a commit to fedepaol/frr that referenced this pull request Jan 17, 2024
openshift-merge-bot Bot pushed a commit that referenced this pull request Aug 9, 2026
Four independent bugs in `charts/frr-k8s/values.schema.json` that
together leave strictly-shaped chart inputs unvalidated, reject
documented inputs, and bury a large `frrk8s` block in a schema-ignored
position. Single-file diff.

1. JSON property key typo: `"resources:"` (with trailing colon).

   Pre-fix the property name under `frrk8s.frr.properties` had a stray
   colon, so the `resources` map under `frrk8s.frr` was effectively
   unschema'd. Rename to `"resources"`, matching the sibling shapes
   `frrk8s.reloader.resources`, `frrk8s.frrMetrics.resources`,
   `frrk8s.frrStatus.resources` in the same file.

2. `prometheus.serviceMonitor.interval` schema mismatch.

   Pre-fix declared `anyOf: integer | null`, but the Prometheus
   convention for scrape intervals is a duration string (`"30s"`,
   `"1m"`, etc.) and `charts/frr-k8s/README.md:86` already documents
   the field as `string`. Operators who set
   `prometheus.serviceMonitor.interval: 30s` were rejected by
   `helm template` with a schema error. Widen to
   `anyOf: string | null`.

3. `crds` block misplaced under `prometheus`.

   Pre-fix the `crds` schema lived at `properties.prometheus.crds`.
   JSON Schema silently ignores unknown sibling keys, so the entire
   top-level `crds` map in `values.yaml` was unvalidated —
   `crds.enabled: "not_a_bool"` was accepted without complaint. Move
   it to `properties.crds`; the schema now catches type errors on
   `crds.enabled` and constrains `crds.validationFailurePolicy` to
   the documented enum `Ignore | Fail`.

4. `frrk8s` block misplaced under `prometheus`.

   Pre-fix an entire `frrk8s` definition (`tolerateMaster`,
   `updateStrategy`, `runtimeClassName`, `secretName`, `frr.{image,
   metricsPort, secureMetricsPort, resources}`, `command`, `reloader`,
   `frrMetrics`) lived at `properties.prometheus.frrk8s` — a sibling
   of `properties` inside the `prometheus` block. Same JSON-Schema
   silent-ignore as #3: the chart's actual `frrk8s.*` values went
   unvalidated. Merge the misplaced block into the existing top-level
   `properties.frrk8s` (which previously held only `strategy`,
   `command`, `webhookMode`). The `frr.required: [enabled]` rule is
   dropped during the move because the chart's own `values.yaml` does
   not set `frrk8s.frr.enabled` — enforcing it would reject the chart's
   default render with a confusing "missing property" error, which the
   pre-fix schema avoided by being in a position the validator
   ignored.

Verified locally (helm v3.18 and v3.21):

Pre-fix:

- `helm template ... --set prometheus.serviceMonitor.interval=30s` →
  rejected ("got string, want integer").
- `helm template ... --set crds.enabled=not_a_bool` → silently accepted.
- `helm template ... --set frrk8s.tolerateMaster=not_a_bool` → silently
  accepted.

Post-fix:

- `interval=30s` → accepted.
- `crds.enabled=not_a_bool` → rejected:
  `at '/crds/enabled': got string, want boolean`.
- `frrk8s.tolerateMaster=not_a_bool` → rejected:
  `at '/frrk8s/tolerateMaster': got string, want boolean`.
- Default `helm template charts/frr-k8s --set crds.enabled=true` renders
  cleanly (42 documents, 0 errors).
- `helm lint charts/frr-k8s --set crds.enabled=true` clean.

Signed-off-by: Aleksei Sviridkin <f@lex.la>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants