# Caddy

{% embed url="<https://caddyserver.com/docs/install>" %}
Caddy Installation Instructions
{% endembed %}

{% embed url="<https://caddyserver.com/docs/running>" %}
Installing Caddy as a Service
{% endembed %}

An example Caddy V2 Caddyfile with reverse proxy

```
mydomain.com {
    root * C:\Caddy\www\organizr\html
    php_fastcgi localhost:9000
    rewrite /api/v2/* /api/v2/index.php?{query}
    file_server

    # Subdirectory
    route /calibre/* {
        uri strip_prefix /calibre
        reverse_proxy localhost:9900
    }
}

# Subdomain
tautulli.mydomain.com {
    route {
        reverse_proxy localhost:8181
    } 
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.organizr.app/installation/prerequisites/installing-webservers/caddy.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
