mirror of
https://github.com/acmesh-official/acme.sh.git
synced 2025-06-16 09:37:42 +00:00
Fixed ShellCheck and shfmt
This commit is contained in:
parent
b9291ea697
commit
cbfef738f3
@ -32,9 +32,10 @@ parse_response() {
|
|||||||
|
|
||||||
# Function to deploy base64-encoded certificate to firewall
|
# Function to deploy base64-encoded certificate to firewall
|
||||||
deployer() {
|
deployer() {
|
||||||
cert_base64=$(cat "$_cfullchain" | _base64 | tr -d '\n')
|
cert_base64=$(_base64 <"$_cfullchain" | tr -d '\n')
|
||||||
key_base64=$(cat "$_ckey" | _base64 | tr -d '\n')
|
key_base64=$(_base64 <"$_ckey" | tr -d '\n')
|
||||||
payload=$(cat <<EOF
|
payload=$(
|
||||||
|
cat <<EOF
|
||||||
{
|
{
|
||||||
"type": "regular",
|
"type": "regular",
|
||||||
"scope": "global",
|
"scope": "global",
|
||||||
@ -54,8 +55,9 @@ EOF
|
|||||||
|
|
||||||
# Function to upload CA certificate to firewall (FortiGate doesn't automatically extract CA from fullchain)
|
# Function to upload CA certificate to firewall (FortiGate doesn't automatically extract CA from fullchain)
|
||||||
upload_ca_cert() {
|
upload_ca_cert() {
|
||||||
ca_base64=$(cat "$_cca" | _base64 | tr -d '\n')
|
ca_base64=$(_base64 <"$_cca" | tr -d '\n')
|
||||||
payload=$(cat <<EOF
|
payload=$(
|
||||||
|
cat <<EOF
|
||||||
{
|
{
|
||||||
"import_method": "file",
|
"import_method": "file",
|
||||||
"scope": "global",
|
"scope": "global",
|
||||||
@ -78,7 +80,8 @@ EOF
|
|||||||
|
|
||||||
# Function to activate the new certificate
|
# Function to activate the new certificate
|
||||||
set_active_web_cert() {
|
set_active_web_cert() {
|
||||||
payload=$(cat <<EOF
|
payload=$(
|
||||||
|
cat <<EOF
|
||||||
{
|
{
|
||||||
"admin-server-cert": "$_cdomain"
|
"admin-server-cert": "$_cdomain"
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user