Skip to content
Snippets Groups Projects
Commit cd7db717 authored by Krish Moodbidri's avatar Krish Moodbidri
Browse files

Refactor conditional statement for TARGET_ENV comparison

Changed the conditional statement from using single brackets and == operator to double brackets and = operator for improved compatibility and correctness when comparing values of TARGET_ENV. This change ensures that the comparison works as expected for both "staging" and "production" values.
parent 5d83be06
No related branches found
No related tags found
1 merge request!16Fix: Refactor conditional statement for TARGET_ENV comparison
...@@ -51,7 +51,7 @@ build_packer: ...@@ -51,7 +51,7 @@ build_packer:
- 'sed -i -E "s/(sacct_log_file_path: ).*/\1\/CRI_Cluster_Monitor\/slurm-cluster.log/" CRI_Cluster_Monitor/group_vars/all' - 'sed -i -E "s/(sacct_log_file_path: ).*/\1\/CRI_Cluster_Monitor\/slurm-cluster.log/" CRI_Cluster_Monitor/group_vars/all'
- 'sed -i -E "s/(enable_user_reg: ).*/\1false/" CRI_XCBC/group_vars/all' - 'sed -i -E "s/(enable_user_reg: ).*/\1false/" CRI_XCBC/group_vars/all'
- | - |
if [ "$TARGET_ENV" == "staging" || "$TARGET_ENV" == "production" ]; then if [[ "$TARGET_ENV" == "staging" || "$TARGET_ENV" == "production" ]]; then
'sed -i -E "s/(enable_UAB_UI: ).*/\1true/" CRI_Cluster_Monitor/group_vars/all' 'sed -i -E "s/(enable_UAB_UI: ).*/\1true/" CRI_Cluster_Monitor/group_vars/all'
fi fi
- echo $PKR_VAR_s3_endpoint - echo $PKR_VAR_s3_endpoint
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment