- Install NGINX with Lua
- Install CF origin certificates
- Install Kubo 0.15
NGINX Config
- Use
set_by_lua_block
to extract host type fromngx.var.http_host
Kubo Config
DoH Resolvers:
"DNS": {
"Resolvers": {
"bit.": "https://dweb-dns.v2ex.pro/dns-query",
"eth.": "https://dns.eth.limo/dns-query"
}
}
Set a domain for public gateway so Kubo can recognize Host header.
"PublicGateways": {
"gateway.example.com": {
"UseSubdomains": true,
"InlineDNSLink": true,
"Paths": ["/ipfs", "/ipns"]
}
}
You don't need a real certificate for this domain as it won't be exposed to Internet.