www/caddy is included in OPNsense plugins
https://github.com/opnsense/plugins/tree/master/www/caddy
This repository contains a fork of it which retains the DNS Provider subsystem, and adds a helper xcaddy plugin so the binary can be easily upgraded to include whichever module is needed.
- os-caddy-plus 2.1.0 requires OPNsense version 26.1 or later
- os-xcaddy-plus 0.2 requires OPNsense version 25.1 or later
How to install on OPNsense:
- Ensure you have removed the packages
os-caddyandcaddy-custom(served from the OPNsense repository). - Existing configuration of
os-caddywill be compatible withos-caddy-plus, yet not necessarily the other way around.
pkg install gitmkdir -p /src/gitcd /src/gitgit clone https://github.com/opnsense/portsgit clone https://github.com/Monviech/os-caddycd /src/git/ports/lang/gomake -DBATCH install cleancd /src/git/ports/www/caddymake -DBATCH install cleancd /src/git/ports/www/xcaddymake -DBATCH install cleancd /src/git/os-caddy/www/caddy-plusmake packagecd /src/git/os-caddy/www/caddy-plus/work/pkgpkg install *.pkgcd /src/git/os-caddy/www/xcaddy-plusmake packagecd /src/git/os-caddy/www/xcaddy-plus/work/pkgpkg install *.pkg
- Now everything should be installed.
How to use os-xcaddy-plus:
You can find the xcaddy plugin in Services: Caddy: Modules:
- Press
Update Modules, this automatically pulls all available plugins for caddy - Select the base build with the
Modulesdropdown, to use all features you need at least:
github.com/mholt/caddy-dynamicdns
github.com/mholt/caddy-l4
github.com/caddy-dns/cloudflare <- A DNS Provider of your choice
-
Press
Buildand wait until the build has finished -
To keep caddy automatically up to date, create a cronjob:
System: Settings: Cronthat callsBuild Caddy binary with additional modules
-
Service restarts are handled automatically if a build succeeds
-
Afterwards you can use
os-caddy-pluswith the binary you just built.
How to use os-caddy-plus: