WSL Docker

This commit is contained in:
MangoPig 2025-12-03 03:05:11 +00:00
parent 2ad3a414db
commit 8e32c77541

View File

@ -96,15 +96,20 @@ fi
# Docker Installation
if command -v docker &> /dev/null; then
echo -e "${GREEN} LOG: Docker is already installed. Skipping...${NC}"
else
# Check if we are running in WSL
if grep -qEi "(Microsoft|WSL)" /proc/version &> /dev/null; then
echo -e "${RED} LOG: WSL Detected! Skipping Native Docker installation.${NC}"
echo -e "${RED} >>> ACTION REQUIRED: Please install Docker Desktop for Windows.${NC}"
echo -e "${RED} >>> Ensure 'Use WSL 2 based engine' is enabled in Docker settings.${NC}"
else
echo -e "${BLUE} LOG:${YELLOW} Docker not found. Installing Native Docker Engine...${NC}"
# ARCH LINUX
if [ "$OS" == "arch" ] || [ "$OS" == "manjaro" ]; then
echo -e "${BLUE} LOG:${YELLOW} Cleaning potential zombie files...${NC}"
sudo rm -f /usr/bin/docker /usr/bin/docker-compose /usr/share/bash-completion/completions/docker
sudo pacman -S --noconfirm --needed docker docker-compose
# Enable service
sudo systemctl enable --now docker
fi
# UBUNTU / DEBIAN
@ -123,6 +128,7 @@ else
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
fi
fi
fi
# Install NVM, GVM, Rustup
echo -e "${BLUE} LOG:${YELLOW} Installing NVM, GVM and Rustup...${NC}"