Misleading error message and also missing directory check in check_args() function
The check_args() function in script(common.sh) displaying a hardcoded error message stating:
This script expects to find a kustomization in [env_name] directory to generate management-cluster configuration and secrets.
This message was misleading because:
- The validation logic applies to both management(via
apply.sh) and workload clusters(viaapply-workload-cluster.sh). - It incorrectly implies the script is specific to management clusters.
- It does not distinguish between different failure causes, such as: Missing directory
Edited by manik bindlish