Skip to content

Commit 4154973

Browse files
Removing unnessary values from values template file
1 parent a058be0 commit 4154973

File tree

5 files changed

+12
-29
lines changed

5 files changed

+12
-29
lines changed
Lines changed: 4 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,11 @@
11
agent:
2-
namespaceOverride: ntnx-system
3-
name: nutanix-agent
4-
port: 8080
5-
image:
6-
repository: docker.io/vijayaraghavanr31
7-
name: nke-k8s-agent
8-
pullPolicy: IfNotPresent
9-
tag: "688-14"
10-
privateRegistry: false
11-
imageCredentials:
12-
dockerconfig: replace_base64_encoded_creds
13-
updateConfigInMin: 10
14-
updateMetricsInMin: 360
15-
config:
16-
registration:
17-
delete:
18-
force: false
19-
kubeconfig:
20-
delete:
21-
force: false
2+
name: {{ .AgentName}}
223

234
pc:
245
port: {{ .PrismCentralPort }}
256
insecure: {{ .PrismCentralInsecure }} #set this to true if PC does not have https enabled
267
endpoint: {{ .PrismCentralHost }} # eg: ip or fqdn
27-
username: "admin" # eg: admin or any other user with Kubernetes Infrastructure provision role
28-
password: "Nutanix.123"
298
k8sClusterName: {{ .ClusterName }}
30-
k8sDistribution: "CAPX" # eg: CAPX or NKE or OCP or EKSA or NKP
31-
categoryMappings: "" # "one or more comma separated key=value" eg: "key1=value1" or "key1=value1\,key2=value2"
9+
10+
createSecret: false
11+

charts/cluster-api-runtime-extensions-nutanix/templates/helm-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ data:
3434
k8s-registration-agent: |
3535
ChartName: nutanix-k8s-agent
3636
ChartVersion: 0.0.1-alpha.1
37-
RepositoryURL: '{{ if .Values.helmRepository.enabled }}oci://helm-repository.{{ .Release.Namespace }}.svc/charts{{ else }}http://192.168.1.3:8080{{ end }}'
37+
RepositoryURL: '{{ if .Values.helmRepository.enabled }}oci://helm-repository.{{ .Release.Namespace }}.svc/charts{{ else }}http://192.168.1.16:8080{{ end }}'
3838
local-path-provisioner-csi: |
3939
ChartName: local-path-provisioner
4040
ChartVersion: 0.0.31

hack/addons/helm-chart-bundler/repos.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ repositories:
6262
nutanix-csi-storage:
6363
- 3.3.4
6464
nutanix-k8s-agent:
65-
repoURL: http://192.168.1.3:8080
65+
repoURL: http://192.168.1.16:8080
6666
charts:
6767
nutanix-k8s-agent:
6868
- 0.0.1-alpha.1

hack/addons/kustomize/k8s-registration-agent/kustomization.yaml.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ helmCharts:
1111
- name: nutanix-k8s-agent
1212
namespace: kube-system
1313
#repo: https://mesosphere.github.io/charts/stable
14-
repo: http://192.168.1.3:8080
14+
repo: http://192.168.1.16:8080
1515
releaseName: k8s-registration-agent
1616
version: ${K8S_REGISTRATION_AGENT_VERSION}
1717
includeCRDs: true

pkg/handlers/generic/lifecycle/k8sregistrationagent/handler.go

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ import (
3131
const (
3232
defaultHelmReleaseName = "k8s-registration-agent"
3333
defaultHelmReleaseNamespace = "ntnx-system"
34-
defaultCredentialsSecretName = "nutanix-k8s-agent-credentials"
34+
defaultK8sAgentName = "nutanix-agent"
35+
defaultCredentialsSecretName = defaultK8sAgentName
3536
)
3637

3738
type ControllerConfig struct {
@@ -149,7 +150,7 @@ func (n *DefaultK8sRegistrtionAgent) apply(
149150
return
150151
}
151152

152-
// 🔹 Ensure credentials are provided
153+
// Ensure credentials are provided
153154
if k8sAgentVar.Credentials == nil {
154155
resp.SetStatus(runtimehooksv1.ResponseStatusFailure)
155156
resp.SetMessage("name of the Secret containing PC credentials must be set")
@@ -300,6 +301,7 @@ func templateValuesFunc(
300301
}
301302

302303
type input struct {
304+
AgentName string
303305
PrismCentralHost string
304306
PrismCentralPort uint16
305307
PrismCentralInsecure bool
@@ -311,6 +313,7 @@ func templateValuesFunc(
311313
return "", err
312314
}
313315
templateInput := input{
316+
AgentName: defaultK8sAgentName,
314317
PrismCentralHost: address,
315318
PrismCentralPort: port,
316319
PrismCentralInsecure: nutanixConfig.PrismCentralEndpoint.Insecure,

0 commit comments

Comments
 (0)