summaryrefslogtreecommitdiff
path: root/i2p.html
diff options
context:
space:
mode:
authorLuke Smith <luke@lukesmith.xyz>2021-08-24 12:03:11 -0400
committerLuke Smith <luke@lukesmith.xyz>2021-08-24 12:03:11 -0400
commit2967576c5d27b3d7a4d5698ecb69cdfa1051479f (patch)
tree519f756fde890e0b7db5a669c518c12729f9b4e9 /i2p.html
parent8b286783aac2574645964b4d03403a0964f69217 (diff)
parent47c2b83f371b1bc5ecd7303aabf9e5d8d6fb54b9 (diff)
Merge branch 'qorg11-add-i2p'
Diffstat (limited to 'i2p.html')
-rw-r--r--i2p.html101
1 files changed, 101 insertions, 0 deletions
diff --git a/i2p.html b/i2p.html
new file mode 100644
index 0000000..bff7b38
--- /dev/null
+++ b/i2p.html
@@ -0,0 +1,101 @@
+<!DOCTYPE html>
+<html lang=en>
+ <head>
+ <title>Mirror your site over I2P</title>
+ <meta charset="utf-8"/>
+ <link rel="shortcut icon" href="favicon.ico" type="image/x-icon" />
+ <link rel='stylesheet' type='text/css' href='style.css'>
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <link rel='alternate' type='application/rss+xml' title='Land Chad RSS' href='/rss.xml'>
+ </head>
+ <body>
+ <header><h1>Mirror Your Site Over I2P</h1></header>
+ <nav></nav>
+ <main>
+ <img class=titleimg src="pix/i2p.svg" alt="I2P logo">
+ <p>
+ Now you have a website, why not offer it in a private alternative such as the Invisible Internet?
+ </p>
+
+ <h2>Setting up I2P</h2>
+ <p>
+ There are 2 main I2P implementations, I2P and i2pd, we are using i2pd in this
+ guide because it's easier to use in servers.
+ </p>
+ <h3>Installing I2P</h3>
+
+ <p>
+ i2pd is in most repos, in debian/ubuntu you can install it simply
+ with <pre><code>apt install i2pd</code></pre>
+ </p>
+
+ <h3>Enabling I2P</h3>
+ <p>
+ We are going to create a user for i2pd, because i2pd finds the configuration
+ files in its home directory. And it's easier (and more tidy) to have it in a separate user:
+ </p>
+ <pre><code>useradd -m i2p -s /bin/bash
+su -l i2p
+mkdir ~/.i2pd
+cd ~/.i2pd</code></pre>
+
+ <p>
+ Now that you're in ~/.i2pd, you have to create a file named
+ "tunnels.conf". Which is the config file for every hidden service you're
+ offering over I2P, the content should be like this:
+ </p>
+ <pre><code>[<strong>example</strong>]
+type = http
+host = 127.0.0.1
+port = 8080
+keys = <strong>example.dat</strong></code></pre>
+
+ <h3>Getting your I2P Hostname</h3>
+
+ <p>
+ Then, run <code>/usr/sbin/i2pd --daemon</code> to start i2pd and we can retreive our I2P hostname.
+ </p>
+
+ <p>
+ This can be done in lynx or a command-line browser by going to <code>http://127.0.0.1:7070/?page=i2p_tunnels</code> to get your I2P hostname.
+ </p>
+ <p>
+ You
+ can also run these commands to find your hostname:
+ </p>
+ <pre><code>printf "%s.b32.i2p\n" $(head -c 391 /home/i2p/.i2pd/<strong>example.dat</strong> |sha256sum|xxd -r -p | base32 |sed s/=//g | tr A-Z a-z)</code></pre>
+
+ <h2>Adding the Nginx Config</h2>
+ <p>
+ From here, the steps are almost identical to setting up a normal website configuration file.
+ Follow the steps as if you were making a new website on the webserver
+ <a href="nginx.html">tutorial</a> up until the server block of code. Instead, paste this:
+ </p>
+
+ <pre><code>server {
+listen 127.0.0.1:8080 ;
+root /var/www/<strong>example</strong> ;
+index index.html ;
+}</code></pre>
+
+ <aside>
+ <h4>Clarifications<h4>
+ <p>
+ Nginx will listen in port 8080, but i2pd will forward your port
+ 8080 to the i2p site port 80. This way you don't have to deal with server names or anything like that
+ </p>
+ </aside>
+ <p>
+ From here we are almost done, all we have to do is enable the site and reload nginx which is also covered in <a href="nginx.html#enable">the webserver tutorial</a>.
+ </p>
+
+ <h3>Update regularly!</h3>
+
+ <p>Make sure to update I2P on a regular basis by running:</p>
+ <pre><code>apt update && apt install i2pd</code></pre>
+ <p><strong>Contributor</strong> - <a href="https://qorg11.net" target="_blank">qorg11</a></p>
+
+ </main>
+ <footer><a href="https://landchad.net">LandChad.net</a></br>Because Everyone should be an Internet LandChad.</br><li><a href="index.html"><img src="pix/chad.gif" alt="chad"></a></li><li><a href="rss.xml"><img src="pix/rss.svg" alt="RSS"></a></li><li><a href="pix/btc.png"><img src="pix/btc.svg" alt="BTC"></a></li><li><a href="pix/xmr.png"><img src="pix/xmr.svg" alt="XMR"></a></li><li><a href="https://github.com/lukesmithxyz/landchad"><img src="pix/git.svg" alt="Github"></a></footer>
+ </body>
+</html>