|
@@ -53,10 +53,24 @@ function install_i2p {
|
53
|
53
|
echo "deb https://${I2P_DOMAIN}/ stretch main" > /etc/apt/sources.list.d/i2p.list
|
54
|
54
|
echo "deb-src https://${I2P_DOMAIN}/ stretch main" >> /etc/apt/sources.list.d/i2p.list
|
55
|
55
|
|
|
56
|
+ # i2p needs ipv6 to be enabled
|
|
57
|
+ sed -i 's|net.ipv6.conf.all.disable_ipv6.*|net.ipv6.conf.all.disable_ipv6 = 0|g' /etc/sysctl.conf
|
|
58
|
+ /sbin/sysctl -p -q
|
|
59
|
+
|
56
|
60
|
apt-get update
|
57
|
61
|
apt-get -yq install i2p i2p-keyring
|
58
|
62
|
}
|
59
|
63
|
|
60
|
64
|
function remove_i2p {
|
61
|
65
|
apt-get -yq remove i2p i2p-keyring --purge
|
|
66
|
+
|
|
67
|
+ # It's assumed here that ipv6 is only needed for i2p
|
|
68
|
+ # This might not be true in future
|
|
69
|
+ sed -i 's|net.ipv6.conf.all.disable_ipv6.*|net.ipv6.conf.all.disable_ipv6 = 1|g' /etc/sysctl.conf
|
|
70
|
+ /sbin/sysctl -p -q
|
|
71
|
+}
|
|
72
|
+
|
|
73
|
+function i2p_enable_sam {
|
|
74
|
+ sed -i 's|clientApp.1.startOnLoad=.*|clientApp.1.startOnLoad=true|g' /var/lib/i2p/i2p-config/clients.config
|
|
75
|
+ systemctl restart i2p
|
62
|
76
|
}
|