Proxy for not sharing your Cloudflare private key everywhere on untrusted servers.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
frontend
migrations
src
templates
.gitignore
Cargo.toml
README.md
diesel.toml

README.md

cloudflare-proxy

Proxy for Cloudflare API written in Rust.

Usage

First change the .env file:

DATABASE_URL=postgres://user_pass@localhost/DB_NAME

Then create a user, a site and give the user privilege:

diesel setup

cargo run --bin new_user

cargo run --bin new_site

cargo run --bin new_priv

And run the web app with:

ROCKET_CFUSER=<CF_EMAIL> ROCKET_CFKEY=<CF_KEY> cargo run

Now you can call the API with:

curl --verbose  --header "Content-Type: application/json" \
  --data '{"user":"username","key":"fdsfdafsas","zone":"example.net","rec":"vu1.example.net","rectype":"A", "value":"10.2.22.2"}' \
  http://localhost:8000/update

ACME (Let's Encrypt)

Use with certbot-dns-cfproxy

LICENSE

MIT or Apache