cloudflare-cli

command
v0.0.0-...-50172b1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2023 License: GPL-3.0 Imports: 27 Imported by: 0

README

Cloudflare 命令行操作

因为工作需要,用cf的api来操作会效率更高,特意写了个小程序。


为什么效率高呢?下面以配置域名http301跳转为例

cloudflare WEB 界面后台配置步骤

  1. 搜索域名
  2. 进入ssl/tls页面
  3. 添加hsts配置
  4. 进入域名dns配置页面
  5. 删除旧的无用解析
  6. 添加跳转的子域名解析,并启用CDN
  7. 切换到page规则页面
  8. 添加规则,选择url重定向
  9. 添加对应的跳转规则

cloudflare-cli 配置步骤

  1. 打开终端
  2. 输入 cloudflare-cli 301 <旧域名> <新域名>

哈哈,这样多简单

而且命令行还可以批量操作哦。

Documentation

Overview

* cloudflare-cli * * 创建时间 2020-08-27 * 更新时间 2023-04-21

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL