docs: Add Caddyfile syntax highlighting (#41)

This commit is contained in:
Francis Lavoie 2020-05-17 16:32:12 -04:00 committed by GitHub
parent 75fcfc21bb
commit e0f5ee1bb9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
34 changed files with 215 additions and 179 deletions

View file

@ -9,7 +9,7 @@ Writes a hard-coded/static response to the client.
## Syntax
```
```caddy-d
respond [<matcher>] <status>|<body> [<status>] {
body <text>
close
@ -32,19 +32,19 @@ To clarify, the first non-matcher argument can be either a 3-digit status code o
Write a 200 status with an empty body to all health checks:
```
```caddy-d
respond /health-check 200
```
Write a simple response body to all requests:
```
```caddy-d
respond "Hello, world!"
```
Write an error response and close the connection:
```
```caddy-d
respond /secret/* "Access denied" 403 {
close
}