summaryrefslogtreecommitdiff
path: root/caddytest
diff options
context:
space:
mode:
authormritd <mritd@linux.com>2021-07-02 07:22:16 +0800
committerGitHub <noreply@github.com>2021-07-01 17:22:16 -0600
commit4245ceb67d1a40ce7a691bcf85e143218e5c458c (patch)
tree9b9a825737aaaa611ade0a15b3a31d1ea99eda14 /caddytest
parent0bdb8aa82d7cef64dae3f75f19c680922237e658 (diff)
fileserver: Add `disable_canonical_uris` Caddyfile subdirective (#4222)
* feat(fileserver): add 'canonical_uris' parameter to caddyfile add 'canonical_uris' parameter to caddyfile reference #2741 Signed-off-by: mritd <mritd@linux.com> * feat(file_server): rename subdirective canonical_uris to disable_canonical_uris rename subdirective canonical_uris to disable_canonical_uris Signed-off-by: mritd <mritd@linux.com> * test(caddyfile_adapt): add disable_canonical_uris subdirective test file add disable_canonical_uris subdirective test file Signed-off-by: mritd <mritd@linux.com>
Diffstat (limited to 'caddytest')
-rw-r--r--caddytest/integration/caddyfile_adapt/file_server_disable_canonical_uris.txt32
1 files changed, 32 insertions, 0 deletions
diff --git a/caddytest/integration/caddyfile_adapt/file_server_disable_canonical_uris.txt b/caddytest/integration/caddyfile_adapt/file_server_disable_canonical_uris.txt
new file mode 100644
index 0000000..c30b9e9
--- /dev/null
+++ b/caddytest/integration/caddyfile_adapt/file_server_disable_canonical_uris.txt
@@ -0,0 +1,32 @@
+:80
+
+file_server {
+ disable_canonical_uris
+}
+----------
+{
+ "apps": {
+ "http": {
+ "servers": {
+ "srv0": {
+ "listen": [
+ ":80"
+ ],
+ "routes": [
+ {
+ "handle": [
+ {
+ "canonical_uris": false,
+ "handler": "file_server",
+ "hide": [
+ "./Caddyfile"
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ }
+ }
+ }
+}