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
243b6ae9
Unverified
Commit
243b6ae9
authored
May 16, 2020
by
neil
Committed by
GitHub
May 16, 2020
Browse files
Merge pull request #2931 from dvaerum/dev
Bug fix: DNS TXT entries will now be removed for dns_gdnsdk.sh
parents
8780ba36
048f754d
Changes
1
Hide whitespace changes
Inline
Side-by-side
dnsapi/dns_gdnsdk.sh
View file @
243b6ae9
...
@@ -157,9 +157,18 @@ _successful_update() {
...
@@ -157,9 +157,18 @@ _successful_update() {
}
}
_findentry
()
{
_findentry
()
{
#args $1: fulldomain, $2: txtvalue
#returns id of dns entry, if it exists
#returns id of dns entry, if it exists
_myget
"action=dns_primary_changeDNSsetup&user_domain=
$_domain
"
_myget
"action=dns_primary_changeDNSsetup&user_domain=
$_domain
"
_id
=
$(
echo
"
$_result
"
| _egrep_o
"<td>
$1
</td>
\s
*<td>
$2
</td>[^?]*[^&]*&id=[^&]*"
|
sed
's/^.*=//'
)
_debug3
"_result:
$_result
"
_tmp_result
=
$(
echo
"
$_result
"
|
tr
-d
'\n\r'
| _egrep_o
"<td>
$1
</td>
\s
*<td>
$2
</td>[^?]*[^&]*&id=[^&]*"
)
_debug _tmp_result
"
$_tmp_result
"
if
[
-z
"
${
_tmp_result
:-}
"
]
;
then
_debug
"The variable is _tmp_result is not supposed to be empty, there may be something wrong with the script"
fi
_id
=
$(
echo
"
$_tmp_result
"
|
sed
's/^.*=//'
)
if
[
-n
"
$_id
"
]
;
then
if
[
-n
"
$_id
"
]
;
then
_debug
"Entry found with _id=
$_id
"
_debug
"Entry found with _id=
$_id
"
return
0
return
0
...
...
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