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
8718ac0c
Unverified
Commit
8718ac0c
authored
Jun 30, 2020
by
Matthew
Committed by
GitHub
Jun 30, 2020
Browse files
duckdns doesn't permit subdomains or underscores
parent
71a5f0e8
Changes
1
Hide whitespace changes
Inline
Side-by-side
dnsapi/dns_duckdns.sh
View file @
8718ac0c
...
...
@@ -91,13 +91,13 @@ dns_duckdns_rm() {
#################### Private functions below ##################################
#fulldomain=
_
acme-challenge
.
domain.duckdns.org
#fulldomain=acme-challenge
-
domain.duckdns.org
#returns
# _duckdns_domain=domain
# _duckdns_domain=
acme-challenge-
domain
_duckdns_get_domain
()
{
# We'll extract the domain/username from full domain
_duckdns_domain
=
"
$(
printf
"%s"
"
$fulldomain
"
| _lower_case |
_egrep_o
'[.][^.][^.]*[.]
duckdns.org
'
|
cut
-d
.
-f
2
)
"
_duckdns_domain
=
"
$(
printf
"%s"
"
$fulldomain
"
| _lower_case |
sed
's/^\([a-z0-9-]*\)\.
duckdns
\
.org
/\1/'
)
"
if
[
-z
"
$_duckdns_domain
"
]
;
then
_err
"Error extracting the domain."
...
...
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