This project contains Ansible code that creates a baseline in an existing Kubernetes environment for use with the SAS Viya Platform, generates the manifest for an order, and then can also deploy that order into the Kubernetes environment specified.
Apache License 2.0
71
stars
64
forks
source link
fix: (IAC-938) filestore directory doesn't get created w/o V4_CFG_MANAGE_STORAGE #405
The entry for V4_CFG_MANAGE_STORAGE in CONFIG-VARS.md indicates that it defaults to true but is not required. This PR ensures that if a value for V4_CFG_MANAGE_STORAGE has not been defined in ansible-vars or via a command line flag, it will be set to true. Validation checks were added to fail and exit with a message for empty or unsupported values.
Tests
Verified these scenarios, see internal ticket for additional details:
Scenario
Method
Description
tags
Order
Verification
1
ansible
V4_CFG_MANAGE_STORAGE not defined in ansible-vars and not specified on command line
"baseline,cluster-monitoring,install"
2023.02
DAC sets V4_CFG_MANAGE_STORAGE=true, nfs-subdir-external-provisioner creates both storageClasses, v4m storage class is created
2
ansible
V4_CFG_MANAGE_STORAGE not defined in ansible-vars and not specified on command line
"viya,install"
2023.02
DAC sets V4_CFG_MANAGE_STORAGE=true, jump-server-role create folders task runs as expected, verified astores, bin, data, homes folders exist under /export location, verified sas-cas-server-default-controller pod successfully mounted /export/deploy/data and /export/deploy/homes
3
ansible
V4_CFG_MANAGE_STORAGE not defined in ansible-vars and not specified on command line
"baseline,cluster-monitoring,viya,uninstall"
2023.02
DAC sets V4_CFG_MANAGE_STORAGE=true, successful uninstall of all installed components
4
ansible
V4_CFG_MANAGE_STORAGE defined as false in ansible-vars and not specified on command line
"baseline,install"
2023.02
skip nfs-subdir-external-provisioner deployment, no storage classes created
5
ansible
V4_CFG_MANAGE_STORAGE defined as false in ansible-vars and V4_CFG_MANAGE_STORAGE override specified as true on command line
"baseline,install"
2023.02
nfs-subdir-external-provisioner creates both storageClasses
6
ansible
V4_CFG_MANAGE_STORAGE defined as false in ansible-vars and V4_CFG_MANAGE_STORAGE override specified as true on command line
"cluster-monitoring,install"
2023.02
v4m storage class created, cluster-monitoring successfully installed with PVCs bound to v4m SC for alertmanager, prometheus and granfana
7
ansible
V4_CFG_MANAGE_STORAGE defined as false in ansible-vars and V4_CFG_MANAGE_STORAGE override specified as true on command line
"baseline,cluster-monitoring,uninstall"
2023.02
successful uninstall of all installed components
8
ansible
V4_CFG_MANAGE_STORAGE not defined in ansible-vars and V4_CFG_MANAGE_STORAGE override specified as false on command line
"baseline,install"
2023.02
skip nfs-subdir-external-provisioner deployment, no storage classes created
9
ansible
V4_CFG_MANAGE_STORAGE defined as true in ansible-vars and not specified on command line
"baseline,cluster-monitoring,install"
2023.02
nfs-subdir-external-provisioner creates both storageClasses, v4m storage class created, cluster-monitoring successfully installed with PVCs bound to v4m SC for alertmanager, prometheus and granfana
10
ansible
V4_CFG_MANAGE_STORAGE defined as true in ansible-vars and V4_CFG_MANAGE_STORAGE override specified as '' on command line
"baseline,install"
2023.02
DAC exits with message "V4_CFG_MANAGE_STORAGE is defined but empty, supported values are true or false."
11
ansible
V4_CFG_MANAGE_STORAGE defined as true in ansible-vars and V4_CFG_MANAGE_STORAGE override specified as 'ture' on command line
"baseline,install"
2023.02
DAC exits with message "The value provided for V4_CFG_MANAGE_STORAGE is unsupported, supported values are true or false."
Changes
The entry for V4_CFG_MANAGE_STORAGE in CONFIG-VARS.md indicates that it defaults to true but is not required. This PR ensures that if a value for V4_CFG_MANAGE_STORAGE has not been defined in ansible-vars or via a command line flag, it will be set to true. Validation checks were added to fail and exit with a message for empty or unsupported values.
Tests