I’m assuming I need to integrate w/ the caddy instance below
instance, err := caddy.Start(caddyfile)
At first I thought I could configure in caddyFile, but didn’t find any examples.
Thinking it’s probably using good old net/http package together w/ caddy instance.
Give that wiki page a read and look further into the pages for Directives and HTTP Middleware, which outline the methods used by the header code you linked.
I should note that Caddy doesn’t use or directly integrate with another net/http server, though. Depending on what your server does, instead of extending with middleware, you could run your Caddy instance with a proxy directive to your own server listening on a local port.