Repository navigation
feat(base): install cloudflared from Cloudflare apt repository - #11
Conversation
Add install-cloudflared.sh to the root phase, using the official pkg.cloudflare.com apt repository (any suite, cloudflare-public-v2 key), and document it in CLAUDE.md, images/CLAUDE.md and README.md. Closes #10
|
This pull request was opened by a factory run. |
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request adds the installation of cloudflared (Cloudflare Tunnel client) to the Coder workspace base image, updating the Dockerfile, adding an installation script, and updating the documentation. The review feedback suggests two improvements to the install-cloudflared.sh script: first, using curl -o instead of piping to tee to ensure the script fails immediately if the download fails; second, using standard redirection (>) instead of tee for writing the apt source list file, as the script already runs with root privileges.
There was a problem hiding this comment.
Code Review
본 풀 리퀘스트는 Coder 워크스페이스 베이스 이미지에 Cloudflare 터널 클라이언트인 cloudflared 설치 과정을 추가합니다. 이를 위해 공식 apt 저장소에서 패키지를 설치하는 install-cloudflared.sh 스크립트가 새로 도입되었으며, Dockerfile 및 관련 문서들이 업데이트되었습니다. 리뷰어는 설치 스크립트의 안정성과 단순화를 위해 set -euo pipefail 설정 적용, 불필요한 tee 명령어 제거 및 curl -o와 리다이렉션(>) 사용을 제안했습니다.
|
Review round closed: a review pass is working 5 thread(s). |
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces the installation of cloudflared (Cloudflare Tunnel client) into the Docker base image for Coder workspaces, updating the Dockerfile, adding an installation script, and updating the relevant documentation. The review feedback suggests aligning the GPG key filename with the official Cloudflare documentation, adding retry options to the curl command, optimizing the apt-get installation with --no-install-recommends to reduce image size, and ensuring the documentation remains consistent with these script updates.
|
Review round closed: a review pass is working 3 thread(s). |
|
/gemini review |
There was a problem hiding this comment.
Code Review
이번 풀 리퀘스트는 Coder 워크스페이스용 Docker 베이스 이미지에 Cloudflare Tunnel 클라이언트인 cloudflared 설치 단계를 추가합니다. 이를 위해 관련 문서들을 업데이트하고, install-cloudflared.sh 스크립트를 통해 공식 apt 리포지토리에서 패키지를 설치하도록 설정했습니다. 리뷰 피드백으로는 다운로드한 GPG 키 파일의 권한이 umask 설정에 의해 제한되어 _apt 사용자가 읽지 못해 빌드가 실패하는 문제를 방지하기 위해, GPG 키 파일에 명시적으로 0644 권한을 부여할 것을 권장했습니다.
|
Review round closed: a review pass is working 1 thread(s). |
Set the downloaded Cloudflare GPG keyring to 0644 so the unprivileged _apt user can read it regardless of the build umask.
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request integrates the installation of cloudflared (Cloudflare Tunnel client) into the Coder workspace Docker base image by adding a new installation script, updating the Dockerfile, and updating the documentation. The review feedback correctly highlights a medium-severity issue in the install-cloudflared.sh script where the downloaded ASCII-armored GPG key is saved directly without dearmoring, which could cause compatibility issues with some apt versions. The suggested fix to pipe the download through gpg --dearmor should be applied.
|
Review round closed: a review pass is working 1 thread(s). |
|
The factory's review pass pushed no new commit, so it is stopping at this head. Some review threads or failed checks may be unworked. @amondnet, this pull request is back with you for review. |
요약
베이스 이미지에
cloudflaredCLI를 설치한다. pkg.cloudflare.com에 안내된 Cloudflare 공식 apt 저장소를 쓰므로apt-get upgrade로 갱신할 수 있다.변경 내용
images/base/scripts/install-cloudflared.sh(새 파일, root): 서명 키를/usr/share/keyrings/cloudflare-public-v2.gpg에 받고,deb [signed-by=...] https://pkg.cloudflare.com/cloudflared any main을 등록한 뒤cloudflared를 설치하고 apt 캐시를 정리한다.images/base/Dockerfile: root 단계에서 mise 다음, Docker 이전에 위 스크립트를 실행한다. 기존과 같이/tmp에 복사하고 실행 후 삭제한다.CLAUDE.md,images/CLAUDE.md,README.md에 cloudflared 항목을 추가했다.범위
바이너리 설치만 다룬다. 터널, 서비스, 인증 정보, systemd 유닛은 설정하지 않는다. 다른 도구와 coder 사용자 단계는 바꾸지 않았다.
트레이드오프
릴리스
.deb를 직접 받는 대신 apt 저장소를 택했다. 이슈가 가리킨 문서가 apt 저장소이고, gh·mise·docker 설치 방식과 같다. 버전은 고정하지 않는다.영향 범위
이미지 크기가 약 30–40MB 늘어난다.
any스위트라 amd64·arm64 모두 패키지가 있다.검증
cloudflare-public-v2.gpg로cloudflared/dists/any/InRelease를gpgv검증:Good signature from "CloudFlare Software Packaging 2025". 현재 문서의cloudflare-main.gpg와 바이트 단위로 같다.bash -n images/base/scripts/install-cloudflared.sh통과.Closes #10
Asana Tasks