Marzgah CLI
设置和管理一个自托管的Marzgah VPN经销商面板。需要 1.4.4或更新版本;npm发布这个包,但可执行文件运行在Bun上。
创建面板
bunx @begyoupardon/marzgah init my-panel
CLI从与此版本捆绑在一起的模板创建一个完整的项目,安装它的依赖项,并启动交互式安装向导。它拒绝覆盖非空目录。安装程序直接支持Bun、Docker和Cloudflare配置说明。Docker和Cloudflare需要各自的工具/帐户。
要创建文件而不安装依赖项、联系VPN后端或请求凭据:
bunx @begyoupardon/marzgah init my-panel --scaffold-only
cd my-panel
bun install --frozen-lockfile
bun run cli init
在现有生成的项目中, init 如果没有目录,则运行配置向导。
管理一个小组
从面板的目录中运行命令,其中包含 .env 数据直播:
cd my-panel
bunx @begyoupardon/marzgah doctor
bunx @begyoupardon/marzgah migrate
bunx @begyoupardon/marzgah create-admin
bunx @begyoupardon/marzgah reset-password
bunx @begyoupardon/marzgah backup --out ./backups/manual.db
恢复备份前停止面板:
bunx @begyoupardon/marzgah restore ./backups/manual.db
数据库管理命令在本地SQLite上操作。Cloudflare D1迁移使用安装向导所描述的Wrangler。 DATABASE_PATH 默认为 ./data/panel.db;从当前目录解析相对路径。包自带迁移,使用 MIGRATIONS_DIR 作为显式覆盖可用。环境变量优先于 .env 值。在管理面板数据库时,使用与面板版本匹配的CLI版本。
如需重复使用,请使用 bun add --global @begyoupardon/marzgah,然后跑 marzgah --help.
来源和许可
来源及问题: https://github.com/begyoupardon/marzgah
应用程序代码目前没有开源许可证(UNLICENSED); 不隐含许可授予。第三方依赖许可证仍然适用。捆绑的Arad字体的SIL开放字体许可证保留在 public/licenses/Arad-OFL.txt 在生成的项目中。Poppins通过其Fontsource包在本地安装。