Truncate long host names for overrides
Long hostnames can cause the 63 char name limit to be exceeded. Truncate the hostname if hostname > 20 char. Change-Id: Ieb7e4dafb41d1fe3ab3d663d2614f75c814afee6
This commit is contained in:
parent
0730df5973
commit
48a0c09fea
@ -38,7 +38,13 @@ limitations under the License.
|
|||||||
{{- $current_dict := dict }}
|
{{- $current_dict := dict }}
|
||||||
|
|
||||||
{{/* set daemonset name */}}
|
{{/* set daemonset name */}}
|
||||||
|
{{/* Note: long hostnames can cause the 63 char name limit to be
|
||||||
|
exceeded. Truncate the hostname if hostname > 20 char */}}
|
||||||
|
{{- if gt (len $host_data.name) 20 }}
|
||||||
|
{{- $_ := set $current_dict "name" (substr 0 20 $host_data.name) }}
|
||||||
|
{{- else }}
|
||||||
{{- $_ := set $current_dict "name" $host_data.name }}
|
{{- $_ := set $current_dict "name" $host_data.name }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
{{/* apply overrides */}}
|
{{/* apply overrides */}}
|
||||||
{{- $override_conf_copy := $host_data.conf }}
|
{{- $override_conf_copy := $host_data.conf }}
|
||||||
|
Loading…
Reference in New Issue
Block a user