mirror of
https://github.com/caddyserver/caddy.git
synced 2024-12-16 21:56:40 -05:00
tests: fix caddyfile adapt warnings (#6619)
Signed-off-by: Mohammed Al Sahaf <msaa1990@gmail.com>
This commit is contained in:
parent
d7564d632f
commit
dd5decabe7
3 changed files with 12 additions and 10 deletions
|
@ -5,15 +5,15 @@
|
||||||
root_cn "Internal Root Cert"
|
root_cn "Internal Root Cert"
|
||||||
intermediate_cn "Internal Intermediate Cert"
|
intermediate_cn "Internal Intermediate Cert"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
acme.example.com {
|
acme.example.com {
|
||||||
acme_server {
|
acme_server {
|
||||||
ca internal
|
ca internal
|
||||||
sign_with_root
|
sign_with_root
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
----------
|
----------
|
||||||
{
|
{
|
||||||
"apps": {
|
"apps": {
|
||||||
|
|
|
@ -1,11 +1,12 @@
|
||||||
example.com {
|
example.com {
|
||||||
respond <<EOF
|
respond <<EOF
|
||||||
<html>
|
<html>
|
||||||
<head><title>Foo</title>
|
<head><title>Foo</title>
|
||||||
<body>Foo</body>
|
<body>Foo</body>
|
||||||
</html>
|
</html>
|
||||||
EOF 200
|
EOF 200
|
||||||
}
|
}
|
||||||
|
|
||||||
----------
|
----------
|
||||||
{
|
{
|
||||||
"apps": {
|
"apps": {
|
||||||
|
|
|
@ -1,23 +1,23 @@
|
||||||
example.com
|
example.com
|
||||||
|
|
||||||
map {host} {my_placeholder} {magic_number} {
|
map {host} {my_placeholder} {magic_number} {
|
||||||
# Should output boolean "true" and an integer
|
# Should output boolean "true" and an integer
|
||||||
example.com true 3
|
example.com true 3
|
||||||
|
|
||||||
# Should output a string and null
|
# Should output a string and null
|
||||||
foo.example.com "string value"
|
foo.example.com "string value"
|
||||||
|
|
||||||
# Should output two strings (quoted int)
|
# Should output two strings (quoted int)
|
||||||
(.*)\.example.com "${1} subdomain" "5"
|
(.*)\.example.com "${1} subdomain" "5"
|
||||||
|
|
||||||
# Should output null and a string (quoted int)
|
# Should output null and a string (quoted int)
|
||||||
~.*\.net$ - `7`
|
~.*\.net$ - `7`
|
||||||
|
|
||||||
# Should output a float and the string "false"
|
# Should output a float and the string "false"
|
||||||
~.*\.xyz$ 123.456 "false"
|
~.*\.xyz$ 123.456 "false"
|
||||||
|
|
||||||
# Should output two strings, second being escaped quote
|
# Should output two strings, second being escaped quote
|
||||||
default "unknown domain" \"""
|
default "unknown domain" \"""
|
||||||
}
|
}
|
||||||
|
|
||||||
vars foo bar
|
vars foo bar
|
||||||
|
@ -27,6 +27,7 @@ vars {
|
||||||
ghi 2.3
|
ghi 2.3
|
||||||
jkl "mn op"
|
jkl "mn op"
|
||||||
}
|
}
|
||||||
|
|
||||||
----------
|
----------
|
||||||
{
|
{
|
||||||
"apps": {
|
"apps": {
|
||||||
|
|
Loading…
Reference in a new issue