File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -44,18 +44,21 @@ jobs:
4444 run : |
4545 . venv/bin/activate
4646 CI_CLUSTERS=$(openstack server list | grep --only-matching 'slurmci-RL.-[0-9]\+' | sort | uniq || true)
47+ echo "DEBUG: Raw CI clusters: $CI_CLUSTERS"
48+
4749 if [[ -z "$CI_CLUSTERS" ]]; then
4850 echo "No matching CI clusters found."
4951 else
50- echo "Found clusters: $CI_CLUSTERS"
51- echo "ci_clusters=$CI_CLUSTERS" >> $GITHUB_ENV
52+ # Flatten multiline value so can be passed as env var
53+ CI_CLUSTERS_FORMATTED=$(echo "$CI_CLUSTERS" | tr '\n' ' ' | sed 's/ $//')
54+ echo "DEBUG : Formatted CI clusters: $CI_CLUSTERS_FORMATTED"
55+ echo "ci_clusters=$CI_CLUSTERS_FORMATTED" >> $GITHUB_ENV
5256 fi
5357 shell : bash
5458
5559 - name : Delete clusters if control node not tagged with keep
5660 run : |
5761 . venv/bin/activate
58- echo "Found clusters: ${{ env.ci_clusters }}"
5962 if [[ -z ${ci_clusters} ]]; then
6063 echo "No clusters to delete."
6164 exit 0
6770 if [[ $TAGS =~ "keep" ]]; then
6871 echo "Skipping ${cluster_prefix} - control instance is tagged as keep"
6972 else
70- yes | ./dev/delete-cluster.py ${cluster_prefix}
73+ ./dev/delete-cluster.py ${cluster_prefix} --force
7174 fi
7275 done
7376 shell : bash
You can’t perform that action at this time.
0 commit comments