Tutorial: Host your own IPFS node and help the next generation of web

The full article was originally published by David Hawig on Medium. Read the full article here.

In the last tutorial we showed you how to host our service locally. Now we’re going to cover how you can set up your own IPFS node and be part of Dweb.page. It’s important to mention that you can use an IPFS node for a lot of interesting projects and ideas. So even if you have no interested in Dweb.page this tutorial might still provide some value for you.

The following is based on the great tutorial series by Carson Farmer.

Getting a server

To host an IPFS node online, you’re going to need an Ubuntu web server. Generally, you can choose between a lot of different companies for this. Our recommendation for an IPFS node is to look out for the data transfer pricing model because that will be the most expensive part of running your node. For example, AWS charges $0.09/GB which can be quite expensive, and it doesn’t help to decentralize the web if everyone is using AWS 😉.

We’ll be using the Cloud Server M with Ubuntu 18.04 by IONOS for this tutorial since they charge nothing for the data transfer and with the 100$ credit, you can test everything for free at the beginning. But there might be other even better solutions so feel free to use whatever you prefer!

Connecting to your server

We’re using PuTTY to connect to our server. PuTTY is a Secure Shell (SSH) client, which gives us access to the command line of our web server. You can download it here. Once you installed it, you need to know your DNS Hostname. On IONOS you find it in the cloud panel if you click on your server. Next, open PuTTY and enter your hostname. Make sure the port number is set to 22. You can now save this to open the connection in the future easily.

Enter your host and establish the connection

Now click on open and enter your name plus password. Depending on your service provider you either did create a password during the setup process, or you need to create pem file or create a new password first. If everything is correct you should see something like this:

Install IPFS

For installing IPFS on your server, we need to type quite a lot of Linux commands. We’ll present you the commands first, and the explain them a below. So, if you’re not interested in it, you can copy paste it into your command line.

wget https://dist.ipfs.io/go-ipfs/v0.4.18/go-ipfs_v0.4.18_linux-amd64.tar.gz
tar xvfz go-ipfs_v0.4.18_linux-amd64.tar.gz
rm go-ipfs_v0.4.18_linux-amd64.tar.gz
sudo mv go-ipfs/ipfs /usr/local/bin
rm -rf go-ipfs
ipfs init -p server

The wget command downloads the latest IPFS version on your machine. Then you unpack it with tar xvfz and remove the downloaded archive with rm. sudo mv then moves it to a different directory, and we remove the unpacked folder with rm.

Read the full Article

The full article was originally published by David Hawig on Medium, where people are continuing the conversation by highlighting and responding to this story.

You might also like

This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. AcceptRead More