Skip to content
This repository has been archived by the owner on Oct 22, 2021. It is now read-only.

fix: disable routing api under eirini, not supported #1469

Merged
merged 1 commit into from
Oct 9, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions chart/config/unsupported.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ unsupported:
Don't use properties.diego-cell.garden.grootfs.reserved_space_for_other_jobs_in_mb.
Use sizing.diego_cell.ephemeral_disk.size to set the amount of disk available to the cell.

features.routing_api.enabled && features.eirini.enabled: |
Cannot activate routing-api for eirini. It is not yet supported by this scheduler.

features.embedded_database.enabled && features.external_database.enabled: |
Cannot simultaneously activate both features.embedded_database and features.external_database.

Expand Down
4 changes: 4 additions & 0 deletions chart/templates/_features.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,8 @@
{{- else }}
{{- $_ := merge $.Values (dict "features" (dict "external_blobstore" (dict "enabled" false))) }}
{{- end}}
{{- /* Fix routing_api to proper (per-scheduler) default when not overriden by user */}}
{{- if kindIs "invalid" $.Values.features.routing_api.enabled }}
{{- $_ := set $.Values.features.routing_api "enabled" (not $.Values.features.eirini.enabled) }}
{{- end }}
{{- end }}
9 changes: 9 additions & 0 deletions chart/values.schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,15 @@ properties:
password: {type: string}
additionalProperties: false
additionalProperties: false

routing_api:
type: object
properties:
enabled:
oneOf:
- type: boolean
- type: 'null'

additionalProperties:
type: object
properties:
Expand Down
3 changes: 2 additions & 1 deletion chart/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,8 @@ features:
routing_api:
# Enable the routing API. Disabling this will also disable TCP routing, which is used for TCP
# port forwarding.
enabled: true
# Enabled by default, except under Eirini, where the routing-api is not (yet) supported.
enabled: ~
embedded_database:
# Enable the embedded database. If this is disabled, then features.external_database should be
# configured to use an external database.
Expand Down
3 changes: 3 additions & 0 deletions scripts/image_list.rb
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,9 @@ def initialize(chart:, values:)
# Eirini will throw an error unless a compatible stack is selected
if values['features']['eirini']['enabled']
values['install_stacks'] = ['sle15']
# Chart will throw an error when trying to use both eirini and
# routing_api. Avoid.
values['features']['routing_api']['enabled'] = false
end
Tempfile.open(['values-', '.yaml']) do |values_file|
values_file.write values.to_yaml
Expand Down