How to install a Blynk Server in a Raspberry pi?

when i try it - chrome tells me about security issues - does you chrome do that?

I only ever use Chrome.

If it is set up correctly you will be warned about security but you can then access the unsecured web page.
You are probably missing a few steps, either the ports or the security.

Have you done this bit?

sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080
sudo iptables -t nat -A PREROUTING -p tcp --dport 443 -j REDIRECT --to-port 9443

Hi Dave

I used yet another page, but also here the warnings are missing and the info about creating an account first

http://docs.blynk.cc/#blynk-server-how-to-run-local-blynk-server-how-to-launch-blynk-server-on-raspberry-pi

The info is on multiple places but they are not 100% the same it seems

Chrome and now internet explorer just say The page cannot be displayed nothing about unsecure page or something. However you mentioned something else to try which I not did before so I will try. It just seems I know too little to make this simply working.

Update: just did your reroute suggestions: did not helpā€¦Why do I not see a reroute for 7443 like you mentioned in your login link https://[IP]:7443/admin ?

Because it should work like this if you go to that webpage. Iā€™m not even sure why you would want to redirect ports. Normally you would just assign your server other ports (but Iā€™m not sure if that is possible with Blynk server as it is).

I believe the iptables are for other features within the server like the API, QR codes etc.
Port 7443 is hard coded in the server.
Did you go through the certification?

For local servers you canā€™t have proper certificates, even free Lets Encrypt certs as they need to be tied to a domain. But the docs do cover self signing certs with openSSL etc.

Re-assigning those ports with IP tables happens on a local level. So if you redirect 443 to 8443, it just means when you go to the server on 443 port, it will redirect you to 8443. I still donā€™t understand why you would need that. Itā€™s just useless to do, unless your application on the other end cannot talk to Blynk server on non-default ports. In all other cases this is only confusing.

And you can definitely have proper certificates for your local blynk server, provided you own a domain name and set everything up properly (which is a hell of task, Iā€™ll be the first one to admit that :wink: ).

That was the point I was trying to make.

@Lichtsignaal @Costas
I have the whole thing running now, using local server my robot can be controlled with my (cloned) blynk app!
Do I really need that admin page? Because I can not reach it no matter what I do, certificates is not something I know anything about. And I was a Kickstarter backer so I have a large amount of energy/credit for blynk sketches I imagine more then I need in a lifetime :slight_smile:

Is your Kickstarter ā€œEnergyā€ showing in the app for local server?

Yes and I must take back my words: I DO need to get to the admin page because I only have 1200 as energy and a simple function already costs 200!

Did you create the server.properties file? You need to add to that file which IPā€™s are allowed to access the admin page. It looks like this:

#ADMINISTRATION SECTION

#admin monitoring port.
server.admin.port=7443
admin.rootPath=/admin
allowed.administrator.ips=0.0.0.0/0

This part has to be in the server.properties file for the admin page to work

No I did not, I have no clue about these things I thought I have default access with the link that another user posted. How do I create such a file?

@Dennis_van_Elteren itā€™s all covered in the GitHub docs and includes a link to a sample server.properties file for you to use https://github.com/blynkkk/blynk-server

Study the docs closely for your specific hardware as a single step missed will result in problems for you.

The easiest way is to copy from github repository. I just grabbed the source files (zip) from github, and found inside server.properties file (there are more than one, though) Then modified it for my needs.

I used the text editor Nano

Just type nano in the terminal window, it will open up a editor with a blank document - then add things like this to yours - The server.ssl stuff might be optional unless you figured out how to generate your own certificatesā€¦ took me ages to stumble around that one :wink:

server.ssl.cert=./server.crt
server.ssl.key=./server.pem
server.ssl.key.pass=*********

administration.https.port=7443
admin.rootPath=/admin
allowed.administrator.ips=0.0.0.0/0
allowed.users.list=*********@gmail.com

All the commands for the editor are on the bottom and the ^ means CTRL key

So after entering the info, use CTRL-O to Write Out (aka Save) it as server.properties
then CTRL-X to exit the editor

tnx all!

Hi,I have the same problem with you.so,How to add the IPv6 range to the allowed.administrator.ips ??

A post was split to a new topic: Problems creating certificates