added additionalNodeSelector to manifestgen options

Signed-off-by: Phil Nichol <35630607+philnichol@users.noreply.github.com>
This commit is contained in:
Phil Nichol 2022-02-11 00:05:15 +00:00
parent 877729aca3
commit f4ac38987e
No known key found for this signature in database
GPG key ID: 998C1F11E05F7B14
2 changed files with 21 additions and 17 deletions

View file

@ -19,23 +19,24 @@ package install
import "time" import "time"
type Options struct { type Options struct {
BaseURL string BaseURL string
Version string Version string
Namespace string Namespace string
Components []string Components []string
ComponentsExtra []string ComponentsExtra []string
EventsAddr string EventsAddr string
Registry string Registry string
ImagePullSecret string ImagePullSecret string
WatchAllNamespaces bool WatchAllNamespaces bool
NetworkPolicy bool NetworkPolicy bool
LogLevel string LogLevel string
NotificationController string NotificationController string
ManifestFile string ManifestFile string
Timeout time.Duration Timeout time.Duration
TargetPath string TargetPath string
ClusterDomain string ClusterDomain string
TolerationKeys []string TolerationKeys []string
AdditionalNodeSelectors map[string]string
} }
func MakeDefaultOptions() Options { func MakeDefaultOptions() Options {

View file

@ -133,6 +133,9 @@ spec:
spec: spec:
nodeSelector: nodeSelector:
kubernetes.io/os: linux kubernetes.io/os: linux
{{- range $k, $v := .AdditionalNodeSelectors }}
{{$k}}: "{{$v}}"
{{- end }}
{{- if .ImagePullSecret }} {{- if .ImagePullSecret }}
imagePullSecrets: imagePullSecrets:
- name: {{.ImagePullSecret}} - name: {{.ImagePullSecret}}