Skip to content

Commit 57b3739

Browse files
committed
docs: Various updates for 2.3, 2.4 beta, and Go 1.16
Steps on #139 (sorry)
1 parent 2e255b1 commit 57b3739

File tree

8 files changed

+66
-6
lines changed

8 files changed

+66
-6
lines changed

src/docs/markdown/caddyfile/directives.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ The following directives come standard with Caddy, and can be used in the HTTP C
88

99
Directive | Description
1010
----------|------------
11+
**[abort](/docs/caddyfile/directives/abort)** | Aborts the HTTP request
1112
**[acme_server](/docs/caddyfile/directives/acme_server)** | An embedded ACME server
1213
**[basicauth](/docs/caddyfile/directives/basicauth)** | Enforces HTTP Basic Authentication
1314
**[bind](/docs/caddyfile/directives/bind)** | Customize the server's socket address
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
title: abort (Caddyfile directive)
3+
---
4+
5+
# abort
6+
7+
Prevents any response to the client by immediately aborting the HTTP handler chain and closing the connection. Any concurrent, active HTTP streams on the same connection are interrupted.
8+
9+
10+
## Syntax
11+
12+
```caddy-d
13+
abort [<matcher>]
14+
```
15+
16+
## Examples
17+
18+
Abort all requests for paths starting with `/foo`:
19+
20+
```caddy-d
21+
abort /foo*
22+
```

src/docs/markdown/caddyfile/directives/acme_server.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,16 @@ When enabled, requests matching the path `/acme/*` will be handled by the ACME s
1111

1212
## Client configuration
1313

