Caddy in Docker on Synology NAS

So I have my Jellyfin server set up on Docker, which I can access using my NAS’ internal IP and the jellyfin port.
Then I have the no-ip account set up like this:

Caddy set up on Docker:

I’ve just noticed that this has port settings on here, maybe this has something to do with it? Or does the caddyfile override it?

And then my caddyfile is this:

{
    http_port 8080
    https_port 8443
}

mydomain.ddns.net:80 {
  respond "404" 403
}

mydomain.ddns.net:443 {
  respond "404" 403
}

mydomain.ddns.net:5858 {
  reverse_proxy 127.0.0.1:8096
}

I know you said I could combine the 80 and 443 blocks but I’m not sure exactly how to do that.