Skip to content

Commit

Permalink
Add a parameter for randomized password (#213)
Browse files Browse the repository at this point in the history
Signed-off-by: Vatsal Parekh <[email protected]>
  • Loading branch information
Vatsal Parekh authored Sep 17, 2020
1 parent f3cbbb8 commit 48b228a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 10 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
*.retry
dist
pvs
__pycache__
.idea
openshift.local.clusterup/
common-templates*.yaml
releases.json
Expand Down
9 changes: 0 additions & 9 deletions generate-templates.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
vars:
os: rhel8
icon: rhel
password: redhat
oslabels: "{{ rhel8_labels }}"
osinfoname: "{{ oslabels[0] }}"

Expand Down Expand Up @@ -60,7 +59,6 @@
vars:
os: rhel7
icon: rhel
password: redhat
oslabels: "{{ rhel7_labels }}"
osinfoname: "{{ oslabels[0] }}"

Expand All @@ -84,7 +82,6 @@
vars:
os: rhel6
icon: rhel
password: redhat
oslabels: "{{ rhel6_labels }}"
osinfoname: "{{ oslabels[0] }}"

Expand All @@ -104,7 +101,6 @@
vars:
os: centos8
icon: centos
password: centos
oslabels:
- centos8
osinfoname: "{{ oslabels[0] }}"
Expand All @@ -125,7 +121,6 @@
vars:
os: centos7
icon: centos
password: centos
oslabels:
- centos7.0
osinfoname: "{{ oslabels[0] }}"
Expand All @@ -146,7 +141,6 @@
vars:
os: centos6
icon: centos
password: centos
oslabels: "{{ centos6_labels }}"
osinfoname: "{{ oslabels[0] }}"

Expand Down Expand Up @@ -174,7 +168,6 @@
vars:
os: fedora
icon: fedora
password: fedora
oslabels: "{{ fedora_labels }}"
osinfoname: "{{ oslabels[0] }}"

Expand All @@ -190,7 +183,6 @@
vars:
os: opensuse
icon: opensuse
password: opensuse
oslabels:
- opensuse15.0
osinfoname: "{{ oslabels[0] }}"
Expand All @@ -208,7 +200,6 @@
vars:
os: ubuntu
icon: ubuntu
password: ubuntu
oslabels:
- ubuntu18.04
osinfoname: "{{ oslabels[0] }}"
Expand Down
6 changes: 5 additions & 1 deletion templates/_linux.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ objects:
- cloudInitNoCloud:
userData: |-
#cloud-config
password: {{ password }}
password: ${CLOUD_USER_PASSWORD}
chpasswd: { expire: False }
name: cloudinitdisk

Expand All @@ -120,3 +120,7 @@ parameters:
- name: SRC_PVC_NAMESPACE
description: Namespace of the source PVC
value: kubevirt-os-images
- description: Randomized password for cloud-user
from: '[a-z0-9]{4}-[a-z0-9]{4}-[a-z0-9]{4}'
generate: expression
name: CLOUD_USER_PASSWORD

0 comments on commit 48b228a

Please sign in to comment.