2019-11-25 13:11:18 +01:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
2020-03-26 17:50:12 +01:00
|
|
|
current_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
2024-08-07 23:31:32 +02:00
|
|
|
source $current_dir/common.sh
|
2019-11-25 13:11:18 +01:00
|
|
|
|
2024-08-08 17:06:22 +02:00
|
|
|
if [[ $IMAGE == "build-and-lint" ]]
|
|
|
|
then
|
2024-08-08 17:51:52 +02:00
|
|
|
incus exec $CONTAINER_NAME -- rm -rf $CUSTOM_ENV_GIT_CLONE_PATH
|
|
|
|
incus exec $CONTAINER_NAME -- rm -rf $CUSTOM_ENV_GIT_CLONE_PATH.tmp
|
|
|
|
incus exec $CONTAINER_NAME -- rmdir $(dirname $CUSTOM_ENV_GIT_CLONE_PATH) || true
|
2024-08-08 17:06:22 +02:00
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|
2024-08-07 23:31:32 +02:00
|
|
|
info "Stopping container $CONTAINER_NAME"
|
2019-11-25 13:11:18 +01:00
|
|
|
|
2024-08-07 23:31:32 +02:00
|
|
|
incus stop "$CONTAINER_NAME"
|
|
|
|
incus delete "$CONTAINER_NAME"
|