diff --git a/pkg/manifestgen/install/options.go b/pkg/manifestgen/install/options.go index a456007b..e37b5e84 100644 --- a/pkg/manifestgen/install/options.go +++ b/pkg/manifestgen/install/options.go @@ -19,23 +19,24 @@ package install import "time" type Options struct { - BaseURL string - Version string - Namespace string - Components []string - ComponentsExtra []string - EventsAddr string - Registry string - ImagePullSecret string - WatchAllNamespaces bool - NetworkPolicy bool - LogLevel string - NotificationController string - ManifestFile string - Timeout time.Duration - TargetPath string - ClusterDomain string - TolerationKeys []string + BaseURL string + Version string + Namespace string + Components []string + ComponentsExtra []string + EventsAddr string + Registry string + ImagePullSecret string + WatchAllNamespaces bool + NetworkPolicy bool + LogLevel string + NotificationController string + ManifestFile string + Timeout time.Duration + TargetPath string + ClusterDomain string + TolerationKeys []string + AdditionalNodeSelectors map[string]string } func MakeDefaultOptions() Options { diff --git a/pkg/manifestgen/install/templates.go b/pkg/manifestgen/install/templates.go index ac47cf27..b92a7aa6 100644 --- a/pkg/manifestgen/install/templates.go +++ b/pkg/manifestgen/install/templates.go @@ -133,6 +133,9 @@ spec: spec: nodeSelector: kubernetes.io/os: linux +{{- range $k, $v := .AdditionalNodeSelectors }} + {{$k}}: "{{$v}}" +{{- end }} {{- if .ImagePullSecret }} imagePullSecrets: - name: {{.ImagePullSecret}}