Installing a server locally or in the cloud
SmartESP server is a universal solution and therefore it can be installed both on a local computer and on a cloud server.
Local option
If you choose the local option , then in this case, each controller will need to be assigned a static IP address. This can be done when installing the firmware on it. In this case, when adding a controller to the project, you specify its IP address to which the SmartESP server will access. In addition, in the home router settings, you will also need to assign a static (permanent) IP address for the server.
With the local option, you will not need any special router for specific settings. However, smart home management will be available by default only locally - by the server IP address. For remote management via the Internet, you will need to get a fixed IP address from the provider and forward ports on the router.
Cloud option
By choosing the cloud option , you get access to the server as a regular website on the Internet. In this case, you will need to rent the server itself and purchase a domain name for it. And so that the server can access the controllers, a VPN connection L2TP/IPsec will be used.
We have tried to simplify and automate the configuration of the connection of controllers to the server. To do this, you will need to purchase a Mikrotik router , which has a built-in VPN client, and then connect it to the server . Please note that only the router is connected via a VPN connection, and the controllers are simply registered on the server with automatic configuration.
Installing the server
Prepare a server for installation, for example, rent it on the Digital Ocean platform for the cloud option, or assemble a local home PC. In the initial state, you get a clean operating system, we recommend that it be Ubuntu 24.04 LTS , this is the system for which the SmartESP server was developed and tested.
As already mentioned, you need to have an IP address for the local server, such as 192.168.88.100 , or a registered domain name for the cloud server, such as test.smartesp.net . Also, this domain name must already refer to the IP address of the cloud server. This is done in the DNS settings of the domain name registrar panel, by adding an A record, for example:

Now everything is ready to install the SmartESP server. To simplify this process, we have written a special bash script that can be downloaded using the wget utility:
wget https://smartesp.net/install.sh
after this run:
sh install.sh
This interactive script will ask you for information:
- type of server being installed,
- IP address (for local server) or domain name (for cloud server),
- master key - create a special password for the server administrator.

Next, the necessary components will be downloaded and installed. After installing the server, open it in the browser (using the specified IP address or domain name) and perform the initial installation (creating a database) by clicking the Start button.

After that, register a new user using the master key you specified earlier during installation. That's it! Your own server is ready to work.