Fetching latest headlines…
Fixing VS Code Installation Error on Ubuntu 26.04 (Resolute) via Terminal
NORTH AMERICA
🇺🇸 United StatesMay 7, 2026

Fixing VS Code Installation Error on Ubuntu 26.04 (Resolute) via Terminal

0 views0 likes0 comments
Originally published byDev.to

The Problem: apt-key is Deprecated and Repository is Unsigned

When trying to install Visual Studio Code on the new Ubuntu 26.04 LTS (Resolute) using old tutorial methods, you will likely hit two roadblocks:

  1. sudo: 'apt-key': command not found (The tool has been removed for security reasons).
  2. The following signatures couldn't be verified... NO_PUBKEY EB3E94ADBE1229CF (Public key error).

This happens because Ubuntu now requires GPG keys (digital signatures) to be stored in standalone files within the /etc/apt/keyrings/ directory to ensure system integrity.

The Solution: Manual Repository Configuration

Follow these steps to correctly configure the Microsoft GPG key and repository.

1. Add the GPG Key


bash
# Download the official Microsoft key and convert it to .gpg format
wget -qO- [https://packages.microsoft.com/keys/microsoft.asc](https://packages.microsoft.com/keys/microsoft.asc) | gpg --dearmor > packages.microsoft.gpg

# Move the key to the system's secure keyring folder
sudo install -D -o root -g root -m 644 packages.microsoft.gpg /etc/apt/keyrings/packages.microsoft.gpg

# Remove the temporary file
rm -f packages.microsoft.gpg

Comments (0)

Sign in to join the discussion

Be the first to comment!