Skip to content
Snippets Groups Projects

Remove base compute and gpu build from pipeline

Merged Bo-Chun Chen requested to merge louistw/hpc-factory:feat-remove-compute-build into main
1 file
+ 0
30
Compare changes
  • Side-by-side
  • Inline
+ 0
30
@@ -377,41 +377,11 @@ cleanup_integration:
| awk -v NITK=$NUM_IMAGE_TO_KEEP -v REGEX=ood-$TIMESTAMP_REGEX
'{if ($0 ~ REGEX) result[count++] = $1}
END {for(i=NITK;i<count;i++) print result[i]}'))
- >
BASE_IMAGE_TO_BE_DELETE=($(cat images.txt
| awk -v NITK=$NUM_IMAGE_TO_KEEP -v REGEX=base-$TIMESTAMP_REGEX
'{if ($0 ~ REGEX) result[count++] = $1}
END {for(i=NITK;i<count;i++) print result[i]}'))
- >
COMPUTE_IMAGE_TO_BE_DELETE=($(cat images.txt
| awk -v NITK=$NUM_IMAGE_TO_KEEP -v REGEX=compute-$TIMESTAMP_REGEX
'{if ($0 ~ REGEX) result[count++] = $1}
END {for(i=NITK;i<count;i++) print result[i]}'))
- >
GPU_IMAGE_TO_BE_DELETE=($(cat images.txt
| awk -v NITK=$NUM_IMAGE_TO_KEEP -v REGEX=gpu-$TIMESTAMP_REGEX
'{if ($0 ~ REGEX) result[count++] = $1}
END {for(i=NITK;i<count;i++) print result[i]}'))
- |
for img in ${OOD_IMAGE_TO_BE_DELETE[@]}; do
echo "Deleting image $img"
openstack image delete ${img}
done
- |
for img in ${BASE_IMAGE_TO_BE_DELETE[@]}; do
echo "Deleting image $img"
openstack image delete ${img}
done
- |
for img in ${COMPUTE_IMAGE_TO_BE_DELETE[@]}; do
echo "Deleting image $img"
openstack image delete ${img}
done
- |
for img in ${GPU_IMAGE_TO_BE_DELETE[@]}; do
echo "Deleting image $img"
openstack image delete ${img}
done
rules:
- if: $CI_PIPELINE_SOURCE == "schedule"
when: always
Loading