update: Added 'git' and 'vagrant' to required tools in pre-flight checks fix: configured k3s install to use internal nic for flanel network update: Added Longhorn installation process and updated memory allocation for VMs update: Added 'git' and 'vagrant' to required tools in pre-flight checks fix: configured k3s install to use internal nic for flanel network fix: corrected JSON formatting for config json update: reduce VM memory allocation to 2GB, add Longhorn installation scripts and prerequisites, and implement checks for existing pods update: improve error logging in RunJsonDeployment and RunCommand functions update: add jq installation to provision script update: add version flag
35 lines
996 B
Bash
Executable file
35 lines
996 B
Bash
Executable file
#!/usr/bin/env bash
|
|
|
|
# function to install infctl
|
|
install_infctl() {
|
|
echo "Installing infctl..."
|
|
# Add installation commands here
|
|
curl -L https://codeberg.org/headshed/infctl-cli/raw/branch/main/install.sh | bash
|
|
|
|
}
|
|
|
|
if ! command -v infctl &> /dev/null
|
|
then
|
|
echo "infctl could not be found, installing..."
|
|
install_infctl
|
|
fi
|
|
|
|
# base.json.example config.json.example
|
|
|
|
# https://codeberg.org/headshed/infctl-cli/raw/branch/main/base.json.example
|
|
|
|
# https://codeberg.org/headshed/infctl-cli/raw/branch/main/config.json.example
|
|
|
|
if [ ! -f "base.json" ]; then
|
|
echo "base.json not found in home directory, downloading..."
|
|
curl -o "base.json" https://codeberg.org/headshed/infctl-cli/raw/branch/main/base.json.example
|
|
fi
|
|
|
|
if [ ! -f "config.json" ]; then
|
|
echo "config.json not found in home directory, downloading..."
|
|
curl -o "config.json" https://codeberg.org/headshed/infctl-cli/raw/branch/main/config.json.example
|
|
fi
|
|
|
|
|
|
|
|
echo "infctl is installed and ready to use."
|