Creating DigitalOcean account
After the successful setup of your IDE, it’s time to create your virtual server? For this purpose, you can use DigitalOcean, the IaaS provider. In order to get your DigitalOcean account and get 100$, use this link. It will lead you to the DigitalOcean registration page.
Setting up a new project
After creating and confirming your DigitalOcean account you can proceed with creating a new project that will be used for setting up your IoT Cloud.
Simply click on the “New Project” and be creative while naming your first IoT project, add a nice description, and proudly select “IoT” as the project type.
Ready to create your first Droplet? Great, let’s do it! By clicking on the “Get Started with a Droplet” you will start a simple wizard that will lead you through the Droplet configuration. As a first step, you will have to select the distribution of Linux that will run on your instance, we will use Ubuntu 20.04 (LTS) x64. For this purpose of learning and general development, We suggest using the Basic Shared CPU, with a 10$/month configuration, since it will give you a little bit more space and memory which will speed up some things. Choosing a region for this purpose is not much important, but I suggest you use some region that is close to your location.
Selecting the right region for your droplet is important on larger scale projects in order to optimize access for the clients, and also enable the option of interconnecting multiple droplets within the same region.
In some production environments, you can use public IPv6 networking, adding user metadata, or advanced monitoring, but this is not necessary for now.
For Authentication we will use SSH keys, that will disable Password access to our droplet and improve security. In order to use SSH, you will have to create New SSH Key (or use an existing one if you have it).
In order to create an SSH key, you will need your systems terminal or software like PuTTY. During this book series Windows Terminal that uses WSL (Windows Subsystem for Linux), that runs Ubuntu distribution will be used, but feel free to use any other terminal or application that you are familiar with since most of our work will happen on the remote server that runs Ubuntu distribution. On the internet you can find more information about installing Windows Terminal, configuring WSL 2, and installing Linux distributions.
In order to start creating your new SSH Key, you have to run the following command.
Please note that your email will be used as a label, and we are using a more secure algorithm Ed25519 which is more secure, but if your legacy system does not support it you can use RSA instead.
We suggest you using a strong password while creating this key, but be sure that you will remember it or save it to some vault. Be sure to remember the location where your key will be saved or add some custom location.
On Linux, we can use the ‘cat’ command to show our ‘your_cert_name.pub’ file and then copy it to the DigitalOcean interface. Add your key to a recognizable name and save it.
Next, we have to name our droplet (hostname), here we suggest you use something simple that will be recognizable if you will have multiple droplets within the same project later (e.g. for a project called mycloud, you can use mycloud-mqtt, mycloud-backend, mycloud-database, etc.) For now, let’s call it iot-server.
For the purpose of learning this you do not have to use tags or backups, but feel free to do so if needed.
Finally, click on Create Droplet and your droplet will be created in no time. After successful creation, your configuration should look like something like this:
Now you can finally connect to your droplet by using ssh. This command in Linux provides a secure encrypted connection between two hosts.
Although we suggest you use some kind of terminal, PuTTY will also do the thing, you can find a lot of information online on how to connect to the remote machine using PuTTY and SSH key. On the image above you can see how to use the ssh command from the terminal, be sure to provide the full path to your private key and droplet IP address displayed in DigitalOcean. Feel free to accept the warning about host authenticity if it pops up. Since our SSH key is passphrase protected you will be prompted to enter a passphrase before connecting.
We have to use root access (root user) for the initial configuration since our droplet is new and it does not contain any user.
This whole procedure is completely automated by the IoTaaP Cloud system. IoTaaP provides a fully managed IoT platform that contains all three aspects of IoT, edge hardware, software, and cloud. A solution like this gives you the possibility to focus on your product, your data and totally forget about complex IoT Cloud infrastructure, firmware deployment, and security since everything is automated and handled by IoTaaP.
IoTaaP OS Web configurator for ESP32
Introducing Web Configurator Alongside other features and improvements, we are introducing IoTaaP OS – Web Configurator. Simple web interface hosted on your device that gives you the possibility to configure all device parameters using your…
- Mar 17
- 2 mins read
Selecting the right software for IoT
In the beginning, it’s important to define project requirements and find reliable solutions based on them. Sometimes it can happen that there is no compatible platform so some parts of the system will have to…
- Mar 05
- < 1 min read
[UPDATE] iotaap becomes Open Source
- < 1 min read
let them talk.
- 2 mins read
IoTaaP Cloud 3.0 is here
- < 1 min read