MacOS, Windows and Linux are the 3 players which come across in a developer's daily life. Virtual machine is always the solution. In this article I will go through the steps on how to quickly setup an Debian Linux VM with all required gears (VSCode, Chrome, Docker) for front-end devs, on a Windows laptop.
Download and install VMWare Workstation Player.
Download the ISO image of Debian installation (even you are on intel CPU)
https://cdimage.debian.org/debian-cd/current/amd64/iso-cd/In VMWare, create a new machine from ISO installer. This will take about 20 min.
Once Debian is installed, log in and use terminal to install gdebi
sudo apt install gdebi
- Now download Chrome installer on Linux (.deb) and use gdebi to load the package
Alternatively, you can install using wget via terminal:
wget --no-check-certificate https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
dpkg -i google-chrome-stable_current_amd64.deb
- Download VS Code (https://code.visualstudio.com/) and install from deb installer.
- Install Node
sudo apt update
sudo apt upgrade
sudo apt install nodejs npm -y
- If you switch node versions often, install NVM as well
sudo apt install curl
curl https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash
source ~/.profile
nvm install 12.18.3
- Install docker desktop on Debian
sudo apt-get update
sudo apt-get install ca-certificates curl gnupg lsb-release
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt update
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
Then run sudo apt-get install ./docker-desktop-<version>-<arch>.deb
Ref:
https://docs.docker.com/engine/install/debian/
https://docs.docker.com/compose/install/linux/
Note:
Update: snyk that comes with Docker Engine is not for arm64: you will get this error:
exec /user/local/bin/snyk exec format error
You will have to install the binary manually:
curl https://static.snyk.io/cli/latest/snyk-linux-arm64 -o snyk
chmod +x ./snyk
mv ./snyk /usr/local/bin/
If you are on arm64 Linux, your default installation will not contain Docker Scan plugin, and apt-get install docker-scan-plugin will not work. You will have to install manually:
(https://github.com/docker/scan-cli-plugin#on-linux)
mkdir -p ~/.docker/cli-plugins && \
curl https://github.com/docker/scan-cli-plugin/releases/latest/download/docker-scan_linux_arm64 -L -s -S -o ~/.docker/cli-plugins/docker-scan &&\
chmod +x ~/.docker/cli-plugins/docker-scan
Top comments (0)