一条命令选择入口协议
默认生成公网 HTTPS 地址;需要直连 SSH 或数据库等非 HTTP 协议时,可以切到 ssh 或 tcp 四层入口。
Sealtun 已经覆盖 HTTPS 预览、SSH/TCP 四层入口、自定义域名证书、访问策略、region/profile、声明式多隧道和本地观测。先安装 Skill,让 AI 直接替你完成这些操作。
npx skills add https://github.com/gitlayzer/sealtun
What it does
默认生成公网 HTTPS 地址;需要直连 SSH 或数据库等非 HTTP 协议时,可以切到 ssh 或 tcp 四层入口。
Basic Auth、Bearer Token、IP allowlist / denylist 和临时链接都在 Sealtun proxy 层生效,公开预览也能保留边界。
sealtun.yaml 支持 dry-run、diff、apply、ttl 和多隧道;doctor、logs、events、metrics、dashboard 让问题定位回到同一条链路。
Latest capabilities
Sealtun 现在不只是把 Web 页面发出去。它可以管理公网协议、域名证书、访问控制、账号环境和运行状态,让本地调试更接近真实入口。
Web 预览继续走 HTTPS;本地 sshd 可以用 NodePort 直连;数据库、队列和调试服务可以用通用 TCP 入口。
sealtun expose 3000
--protocol ssh
--protocol tcp
Sealtun 保留 Sealos host 作为 CNAME 目标,确认 DNS 归属后再写入 Ingress,并创建 cert-manager Issuer 和 Certificate。
--domain
domain verify --wait
domain doctor
Basic Auth、Bearer Token、IP 规则和临时访问链接都在代理层处理,token 以 hash 形式保存。
内置 gzg、hzh、bja、cloud、usw region,并支持命名 profile 保存不同账号、workspace 和 kubeconfig。
logs、events、metrics、inspect --remote、doctor 和本地 dashboard 把本地 session 与远端 Kubernetes 状态放在一起看。
sealtun.yaml 支持多个稳定命名隧道、dry-run、diff、apply、ttl 和失败回滚,适合团队共享配置。
Codex Skill
把这个仓库作为 Skill 安装后,AI agent 会理解 Sealtun 的 CLI、配置、访问策略、四层入口、域名诊断和发布流程。 你可以直接描述目标:暴露本地服务、加 Basic Auth、绑定域名、写 sealtun.yaml、查 doctor,而不是先查参数。
npx skills add https://github.com/gitlayzer/sealtun
Install
先装 Skill,让 AI 会用 Sealtun;需要自己操作时,再用 npm 或 npx 安装 CLI。 团队共享入口可以写进 sealtun.yaml,用 dry-run 和 diff 先看清变更,再 apply。
npx skills add https://github.com/gitlayzer/sealtun
# Then ask your AI agent:
# "Expose localhost:3000 with Basic Auth and a temporary review link."
npm install -g sealtun
sealtun login gzg --profile demo
sealtun expose 3000
sealtun expose 22 --protocol ssh
sealtun expose 5432 --protocol tcp
sealtun expose 3000 --domain app.example.com
# Create CNAME app.example.com -> <sealos-host>
sealtun domain verify <tunnel-id> --wait --timeout 5m
sealtun domain status
sealtun domain doctor <tunnel-id>
export SEALTUN_BASIC_AUTH_PASSWORD='change-me'
export SEALTUN_TEMP_TOKEN='review-link-secret'
sealtun expose 3000 \
--basic-auth-user admin \
--basic-auth-password-env SEALTUN_BASIC_AUTH_PASSWORD \
--temporary-access-token-env SEALTUN_TEMP_TOKEN \
--temporary-access-ttl 1h
version: v1
tunnels:
- name: web
localPort: 3000
protocol: https
ttl: 2h
- name: postgres
localPort: 5432
protocol: tcp
sealtun apply -f sealtun.yaml --dry-run
sealtun diff -f sealtun.yaml
sealtun apply -f sealtun.yaml
Built for local services that need a real entrance