Moved to better status codes

master
Keith Irwin 2022-09-10 14:08:45 -06:00
parent 960ed70b52
commit 92094e5c0d
Signed by: ki9
GPG Key ID: DF773B3F4A88DA86
2 changed files with 2 additions and 1 deletions

View File

@ -7,6 +7,7 @@
status='' status=''
case "${1}" in case "${1}" in
''|'0'|'200') status='200 OK\n';; ''|'0'|'200') status='200 OK\n';;
'201') status='201 Created\n';;
'202') status='202 Accepted\n';; '202') status='202 Accepted\n';;
'400') status='400 Bad Request\n';; '400') status='400 Bad Request\n';;
'500') status='500 Internal Server Error\n';; '500') status='500 Internal Server Error\n';;

View File

@ -126,7 +126,7 @@ wg_config="[Interface] # ${hostname}.${username}.${TLD}\nPrivateKey=${privkey}\n
# if wireguard worked, there's no going back. The admin # if wireguard worked, there's no going back. The admin
# can clean up missing records and certs after checking the logs # can clean up missing records and certs after checking the logs
set -x set -x
<<<"${wg_config}" "${LIB_DIR}/http_res" <<<"${wg_config}" "${LIB_DIR}/http_res" 202
set +x set +x
# Update nameserver # Update nameserver