diff --git a/api/v1alpha1/alluxiocluster_types.go b/api/v1alpha1/alluxiocluster_types.go index bf46fbd3d..a4f560e9f 100644 --- a/api/v1alpha1/alluxiocluster_types.go +++ b/api/v1alpha1/alluxiocluster_types.go @@ -100,6 +100,7 @@ type WorkerSpec struct { Affinity corev1.Affinity `json:"affinity,omitempty" yaml:"affinity,omitempty"` Count int `json:"count,omitempty" yaml:"count,omitempty"` Env map[string]string `json:"env,omitempty" yaml:"env,omitempty"` + HostPathForSystemInfo string `json:"hostPathForSystemInfo,omitempty" yaml:"hostPathForSystemInfo,omitempty"` JvmOptions []string `json:"jvmOptions,omitempty" yaml:"jvmOptions,omitempty"` LimitOneWorkerPerNode bool `json:"limitOneWorkerPerNode,omitempty" yaml:"limitOneWorkerPerNode,omitempty"` LivenessProbe ProbeSpec `json:"livenessProbe,omitempty" yaml:"livenessProbe,omitempty"` @@ -122,7 +123,7 @@ type PagestoreSpec struct { type MetastoreSpec struct { Enabled *bool `json:"enabled,omitempty" yaml:"enabled,omitempty"` - HostPath *bool `json:"hostPath,omitempty" yaml:"hostPath,omitempty"` + HostPath string `json:"hostPath,omitempty" yaml:"hostPath,omitempty"` Size string `json:"size,omitempty" yaml:"size,omitempty"` StorageClass string `json:"storageClass,omitempty" yaml:"storageClass,omitempty"` Type string `json:"type,omitempty" yaml:"type,omitempty"` diff --git a/deploy/charts/alluxio-operator/crds/k8s-operator.alluxio.com_alluxioclusters.yaml b/deploy/charts/alluxio-operator/crds/k8s-operator.alluxio.com_alluxioclusters.yaml index 39d6390c2..b79d6474a 100644 --- a/deploy/charts/alluxio-operator/crds/k8s-operator.alluxio.com_alluxioclusters.yaml +++ b/deploy/charts/alluxio-operator/crds/k8s-operator.alluxio.com_alluxioclusters.yaml @@ -4061,6 +4061,8 @@ spec: additionalProperties: type: string type: object + hostPathForSystemInfo: + type: string jvmOptions: items: type: string diff --git a/deploy/charts/alluxio/templates/worker/deployment.yaml b/deploy/charts/alluxio/templates/worker/deployment.yaml index ca6121d8b..b8e2d5107 100644 --- a/deploy/charts/alluxio/templates/worker/deployment.yaml +++ b/deploy/charts/alluxio/templates/worker/deployment.yaml @@ -250,7 +250,7 @@ spec: name: {{ $fullName }}-alluxio-conf - name: {{ $alluxioWorkerSysInfoVolumeName }} hostPath: - path: {{ $alluxioWorkerSysInfoDirPath }} + path: {{ .Values.worker.hostPathForSystemInfo }} type: DirectoryOrCreate {{- if .Values.hostPathForLogging }} - name: {{ $alluxioWorkerLogVolumeName }} diff --git a/deploy/charts/alluxio/values.yaml b/deploy/charts/alluxio/values.yaml index 25ff0f267..4e267900c 100644 --- a/deploy/charts/alluxio/values.yaml +++ b/deploy/charts/alluxio/values.yaml @@ -187,6 +187,8 @@ journal: worker: # Number of workers to launch count: 1 + # The path on the host machine for system information + hostPathForSystemInfo: /mnt/alluxio/system-info # The path on the host machine for storing worker log hostPathForLogs: /mnt/alluxio/logs/worker # Whether to limit at most one Alluxio worker per k8s node. diff --git a/resources/crds/k8s-operator.alluxio.com_alluxioclusters.yaml b/resources/crds/k8s-operator.alluxio.com_alluxioclusters.yaml index 39d6390c2..b79d6474a 100644 --- a/resources/crds/k8s-operator.alluxio.com_alluxioclusters.yaml +++ b/resources/crds/k8s-operator.alluxio.com_alluxioclusters.yaml @@ -4061,6 +4061,8 @@ spec: additionalProperties: type: string type: object + hostPathForSystemInfo: + type: string jvmOptions: items: type: string