From 710d63bce1b566ee443726908944123ca36d240c Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 9 Feb 2026 22:58:23 +0000 Subject: [PATCH 1/4] Fix failing CI tests across multiple features - chrome: Replace deprecated apt-key with modern GPG keyring approach (/etc/apt/keyrings/) for Debian compatibility - codex: Auto-install Node.js 22.x when not available instead of failing - gemini-cli: Auto-install Node.js 22.x when not available instead of failing - yek: Copy binary to /usr/local/bin when installer places it in ~/.local/bin (not in PATH) - mcp-language-server: Update test scenario Go image from 1.21 to 1.24 (mcp-language-server v0.1.1 requires Go >= 1.24.0) https://claude.ai/code/session_014AiNJx7n8PhgNNwqhAUTzR --- src/chrome/install.sh | 8 +++++--- src/codex/install.sh | 9 ++++++--- src/gemini-cli/install.sh | 9 ++++++--- src/yek/install.sh | 7 +++++++ test/mcp-language-server/scenarios.json | 2 +- 5 files changed, 25 insertions(+), 10 deletions(-) diff --git a/src/chrome/install.sh b/src/chrome/install.sh index 9538df7..4b62000 100755 --- a/src/chrome/install.sh +++ b/src/chrome/install.sh @@ -7,9 +7,11 @@ echo "Installing Google Chrome stable version..." apt-get update apt-get install -y wget gnupg2 apt-transport-https ca-certificates dbus-x11 -# Add Google Chrome repository -wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | apt-key add - -echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" > /etc/apt/sources.list.d/google-chrome.list +# Add Google Chrome repository using modern approach (apt-key is deprecated) +mkdir -p /etc/apt/keyrings +wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | gpg --dearmor -o /etc/apt/keyrings/google-chrome.gpg +chmod a+r /etc/apt/keyrings/google-chrome.gpg +echo "deb [arch=amd64 signed-by=/etc/apt/keyrings/google-chrome.gpg] http://dl.google.com/linux/chrome/deb/ stable main" > /etc/apt/sources.list.d/google-chrome.list apt-get update # Install Google Chrome stable diff --git a/src/codex/install.sh b/src/codex/install.sh index 1c2e43f..447384f 100755 --- a/src/codex/install.sh +++ b/src/codex/install.sh @@ -3,10 +3,13 @@ set -e echo "Installing Codex CLI..." -# Check if Node.js is available +# Check if Node.js is available, install if missing if ! command -v node &> /dev/null; then - echo "Error: Node.js is required but not found. Please ensure the Node.js feature is installed." - exit 1 + echo "Node.js not found. Installing Node.js 22.x..." + apt-get update + apt-get install -y --no-install-recommends curl ca-certificates + curl -fsSL https://deb.nodesource.com/setup_22.x | bash - + apt-get install -y --no-install-recommends nodejs fi # Check Node.js version (requires 18+) diff --git a/src/gemini-cli/install.sh b/src/gemini-cli/install.sh index 6773b8e..3b45ad8 100755 --- a/src/gemini-cli/install.sh +++ b/src/gemini-cli/install.sh @@ -3,10 +3,13 @@ set -e echo "Installing Gemini CLI..." -# Check if Node.js is available +# Check if Node.js is available, install if missing if ! command -v node &> /dev/null; then - echo "Error: Node.js is required but not found. Please ensure the Node.js feature is installed." - exit 1 + echo "Node.js not found. Installing Node.js 22.x..." + apt-get update + apt-get install -y --no-install-recommends curl ca-certificates + curl -fsSL https://deb.nodesource.com/setup_22.x | bash - + apt-get install -y --no-install-recommends nodejs fi # Check Node.js version (requires 18+) diff --git a/src/yek/install.sh b/src/yek/install.sh index 7c372a7..1a520cd 100755 --- a/src/yek/install.sh +++ b/src/yek/install.sh @@ -9,3 +9,10 @@ fi # Install yek curl -fsSL https://azimi.me/yek.sh | bash + +# The installer places the binary in ~/.local/bin which may not be in PATH. +# Copy it to /usr/local/bin to ensure it's globally available. +if [ -f "$HOME/.local/bin/yek" ] && ! command -v yek >/dev/null 2>&1; then + cp "$HOME/.local/bin/yek" /usr/local/bin/yek + chmod +x /usr/local/bin/yek +fi diff --git a/test/mcp-language-server/scenarios.json b/test/mcp-language-server/scenarios.json index 536b326..dd4044e 100644 --- a/test/mcp-language-server/scenarios.json +++ b/test/mcp-language-server/scenarios.json @@ -9,7 +9,7 @@ } }, "mcp_language_server_with_go_image": { - "image": "mcr.microsoft.com/devcontainers/go:1-1.21-bullseye", + "image": "mcr.microsoft.com/devcontainers/go:1-1.24-bookworm", "features": { "mcp-language-server": {} } From 0fcc0e0d3cef8b2a2d5feadf18617a01ba62be80 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 9 Feb 2026 23:06:32 +0000 Subject: [PATCH 2/4] Fix codex/gemini-cli: add missing test.sh files and fix npm permissions - Add test/codex/test.sh and test/gemini-cli/test.sh for autogenerated tests (devcontainer features test requires these files) - Fix npm permission error: always install as root since npm's global directory (/usr/lib/node_modules/) requires root permissions. The previous su to _REMOTE_USER caused EACCES errors on non-root images. https://claude.ai/code/session_014AiNJx7n8PhgNNwqhAUTzR --- src/codex/install.sh | 14 ++++---------- src/gemini-cli/install.sh | 14 ++++---------- test/codex/test.sh | 16 ++++++++++++++++ test/gemini-cli/test.sh | 16 ++++++++++++++++ 4 files changed, 40 insertions(+), 20 deletions(-) create mode 100755 test/codex/test.sh create mode 100755 test/gemini-cli/test.sh diff --git a/src/codex/install.sh b/src/codex/install.sh index 447384f..d0a8961 100755 --- a/src/codex/install.sh +++ b/src/codex/install.sh @@ -27,16 +27,10 @@ if ! command -v npm &> /dev/null; then exit 1 fi -# Install Codex CLI - prefer remote user installation if available -if [ -n "$_REMOTE_USER" ] && [ "$_REMOTE_USER" != "root" ]; then - echo "Installing Codex CLI as user: $_REMOTE_USER" - NPM_PATH=$(which npm) - BIN_DIR=$(dirname "$NPM_PATH") - su "$_REMOTE_USER" -c "PATH=$BIN_DIR:\$PATH $NPM_PATH install -g @openai/codex" -else - echo "Installing Codex CLI globally as root" - npm install -g @openai/codex -fi +# Install Codex CLI globally as root +# Note: Always install as root since npm's global dir requires root permissions +echo "Installing Codex CLI globally..." +npm install -g @openai/codex # Verify installation if ! command -v codex &> /dev/null; then diff --git a/src/gemini-cli/install.sh b/src/gemini-cli/install.sh index 3b45ad8..c864f78 100755 --- a/src/gemini-cli/install.sh +++ b/src/gemini-cli/install.sh @@ -27,16 +27,10 @@ if ! command -v npm &> /dev/null; then exit 1 fi -# Install Gemini CLI - prefer remote user installation if available -if [ -n "$_REMOTE_USER" ] && [ "$_REMOTE_USER" != "root" ]; then - echo "Installing Gemini CLI as user: $_REMOTE_USER" - NPM_PATH=$(which npm) - BIN_DIR=$(dirname "$NPM_PATH") - su "$_REMOTE_USER" -c "PATH=$BIN_DIR:\$PATH $NPM_PATH install -g @google/gemini-cli" -else - echo "Installing Gemini CLI globally as root" - npm install -g @google/gemini-cli -fi +# Install Gemini CLI globally as root +# Note: Always install as root since npm's global dir requires root permissions +echo "Installing Gemini CLI globally..." +npm install -g @google/gemini-cli # Verify installation if ! command -v gemini &> /dev/null; then diff --git a/test/codex/test.sh b/test/codex/test.sh new file mode 100755 index 0000000..a3eac79 --- /dev/null +++ b/test/codex/test.sh @@ -0,0 +1,16 @@ +#!/bin/bash + +# This test file will be executed against an auto-generated devcontainer.json that +# includes the 'codex' Feature with no options. + +set -e + +# Optional: Import test library bundled with the devcontainer CLI +source dev-container-features-test-lib + +# Feature-specific tests +check "codex command available" which codex +check "codex shows version" bash -c "codex --version" + +# Report results +reportResults diff --git a/test/gemini-cli/test.sh b/test/gemini-cli/test.sh new file mode 100755 index 0000000..1726c7f --- /dev/null +++ b/test/gemini-cli/test.sh @@ -0,0 +1,16 @@ +#!/bin/bash + +# This test file will be executed against an auto-generated devcontainer.json that +# includes the 'gemini-cli' Feature with no options. + +set -e + +# Optional: Import test library bundled with the devcontainer CLI +source dev-container-features-test-lib + +# Feature-specific tests +check "gemini command available" which gemini +check "gemini shows version" bash -c "gemini --version" + +# Report results +reportResults From 5ccf9806bfbd5a6c8f34e1456a3b675970c7ac0a Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 9 Feb 2026 23:11:03 +0000 Subject: [PATCH 3/4] Bump patch versions for chrome, codex, gemini-cli, and yek - chrome: 1.0.1 -> 1.0.2 (fix deprecated apt-key) - codex: 1.0.0 -> 1.0.1 (auto-install Node.js, fix npm permissions) - gemini-cli: 1.0.0 -> 1.0.1 (auto-install Node.js, fix npm permissions) - yek: 1.0.2 -> 1.0.3 (fix PATH issue for installed binary) https://claude.ai/code/session_014AiNJx7n8PhgNNwqhAUTzR --- src/chrome/devcontainer-feature.json | 2 +- src/codex/devcontainer-feature.json | 2 +- src/gemini-cli/devcontainer-feature.json | 2 +- src/yek/devcontainer-feature.json | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/chrome/devcontainer-feature.json b/src/chrome/devcontainer-feature.json index c513742..899a77b 100644 --- a/src/chrome/devcontainer-feature.json +++ b/src/chrome/devcontainer-feature.json @@ -1,6 +1,6 @@ { "id": "chrome", - "version": "1.0.1", + "version": "1.0.2", "name": "Google Chrome for Containers", "description": "Installs Google Chrome with container-specific configurations and wrapper script", "customizations": { diff --git a/src/codex/devcontainer-feature.json b/src/codex/devcontainer-feature.json index de6aec8..8778353 100644 --- a/src/codex/devcontainer-feature.json +++ b/src/codex/devcontainer-feature.json @@ -1,6 +1,6 @@ { "id": "codex", - "version": "1.0.0", + "version": "1.0.1", "name": "Codex CLI", "description": "Installs OpenAI Codex CLI for local AI-powered coding assistance", "options": {}, diff --git a/src/gemini-cli/devcontainer-feature.json b/src/gemini-cli/devcontainer-feature.json index 39f23bc..416b9a0 100644 --- a/src/gemini-cli/devcontainer-feature.json +++ b/src/gemini-cli/devcontainer-feature.json @@ -1,6 +1,6 @@ { "id": "gemini-cli", - "version": "1.0.0", + "version": "1.0.1", "name": "Gemini CLI", "description": "Installs Google Gemini CLI for AI-powered development assistance", "options": {}, diff --git a/src/yek/devcontainer-feature.json b/src/yek/devcontainer-feature.json index 6226a46..992ad53 100644 --- a/src/yek/devcontainer-feature.json +++ b/src/yek/devcontainer-feature.json @@ -1,6 +1,6 @@ { "id": "yek", - "version": "1.0.2", + "version": "1.0.3", "name": "yek", "description": "Installs yek, a tool for serializing repository files for LLM consumption", "options": {}, From 59be567dee7e7f3495d55e48f9a653df52a10230 Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 9 Feb 2026 23:12:46 +0000 Subject: [PATCH 4/4] Update test images from bullseye to bookworm Replace deprecated Debian bullseye-based images with bookworm in codex and gemini-cli test scenarios. https://claude.ai/code/session_014AiNJx7n8PhgNNwqhAUTzR --- test/codex/scenarios.json | 2 +- test/gemini-cli/scenarios.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/codex/scenarios.json b/test/codex/scenarios.json index 9e38755..0fb5b4c 100644 --- a/test/codex/scenarios.json +++ b/test/codex/scenarios.json @@ -9,7 +9,7 @@ } }, "codex_with_node_image": { - "image": "mcr.microsoft.com/devcontainers/javascript-node:1-20-bullseye", + "image": "mcr.microsoft.com/devcontainers/javascript-node:1-20-bookworm", "features": { "codex": {} } diff --git a/test/gemini-cli/scenarios.json b/test/gemini-cli/scenarios.json index 5996699..1e30ae4 100644 --- a/test/gemini-cli/scenarios.json +++ b/test/gemini-cli/scenarios.json @@ -9,7 +9,7 @@ } }, "gemini_cli_with_node_image": { - "image": "mcr.microsoft.com/devcontainers/javascript-node:1-20-bullseye", + "image": "mcr.microsoft.com/devcontainers/javascript-node:1-20-bookworm", "features": { "gemini-cli": {} }