diff --git a/install_incus_ollama.sh b/install_incus_ollama.sh index 9c913ee..ec77e96 100644 --- a/install_incus_ollama.sh +++ b/install_incus_ollama.sh @@ -13,7 +13,7 @@ LOG_FILE="/tmp/incus_ollama_install.log" # Función para mostrar mensajes de error y salir die () { - echo "${RED}Error: $1${NC}" >&2 + echo -e "${RED}Error: $1${NC}" >&2 exit 1 } @@ -22,7 +22,7 @@ run_command() { local cmd="$1" local description="$2" - echo "${YELLOW}Ejecutando: ${description}...${NC}" + echo -e "${YELLOW}Ejecutando: ${description}...${NC}" echo "Comando: ${cmd}\n" >> "${LOG_FILE}" eval "${cmd} < /dev/null" >> "${LOG_FILE}" 2>&1 @@ -32,7 +32,7 @@ run_command() { } -echo "Instalando Incus" +echo -e "${YELLOW}Instalando Incus" # Configuración (puedes modificar estos valores) STORAGE_POOL="default" @@ -44,10 +44,10 @@ NETWORK_DHCP_RANGE="10.0.0.2-10.0.0.254" NETWORK_DHCP_STATIC="10.0.0.1" TRUST_PASSWORD="" # Déjalo vacío para no configurar contraseña -echo "${YELLOW}Inicializando Incus con la siguiente configuración:${NC}" +echo -e "${YELLOW}Inicializando Incus con la siguiente configuración:${NC}" echo " - Pool de almacenamiento: $STORAGE_POOL ($STORAGE_DRIVER)" echo " - Red: $NETWORK_NAME ($NETWORK_TYPE, $NETWORK_ADDR)" -echo "${YELLOW}Esto configurará Incus con valores por defecto.${NC}" +echo -e "${YELLOW}Esto configurará Incus con valores por defecto.${NC}" # Confirmar antes de continuar #read -p "¿Deseas continuar? (y/N) " -n 1 -r @@ -58,7 +58,7 @@ echo "${YELLOW}Esto configurará Incus con valores por defecto.${NC}" #fi # Ejecutar incus admin init con las configuraciones -echo "${YELLOW}Inicializando Incus...${NC}" +echo -e "${YELLOW}Inicializando Incus...${NC}" cat < /etc/apt/sources.list.d/backports.list' sudo curl -fsSL https://pkgs.zabbly.com/key.asc | gpg --show-keys --fingerprint @@ -25,7 +27,7 @@ Signed-By: /etc/apt/keyrings/zabbly.asc EOF' -sudo apt install -y software-properties-common +sudo apt install -y software-properties-common sudo apt-add-repository -y contrib @@ -72,3 +74,6 @@ sudo apt -y install incus sudo usermod -a -G incus,incus-admin $USER +echo "Please, reboot the server..." + + diff --git a/readme.md b/readme.md index 8ebddad..3aa2c61 100644 --- a/readme.md +++ b/readme.md @@ -11,6 +11,8 @@ You need execute two scripts. First script, prepare the baremetal server for use curl -fsSL https://git.cuchulu.com/smartest/aiscripts/raw/branch/master/install_nvidia.sh | bash ``` +Reboot the server for the next script. + ```sh curl -fsSL https://git.cuchulu.com/smartest/aiscripts/raw/branch/master/install_incus_ollama.sh | bash ```