14-
Using ACME server defaults, ACME clients should simply be configured to use `https://localhost/acme/local/directory` as their ACME endpoint. (`local` is the name of Caddy's default CA.)
14+
Using ACME server defaults, ACME clients should simply be configured to use `https://localhost/acme/local/directory` as their ACME endpoint. (`local` is the ID of Caddy's default CA.)
1515

1616

1717
## Syntax
1818

1919
```caddy-d
20-
acme_server [<matcher>]
20+
acme_server [<matcher>] {
21+
ca <id>
22+
}
2123
```
24+
25+
- **ca** specifies the ID of the certificate authority with which to sign certificates. The default is `local`, which is Caddy's default CA, intended for locally-used, self-signed certificates, which is most common in dev environments. For broader use, it is recommended to specify a different CA to avoid confusion. If the CA with the given ID does not already exist, it will be created.
26+

src/docs/markdown/caddyfile/directives/tls.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,7 @@ Obtains certificates using the ACME protocol.
107107
test_dir <test_directory_url>
108108
email <email>
109109
timeout <duration>
110+
key_type ed25519|p256|p384|rsa2048|rsa4096
110111
disable_http_challenge
111112
disable_tlsalpn_challenge
112113
alt_http_port <port>
@@ -122,6 +123,7 @@ Obtains certificates using the ACME protocol.
122123
- **test_dir** is an optional fallback directory to use when retrying challenges; if all challenges fail, this endpoint will be used during retries; useful if a CA has a staging endpoint where you want to avoid rate limits on their production endpoint. Default: `https://acme-staging-v02.api.letsencrypt.org/directory`
123124
- **email** is the ACME account contact email address.
124125
- **timeout** is how long to wait before timing out an ACME operation.
126+
- **key_type** is the type of key to use when generating CSRs. Only set this if you have a specific requirement.
125127
- **disable_http_challenge** will disable the HTTP challenge.
126128
- **disable_tlsalpn_challenge** will disable the TLS-ALPN challenge.
127129
- **alt_http_port** is an alternate port on which to serve the HTTP challenge; it has to happen on port 80 so you must forward packets to this alternate port.

src/docs/markdown/caddyfile/options.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ Possible options are:
4141
acme_ca <directory_url>
4242
acme_ca_root <pem_file>
4343
acme_eab <key_id> <mac_key>
44-
acme_dns <provider>
44+
acme_dns <provider> ...
4545
on_demand_tls {
4646
ask <endpoint>
4747
interval <duration>
@@ -121,7 +121,7 @@ Specifies a PEM file that contains a trusted root certificate for ACME CA endpoi
121121
Specifies an External Account Binding to use for all ACME transactions.
122122

123123
##### `acme_dns`
124-
Configures the DNS challenge to use for all ACME transactions.
124+
Configures the ACME DNS challenge provider to use for all ACME transactions. The tokens following the name of the provider set up the provider the same as if specified in the [`tls` directive's `acme` issuer](/docs/caddyfile/directives/tls#acme).
125125

126126
##### `on_demand_tls`
127127
Configures [On-Demand TLS](/docs/automatic-https#on-demand-tls) where it is enabled, but does not enable it (to enable it, use the [on_demand `tls` subdirective](/docs/caddyfile/directives/tls#syntax)). Highly recommended if using in production environments, to prevent abuse.
@@ -134,7 +134,7 @@ Configures [On-Demand TLS](/docs/automatic-https#on-demand-tls) where it is enab
134134
Specifies the type of key to generate for TLS certificates; only change this if you have a specific need to customize it.
135135

136136
##### `cert_issuer`
137-
Defines the issuer (or source) of TLS certificates.
137+
Defines the issuer (or source) of TLS certificates. The tokens following the name of the issuer set up the issuer the same as if specified in the [`tls` directive](/docs/caddyfile/directives/tls#issuer).
138138

139139

140140

src/docs/markdown/command-line.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,13 @@ To adapt a Caddyfile to JSON that you can easily read and tweak manually:
119119

120120

121121

122+
### `caddy build-info`
123+
124+
<pre><code class="cmd bash">caddy build-info</code></pre>
125+
126+
Prints information provided by Go about the build (main module path, package versions, replacements).
127+
128+
122129

123130
### `caddy environ`
124131

@@ -201,6 +208,7 @@ Prints CLI help text, optionally for a specific subcommand, then exits.
201208
### `caddy list-modules`
202209

203210
<pre><code class="cmd bash">caddy list-modules
211+
[--packages]
204212
[--versions]</code></pre>
205213

206214
Prints the Caddy modules that are installed, optionally with package and/or version information from their associated Go modules, then exits.
@@ -337,6 +345,17 @@ Untrusts a root certificate from the local trust store(s). Intended for developm
337345

338346

339347

348+
### `caddy upgrade`
349+
350+
<pre><code class="cmd bash">caddy upgrade</code></pre>
351+
352+
Replaces the current Caddy binary with the latest version from [our download page](https://caddyserver.com/download) with the same modules installed, including all third-party plugins that are registered on the Caddy website.
353+
354+
Upgrades do not interrupt running servers; currently, the command only replaces the binary on disk. This might change in the future if we can figure out a good way to do it.
355+
356+
The upgrade process is fault tolerant; the current binary is backed up first and automatically restored if anything goes wrong.
357+
358+
This command may require elevated privileges if your user does not have permission to write to the executable file.
340359

341360

342361
### `caddy validate`

src/docs/markdown/install.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ This page describes various methods for installing Caddy on your system.
2525
- [Homebrew](#homebrew)
2626
- [Webi](#webi)
2727
- [Chocolatey](#chocolatey)
28+
- [Ansible](#ansible)
2829

2930

3031
## Static binaries
@@ -183,3 +184,12 @@ _Note: This is a community-maintained installation method._
183184
<pre><code class="cmd">choco install caddy</code></pre>
184185

185186
[**View the Chocolatey package**](https://chocolatey.org/packages/caddy)
187+
188+
189+
## Ansible
190+
191+
_Note: This is a community-maintained installation method._
192+
193+
<pre><code class="cmd bash">ansible-galaxy install nvjacobo.caddy</code></pre>
194+
195+
[**View the Ansible role repository**](https://github.com/nvjacobo/caddy)

src/download.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@
4242
<option value="linux-ppc64">Linux ppc64</option>
4343
<option value="linux-ppc64le">Linux ppc64le</option>
4444
<option value="linux-s390x">Linux s390x</option>
45-
<option value="darwin-amd64">macOS amd64</option>
45+
<option value="darwin-amd64">macOS amd64 (Intel)</option>
46+
<option value="darwin-arm64">macOS arm64 (M1)</option>
4647
<option value="openbsd-amd64">OpenBSD amd64</option>
4748
<option value="openbsd-arm-6">OpenBSD arm 6</option>
4849
<option value="openbsd-arm-7">OpenBSD arm 7</option>

0 commit comments

Comments
 (0)