pocketdev 能在 Hetzner 云服务器上配置一个仅通过 Tailscale 私有网络访问的安全开发环境,安装 Claude Code、Aider 等 AI 编程代理,并支持通过手机 SSH/Mosh 进行编码。

Stars

103

7 天增长

暂无数据

Fork 数

6

开放 Issue

0

开源协议

AGPL-3.0

最近更新

2026-06-30

AI 仓库情报摘要
FR-AI / ANALYSIS

为什么值得关注

它将完全自动化、安全加固的云盒子(无公网入站端口、仅密钥 SSH、代理无 sudo 权限)与实用的手机工作流(二维码、Termius、Mosh)以及通过 Cloudflare 隧道发布临时网页的功能结合,仅需两条命令即可完成。

适合谁使用

  • 希望在手机或平板电脑上编码的开发者
  • 寻找低成本、始终在线的远程环境中使用 AI 编程代理的用户
  • 注重隐私、拒绝公网 SSH 并希望使用私有网络的开发者
  • 个人开发者或小团队,希望尝试多种 AI 编程代理

典型使用场景

  • 在每月仅需5-8欧元的 Hetzner 服务器上运行 Claude Code 或 Aider,并随时随地通过手机接入
  • 为周末项目创建一个安全的开发盒子,并通过 pocketdev publish 与同事共享临时演示链接
  • 接管已有的 Hetzner 服务器,自动加固(无公网端口、仅 Tailscale 访问、安装代理)
  • 在黑客松中快速创建可丢弃的 AI 编程环境,一条命令即可销毁

项目优势

  • 两条命令即可完成设置,带引导式 TUI,逐步完成令牌、服务器、Tailscale 和代理配置
  • 深度安全防御:Hetzner 防火墙阻断所有入站、Tailscale 提供连接、仅密钥 SSH、非特权 dev 用户
  • 支持七种 AI 编程代理(Claude Code、Codex、opencode、Cursor、Gemini、Grok、Aider),通过 SSH 自动登录
  • 针对手机优化的工作流:二维码、Termius SSH ID 分发密钥、Mosh 持久连接、tmux 会话管理

使用前须知

  • 项目处于早期阶段;多用户/托管版本受限于 Claude Pro/Max 等按席位订阅的限制
  • 需要同时拥有 Hetzner Cloud 和 Tailscale 账户,手机设置需要手动管理密钥(仅二维码无法工作)
  • 重启会导致 tmux 会话终止(进程不保留),且首次启动时 cloud-init 会运行 apt upgrade,造成短暂延迟

README 快速开始

pocketdev

Run the AI coding CLI you already pay for on a cloud box you reach from your phone.

pocketdev provisions an always-on Hetzner server, locks it to your private Tailscale network (no public SSH), and installs the agent you use: Claude Code, Codex, Cursor, opencode, Gemini, Grok, or Aider. You log in with your own subscription. Then you SSH in from a laptop or from Termius on a phone and code from anywhere.

Two commands and you are done:

# on your laptop
pocketdev

# on the box (once)
ssh dev@devbox
pocketdev setup

How it works

pocketdev (laptop) walks one step at a time: paste a Hetzner token (it checks the token before moving on), choose the box, connect Tailscale, choose which agents to install on the box, and pick what code the box starts with. Each console page opens only when you reach that step and say so.

The Project step picks one source for the box's code:

  • Clone a GitHub repo. Pick from a searchable list of your repos, read live via the local gh CLI; pocketdev clones it on the box during pocketdev setup (after gh auth login). If gh isn't installed locally, type owner/repo instead.
  • Copy a local folder. Browse your filesystem (start typing to filter, ctrl+a toggles hidden files), pick a folder or file, and pocketdev rsyncs it to the box over the tailnet once the box is up.
  • Start fresh. An empty box.

The box step offers two paths:

  • Create a new box. Drill down Hetzner's hierarchy, the same as the console: Type (Shared / Dedicated) → Class (Cost-Optimized, Regular Performance, or General Purpose) → Architecture (x86 / Arm64), with any single-choice step skipped. Then a table (headers, full region names with country flags, live net monthly prices ex VAT in your account currency) where each row is a concrete size + region, cheapest first. Type to filter, shift+tab to step back. pocketdev creates a firewall that drops all public inbound, boots Ubuntu 24.04 with that firewall attached, joins it to your tailnet, and installs the agent CLIs. Nothing listens on the public internet.
  • Adopt a server you already own. Pick one of your existing servers; pocketdev joins it to your tailnet and installs the agents over SSH without rebuilding it. pocketdev destroy never deletes an adopted server (you owned

项目描述

One command to run the AI coding CLI you already pay for (Claude Code, Codex, Cursor, Gemini, Grok, aider) on a Tailscale-only Hetzner box — code from your phone.

相关仓库与替代方案

根据分类、Topic 和编程语言匹配的相似项目。

nethical6
精选
nethical6 GitHub avatar

conversation-steganography

A tool that hides encrypted secret messages inside innocent-looking AI-generated chat text for private communication over any messaging platform.

Go
1,149
programmersd21
精选
programmersd21 GitHub avatar

flow

flow is a minimalist terminal dashboard that displays real-time network throughput with smooth animations, multiple responsive modes, and zero configuration.

开发者工具CLI 与终端
277
MobAI-App
MobAI-App GitHub avatar

simslim

simslim reduces iOS simulator memory usage by 4x by disabling unnecessary background daemons, allowing many more simulators to run on a single Mac.

Go
248