Fix code-server installation using direct binary download

- Replace install script with direct GitHub binary download
- Manually place binary in /usr/local/bin and libs in /usr/local/lib
- Add verification steps to ensure proper installation
- Resolve issue where code-server was missing after container start

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
2025-09-08 20:42:16 +09:00
parent b01aabba84
commit e8c4ba14b2

View File

@@ -62,9 +62,17 @@ ENV PATH="/usr/local/bin:${PATH}"
RUN apt-get install -y fcitx5 --fix-missing RUN apt-get install -y fcitx5 --fix-missing
RUN apt-get clean && rm -rf /var/lib/apt/lists/* RUN apt-get clean && rm -rf /var/lib/apt/lists/*
## code server ## code server - direct binary download
RUN curl -fsSL https://code-server.dev/install.sh | sh -s -- --method standalone --prefix=/usr/local RUN VERSION=$(curl -s https://api.github.com/repos/coder/code-server/releases/latest | grep '"tag_name"' | sed -E 's/.*"v([^"]+)".*/\1/') && \
RUN which code-server && code-server --version echo "Installing code-server version: $VERSION" && \
curl -fL https://github.com/coder/code-server/releases/download/v${VERSION}/code-server-${VERSION}-linux-amd64.tar.gz -o code-server.tar.gz && \
tar -xzf code-server.tar.gz && \
mv code-server-${VERSION}-linux-amd64/bin/code-server /usr/local/bin/ && \
mv code-server-${VERSION}-linux-amd64/lib /usr/local/lib/code-server && \
rm -rf code-server.tar.gz code-server-${VERSION}-linux-amd64 && \
chmod +x /usr/local/bin/code-server && \
ls -la /usr/local/bin/code-server && \
/usr/local/bin/code-server --version
## PlayWright Chrome ## PlayWright Chrome
RUN npx playwright install chrome RUN npx playwright install chrome