Following the activation of the terminal in my previous guide (How to Enable Linux Apps on Chrome OS Flex), the next logical step in building a hybrid workstation is installing a code editor.
For this purpose, Visual Studio Code is the industry standard. While it is possible to install it via Flatpak, experienced engineers avoid that method due to sandboxing limitations (difficulty accessing system SDKs like Python or Node.js).
In this report, I document the installation via the official Microsoft repository, ensuring the IDE updates automatically alongside your system packages via apt.
Test Configuration
Model: MacBook Pro (Retina, 13-inch, Late 2013)
Architecture: x86_64 (AMD64)
OS: Chrome OS Flex (Stable Channel 2025)
Linux Container: Debian 12 (Bookworm)
Software Version: VS Code 1.96+ (Latest 2025 build)
1. Preparation: Install Dependencies
Microsoft’s repository requires secure transport packages and a keyring manager. Although Debian 12 is robust, minimal containers often lack strictly necessary tools.
Open your Terminal and execute the following command to ensure all prerequisites are present:
Bash
sudo apt update && sudo apt install wget gpg apt-transport-https -y
2. Import the Microsoft GPG Key (The Secure Way)
Strict Protocol: Never download unsigned packages. We must verify the package integrity using Microsoft’s GPG key.
In 2025, the standard for Debian 12 is to store keys in /etc/apt/keyrings, as the old apt-key command is deprecated and insecure.
Command 1: Download and de-armor the key:
Bash
wget -qO- https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > packages.microsoft.gpg
Command 2: Install the key to the protected keyring directory:
Bash
sudo install -D -o root -g root -m 644 packages.microsoft.gpg /etc/apt/keyrings/packages.microsoft.gpg
Command 3: Clean up the temporary file:
Bash
rm packages.microsoft.gpg
3. Add the VS Code Repository
Now we link the repository to the system’s source list. Since Chrome OS Flex runs strictly on amd64 hardware (Intel/AMD), we target that architecture to maintain a clean package index.
Execute this single-line command:
Bash
echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/packages.microsoft.gpg] https://packages.microsoft.com/repos/code stable main" | sudo tee /etc/apt/sources.list.d/vscode.list > /dev/null
4. Install Visual Studio Code
With the repository added, we must update the package cache so the system recognizes the new software source.
Update cache:
Bash
sudo apt update
Install the application:
Bash
sudo apt install code -y
Engineering Note: This process installs the core binary code to /usr/bin/code, making it globally accessible via the terminal.
5. Configuration for High-DPI (Retina) Displays
On the Test Configuration (MacBook Pro 2013), the Retina display (2560×1600) can cause the interface to appear too small or slightly blurry depending on the Chrome OS scaling settings.
To fix this permanently within VS Code:
Launch VS Code by typing
codein the terminal or clicking the icon in the “Linux apps” folder.Press
Ctrl + ,to open Settings.Search for “Window: Zoom Level”.
Set the value to 1.5 or 2 depending on your visual preference.
6. Verification: Accessing Local Files (Crucial Step)
One common confusion for new Flex users is file visibility. By default, the Linux container does not see your Chrome OS files. You must explicitly share them.
To access Downloads:
Open the Files app on Chrome OS.
Navigate to “My Files”, right-click on “Downloads”, and select “Share with Linux”.
Path in VS Code:
/mnt/chromeos/MyFiles/Downloads/
To access Google Drive:
Right-click on “Google Drive” in the Files app and select “Share with Linux”.
Path in VS Code:
/mnt/chromeos/GoogleDrive/
You have successfully deployed a professional development environment on legacy hardware. By using the repository method, your VS Code installation is 100% compliant with Debian standards and will receive security patches every time you run sudo apt upgrade.
Combined with the system’s immutability (see my article on Immutable Linux Distributions), your MacBook Pro is now a secure, engineering-grade cloud terminal.
Technical Disclaimer: The procedures outlined in this guide involve the use of the Linux terminal and system-level modifications. While these steps have been rigorously tested on the specified Test Configuration (MacBook Pro 2013, Chrome OS Flex v130+), individual results may vary. The author and linuxallday.com assume no liability for data loss or system instability. Always backup your data before executing sudo commands.

