added dev preflight check
This commit is contained in:
parent
62ab3f88cd
commit
33c8a232c7
1 changed files with 23 additions and 0 deletions
23
scripts/dev-pre-flight-checks.sh
Executable file
23
scripts/dev-pre-flight-checks.sh
Executable file
|
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
required_tools=("infctl" "pwgen" "kubectl" "k3d" "helm" "jq" "docker")
|
||||
|
||||
MISSING=false
|
||||
check_required_tools() {
|
||||
for tool in "${required_tools[@]}"; do
|
||||
if ! command -v "$tool" &> /dev/null; then
|
||||
echo "Error: $tool is not installed. Please install it to continue."
|
||||
MISSING=true
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
check_required_tools
|
||||
|
||||
if [ "$MISSING" = true ]; then
|
||||
echo "Pre-flight checks failed. Please install the missing tools and try again."
|
||||
exit 1
|
||||
else
|
||||
echo "Pre-flight checks have passed."
|
||||
fi
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue