Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ruanhaishen
Acme.Sh
Commits
0be214e7
Unverified
Commit
0be214e7
authored
Jan 02, 2021
by
neil
Committed by
GitHub
Jan 02, 2021
Browse files
Merge pull request #3307 from jimp100/patch-1
Corrected regex for duckdns subdomains
parents
d6083c68
cee20c4e
Changes
1
Hide whitespace changes
Inline
Side-by-side
dnsapi/dns_duckdns.sh
View file @
0be214e7
...
@@ -96,7 +96,7 @@ dns_duckdns_rm() {
...
@@ -96,7 +96,7 @@ dns_duckdns_rm() {
_duckdns_get_domain
()
{
_duckdns_get_domain
()
{
# We'll extract the domain/username from full domain
# We'll extract the domain/username from full domain
_duckdns_domain
=
"
$(
printf
"%s"
"
$fulldomain
"
| _lower_case | _egrep_o
'^(_acme-challenge\.)?[a-z0-9-]
*
\.duckdns\.org'
|
sed
's/^\(
_acme-challenge\.\)\{0,1\}
\([a-z0-9-]
*
\)\.duckdns\.org/\2/'
)
"
_duckdns_domain
=
"
$(
printf
"%s"
"
$fulldomain
"
| _lower_case | _egrep_o
'^(_acme-challenge\.)?
(
[a-z0-9-]
+
\.
)+
duckdns\.org'
|
sed
-n
's/^\(
[^.]\{1,\}\.\)*
\([a-z0-9-]
\{1,\}
\)\.duckdns\.org
$
/\2/
p;
'
)
"
if
[
-z
"
$_duckdns_domain
"
]
;
then
if
[
-z
"
$_duckdns_domain
"
]
;
then
_err
"Error extracting the domain."
_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