Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
picard
packages
Commits
b8120af0
Commit
b8120af0
authored
Nov 05, 2014
by
Bjoern Franke
Browse files
fastdreg: ugly hack: add vpn01.freifunk-ol.de temporarily to /etc/hosts
parent
3dd5a34c
Changes
1
Hide whitespace changes
Inline
Side-by-side
fastdreg/files/lib/ffnw/fastdreg/fastdreg.sh
View file @
b8120af0
...
...
@@ -10,9 +10,15 @@ pubkey=$(/etc/init.d/fastd show_key mesh_vpn)
regdone
=
$(
uci get fastdreg.ffnw.regdone
)
if
[
"
$regdone
"
-ne
"1"
]
;
then
cp
/etc/hosts /etc/hosts.tmp
echo
"5.45.102.211 vpn01.freifunk-ol.de"
>>
/etc/hosts
reg
=
$(
wget
-T15
"
$keysrv
/reg.php?name=
$hostname
&key=
$pubkey
"
-O
-
)
if
[
"
$reg
"
==
"regdone"
]
;
then
uci
set
fastdreg.ffnw.regdone
=
1
uci commit
fi
rm
/etc/hosts
mv
/etc/hosts.tmp /etc/hosts
fi
Write
Preview
Supports
Markdown
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