[DOCS] Fix broken Alpine Linux configuration in GitLab CI/CD documentation
Documentation Type
Missing documentation (feature not documented)
Documentation Location
https://code.claude.com/docs/en/gitlab-ci-cd
Section/Topic
The "Basic .gitlab-ci.yml (Claude API)" code block and subsequent examples that utilize the node:24-alpine3.21 image.
Current Documentation
The current example configures the environment as follows:
claude:
stage: ai
image: node:24-alpine3.21
# ...
variables:
GIT_STRATEGY: fetch
before_script:
- apk update
- apk add --no-cache git curl bash
- curl -fsSL https://claude.ai/install.sh | bash
What's Wrong or Missing?
The documentation uses an Alpine Linux image (node:24-alpine3.21) but fails to install the necessary operating system dependencies required for the Claude Code native binary to run on Alpine.
As noted in the Setup documentation (https://code.claude.com/docs/en/setup#installation), Alpine Linux specifically requires libgcc, libstdc++, and ripgrep. Additionally, the environment variable USE_BUILTIN_RIPGREP=0 must be set.
Without these additions, the pipeline defined in the documentation will fail during the install step or when attempting to execute the binary.
Suggested Improvement
Update the before_script and variables in the .gitlab-ci.yml examples to include the required Alpine dependencies.
Revised YAML:
variables:
GIT_STRATEGY: fetch
USE_BUILTIN_RIPGREP: "0" # Required for Alpine Linux
before_script:
- apk update
# Added libgcc, libstdc++, and ripgrep
- apk add --no-cache git curl bash libgcc libstdc++ ripgrep
- curl -fsSL https://claude.ai/install.sh | bash
Impact
High - Prevents users from using a feature
Additional Context
- Reference URL for Alpine Requirements: https://code.claude.com/docs/en/setup#installation
- Quote from Setup Docs: "Alpine Linux and other musl/uClibc-based distributions: The native installer requires
libgcc,libstdc++, andripgrep. For Alpine:apk add libgcc libstdc++ ripgrep. SetUSE_BUILTIN_RIPGREP=0."
This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