Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
letsencrypt.sh
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
letsencrypt.sh
Commits
669185a0
Commit
669185a0
authored
Feb 17, 2016
by
Lukas Schauer
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #144 from o1oo11oo/pass_chainfile_to_hook
Pass intermediate cert to hook script
parents
75be937a
142b92f1
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
3 deletions
+6
-3
.gitignore
.gitignore
+1
-0
hook.sh.example
hook.sh.example
+4
-2
letsencrypt.sh
letsencrypt.sh
+1
-1
No files found.
.gitignore
View file @
669185a0
private_key.pem
domains.txt
config.sh
hook.sh
certs/*
archive/*
.acme-challenges/*
hook.sh.example
View file @
669185a0
...
...
@@ -32,7 +32,7 @@ function clean_challenge {
}
function
deploy_cert
{
local
DOMAIN
=
"
${
1
}
"
KEYFILE
=
"
${
2
}
"
CERTFILE
=
"
${
3
}
"
CHAINFILE
=
"
${
4
}
"
local
DOMAIN
=
"
${
1
}
"
KEYFILE
=
"
${
2
}
"
CERTFILE
=
"
${
3
}
"
FULLCHAINFILE
=
"
${
4
}
"
CHAINFILE
=
"
${
5
}
"
# This hook is called once for each certificate that has been
# produced. Here you might, for instance, copy your new certificates
...
...
@@ -46,8 +46,10 @@ function deploy_cert {
# The path of the file containing the private key.
# - CERTFILE
# The path of the file containing the signed certificate.
# - CHAINFILE
# -
FULL
CHAINFILE
# The path of the file containing the full certificate chain.
# - CHAINFILE
# The path of the file containing the intermediate certificate(s).
}
HANDLER
=
$1
;
shift
;
$HANDLER
$@
letsencrypt.sh
View file @
669185a0
...
...
@@ -533,7 +533,7 @@ sign_domain() {
ln
-sf
"cert-
${
timestamp
}
.pem"
"
${
BASEDIR
}
/certs/
${
domain
}
/cert.pem"
# Wait for hook script to clean the challenge and to deploy cert if used
[[
-n
"
${
HOOK
}
"
]]
&&
"
${
HOOK
}
"
"deploy_cert"
"
${
domain
}
"
"
${
BASEDIR
}
/certs/
${
domain
}
/privkey.pem"
"
${
BASEDIR
}
/certs/
${
domain
}
/cert.pem"
"
${
BASEDIR
}
/certs/
${
domain
}
/fullchain.pem"
<&4
>
&5 2>&6
[[
-n
"
${
HOOK
}
"
]]
&&
"
${
HOOK
}
"
"deploy_cert"
"
${
domain
}
"
"
${
BASEDIR
}
/certs/
${
domain
}
/privkey.pem"
"
${
BASEDIR
}
/certs/
${
domain
}
/cert.pem"
"
${
BASEDIR
}
/certs/
${
domain
}
/fullchain.pem"
"
${
BASEDIR
}
/certs/
${
domain
}
/chain.pem"
<&4
>
&5 2>&6
unset
challenge_token
echo
" + Done!"
...
...
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