Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
Acme.Sh
Commits
613475ac
Commit
613475ac
authored
Aug 30, 2021
by
fradev
Browse files
Update ssh.sh
parent
20d23fcb
Changes
1
Show whitespace changes
Inline
Side-by-side
deploy/ssh.sh
View file @
613475ac
...
...
@@ -237,8 +237,8 @@ then rm -rf \"\$fn\"; echo \"Backup \$fn deleted as older than 180 days\"; fi; d
# if filename is same as previous file then append.
_pipe
=
">>"
_local_cert_file
=
$(
_mktemp
)
cat
$_ckey
>
$_local_cert_file
cat
$_ccert
>>
$_local_cert_file
cat
"
$_ckey
"
>
"
$_local_cert_file
"
cat
"
$_ccert
"
>>
"
$_local_cert_file
"
elif
[
"
$Le_Deploy_ssh_backup
"
=
"yes"
]
;
then
# backup file we are about to overwrite.
_cmdstr
=
"
$_cmdstr
cp
$Le_Deploy_ssh_certfile
$_backupdir
>/dev/null;"
...
...
@@ -344,15 +344,15 @@ then rm -rf \"\$fn\"; echo \"Backup \$fn deleted as older than 180 days\"; fi; d
_pipe
=
">>"
_local_full_file
=
$(
_mktemp
)
if
[
"
$Le_Deploy_ssh_fullchain
"
=
"
$Le_Deploy_ssh_keyfile
"
]
;
then
cat
$_ckey
>>
$_local_full_file
cat
"
$_ckey
"
>>
"
$_local_full_file
"
fi
if
[
"
$Le_Deploy_ssh_fullchain
"
=
"
$Le_Deploy_ssh_certfile
"
]
;
then
cat
$_ccert
>>
$_local_full_file
cat
"
$_ccert
"
>>
"
$_local_full_file
"
fi
if
[
"
$Le_Deploy_ssh_fullchain
"
=
"
$Le_Deploy_ssh_cafile
"
]
;
then
cat
$_cca
>>
$_local_full_file
cat
"
$_cca
"
>>
"
$_local_full_file
"
fi
cat
$_cfullchain
>>
$_local_full_file
cat
"
$_cfullchain
"
>>
"
$_local_full_file
"
elif
[
"
$Le_Deploy_ssh_backup
"
=
"yes"
]
;
then
# backup file we are about to overwrite.
...
...
@@ -390,13 +390,13 @@ then rm -rf \"\$fn\"; echo \"Backup \$fn deleted as older than 180 days\"; fi; d
# cleanup local files if any
if
[
-n
"
$_local_cert_file
"
]
;
then
rm
$_local_cert_file
>
/dev/null 1>&2
rm
"
$_local_cert_file
"
>
/dev/null 1>&2
fi
if
[
-n
"
$_local_ca_file
"
]
;
then
rm
$_local_ca_file
>
/dev/null 1>&2
rm
"
$_local_ca_file
"
>
/dev/null 1>&2
fi
if
[
-n
"
$_local_full_file
"
]
;
then
rm
$_local_full_file
>
/dev/null 1>&2
rm
"
$_local_full_file
"
>
/dev/null 1>&2
fi
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment