Aligning to the recent changes for airshipctl

* Dependant airshipctl change
  https://review.opendev.org/c/airship/airshipctl/+/800722

 This PS fixes this issue:
  template: tmpl:9:78: executing "tmpl" at <.ephemeralCluster.ca.validity>:
  wrong type for value; expected int; got float64couldn't execute function: yaml: line 72:
  mapping values are not allowed in this context

Change-Id: I10960ba341e80c213f466c18a4a778fcedce61dc
This commit is contained in:
siraj.yasin 2021-08-13 14:02:42 +00:00 committed by Sirajudeen
parent 7e4710e9b3
commit 88182d2f77
1 changed files with 5 additions and 5 deletions

View File

@ -32,8 +32,8 @@ template: |
name: generated-secrets
annotations:
config.kubernetes.io/path: secrets.yaml
{{- $ephemeralClusterCa := genCAEx .ephemeralCluster.ca.subj .ephemeralCluster.ca.validity }}
{{- $ephemeralKubeconfigCert := genSignedCertEx .ephemeralCluster.kubeconfigCert.subj nil nil .ephemeralCluster.kubeconfigCert.validity $ephemeralClusterCa }}
{{- $ephemeralClusterCa := genCAEx .ephemeralCluster.ca.subj (int .ephemeralCluster.ca.validity) }}
{{- $ephemeralKubeconfigCert := genSignedCertEx .ephemeralCluster.kubeconfigCert.subj nil nil (int .ephemeralCluster.kubeconfigCert.validity) $ephemeralClusterCa }}
ephemeralClusterCa:
crt: {{ $ephemeralClusterCa.Cert|b64enc|quote }}
key: {{ $ephemeralClusterCa.Key|b64enc|quote }}
@ -41,8 +41,8 @@ template: |
certificate-authority-data: {{ $ephemeralClusterCa.Cert|b64enc|quote }}
client-certificate-data: {{ $ephemeralKubeconfigCert.Cert|b64enc|quote }}
client-key-data: {{ $ephemeralKubeconfigCert.Key|b64enc|quote }}
{{- $targetClusterCa := genCAEx .targetCluster.ca.subj .targetCluster.ca.validity }}
{{- $targetKubeconfigCert := genSignedCertEx .targetCluster.kubeconfigCert.subj nil nil .targetCluster.kubeconfigCert.validity $targetClusterCa }}
{{- $targetClusterCa := genCAEx .targetCluster.ca.subj (int .targetCluster.ca.validity) }}
{{- $targetKubeconfigCert := genSignedCertEx .targetCluster.kubeconfigCert.subj nil nil (int .targetCluster.kubeconfigCert.validity) $targetClusterCa }}
targetClusterCa:
tls.crt: {{ $targetClusterCa.Cert|b64enc|quote }}
tls.key: {{ $targetClusterCa.Key|b64enc|quote }}
@ -54,7 +54,7 @@ template: |
passwords:
root: {{ derivePassword 1 "long" (randAscii 10) "user" "airshipit.org"|quote }}
deployer: {{ derivePassword 1 "long" (randAscii 10) "user" "airshipit.org"|quote }}
{{- $sshKey := genSSHKeyPair .sshKeyGen.encBit }}
{{- $sshKey := genSSHKeyPair (int .sshKeyGen.encBit) }}
sshKeys:
privateKey: {{ $sshKey.Private|quote }}
publicKey: {{ $sshKey.Public|quote }}