Caddy server install issues on Unraid

1. Caddy version (caddy version):

Cannot run, latest Alpine version

2. How I run Caddy:

Unraid Docker

a. System environment:

Unraid 6.9.2 Docker

b. Command:

N/A

c. Service/unit/compose file:


d. My complete Caddyfile or JSON config:

localhost

respond "Hello"

3. The problem I’m having:

On install I get this error:

4. Error messages and/or full log output:

docker: Error response from daemon: OCI runtime create failed: container_linux.go:367: starting container process caused: process_linux.go:495: container init caused: rootfs_linux.go:60: mounting “/mnt/user/Docker/conf/caddyv2/Caddyfile” to rootfs at “/var/lib/docker/btrfs/subvolumes/f89f46a3e1e4fe6b6836c88b80184334ca8ff63670dc5b63c3b0e35be87d072e/etc/caddy/Caddyfile” caused: not a directory: unknown: Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type.

The command failed.

5. What I already tried:

Adding a Caddyfile to

/etc/caddy/Caddyfile

6. Links to relevant resources:

If anyone has a working version of Caddy on Unraid would you please be able to share your contain config from the below please?

Have you actually created a file at this path in your filesystem?

The error is saying it wasn’t able to create the mount, because the file type is “unknown”.

Yes I have. The links in the above seems to have the same issue. But I am unable to recreate their solution.

image

and the contents of the file
image

Uh, looks like you made a directory named Caddyfile and then put a Caddyfile inside of that. Don’t do that! Remove the directory, and just create file called Caddyfile there.

Ok… That got it installed and it try to run. But my config (absolute beginner) must be wrong.

What is the absolute bare bones Caddyfile I could test?

run: adapting config using caddyfile: /etc/caddy/Caddyfile:3: unrecognized directive: resond
Did you mean to define a second site? If so, you must use curly braces around each site to separate their configurations.

My mistake… I misspelt “respond”

Not sure if I should open another question but I’ll see if you may know how to achieve my final goal.

I have Bitwarden as my only open port on my router. All my other services are accessible via tailscale.

Bitwarden requires a https connection to work I am trying to use the tailscale/caddy integration so when I point to the tailscale https site it takes me to a ssl connection to local Bitwarden.

Thanks