-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
httpcaddyfile: Fix TLS automation policy merging with get_certificate (…
- Loading branch information
1 parent
d70608b
commit 7984e6f
Showing
2 changed files
with
68 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
67 changes: 67 additions & 0 deletions
67
caddytest/integration/caddyfile_adapt/tls_automation_policies_11.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
# example from https://caddy.community/t/21415 | ||
a.com { | ||
tls { | ||
get_certificate http http://foo.com/get | ||
} | ||
} | ||
|
||
b.com { | ||
} | ||
---------- | ||
{ | ||
"apps": { | ||
"http": { | ||
"servers": { | ||
"srv0": { | ||
"listen": [ | ||
":443" | ||
], | ||
"routes": [ | ||
{ | ||
"match": [ | ||
{ | ||
"host": [ | ||
"a.com" | ||
] | ||
} | ||
], | ||
"terminal": true | ||
}, | ||
{ | ||
"match": [ | ||
{ | ||
"host": [ | ||
"b.com" | ||
] | ||
} | ||
], | ||
"terminal": true | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
"tls": { | ||
"automation": { | ||
"policies": [ | ||
{ | ||
"subjects": [ | ||
"a.com" | ||
], | ||
"get_certificate": [ | ||
{ | ||
"url": "http://foo.com/get", | ||
"via": "http" | ||
} | ||
] | ||
}, | ||
{ | ||
"subjects": [ | ||
"b.com" | ||
] | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |