Completely unattended local Blynk-Server setup

hi!

i would like to try this out. i’m not a linux user (have very limited knowledge), so someone could please explain step by step what should i do?

i have a pi zero w + clean raspbian intalled, upgraded, based on this instruction.

so, whats next?

  • i just have to run these commands, and that’s all? or there are other stuff to prepare before? eg. creating directory structure, setting access rights, etc?

  • if i understand correctly, this version doesn’t has the auto update feature implemented yet?

thanks!

This is for Server install…

Quick local server setup on Raspberry PI
https://github.com/blynkkk/blynk-server#quick-local-server-setup-on-raspberry-pi

This this is for the Client, if you also want it…

How to install Node.js library on Linux

http://help.blynk.cc/how-to-connect-different-hardware-with-blynk/raspberry-pi/how-to-install-nodejs-library-on-linux

I haven’t tried @fragolinux method again, since he updated it… but it is should be a more automated Local Server install… But you learn less, and that might make troubleshooting more difficult in the future.

1 Like

yes, that’s all… at the end you’ll get the url to connect to (https://yourip:9443) and the default user and pass generated during install, which are:
user: admin@blynk.cc
pass: admin

my script is just for easy and fast install, it’s up to you to make the install secure (changing credentials ASAP) and learn how to use or to add more advanced settings, as the official guide explains very well…

oh, and there’s no autoupdate, nor i think it will ever be… i just want to add an option to update, ON REQUEST, the actual install, something like:
sudo /etc/init.d/blynk update
of course don’t try this now, as it’s not there, yet…

1 Like

quite the opposite, instead… the script is there and you know EXACTLY what it does, so you know EXACTLY what can eventually go wrong, while an user manual install could be ANYTHING, from wrong folder, to wrong permissions, and who knows… and many just want to “play” with something and don’t go in details they’ll never understand or need…

Ya… but thats how I seem to learn best… by hands on. That said, I have already manually installed my own server on a Mint netbook, so trying out another with your method will only add to my experience. :wink:

Looking through the code, it seems that updating down the road is as simple as re-running the script again? Is that correct… and subsequent script runs will retain existing settings & data, and just update the Server versions?

guys, thanks for the info.

@Gunner, in the past i already done local server setup the manual way. so that was for learning:

now i would like to try the automated way, to see how it goes.

Ditto :stuck_out_tongue: I thought you had more experience on this… but I couldn’t remember… and didn’t look back into your posts… my bad.

i use linux very very rarely, so i tend to forget things in between uses.

the easiest way would be to stop the server, download the new JAR, restart the server… the cleaner version would be to check if a new version is available and download only if it is… still have to decide what path to go to… of course no data will be modified in both cases

oh, and of course that’s how i learn, too… the fact that i made this script is to make an easier life to newbies, but to do that, you need to learn by yourself, or you can’t just do it :slight_smile:

1 Like

I am running it now… and so far it is installing Java 8 just fine (on my old RPi)… :smiley:

I have been through the pain of manually setting up Pi’s with Blynk on several occasions. It’s not so bad now as I have SD cards I can clone but I think an automated script is an excellent idea. Many people like to drive but they don’t have a clue how the engine works.

@fragolinux can you add the client too please :slight_smile:

what client? The smartphone client has to be downloaded from app stores, then you have to go in settings and let it point to your local server, that’s it…
it’s detailed here: https://github.com/blynkkk/blynk-server#app-and-sketch-changes

No, thats the App… the Client is what we call the script installed on the Arduino/ESP/RPi, etc…

How to install Node.js library on Linux
http://help.blynk.cc/how-to-connect-different-hardware-with-blynk/raspberry-pi/how-to-install-nodejs-library-on-linux

I have to use the “Manual Node.js installation” method due to the older processor on my RPi Model B

@fragolinux the MCU client that many run on Arduino’s and ESP’s.

Well, it installed with no issues :+1: Very nice @fragolinux :smiley:

That was easy… now I have to remember how to tweek it like my original, then copy all my data over, to give the old RPi a good test as my full time server… and soon, double duty as a client as well.

oh, and how to automatize that??? I’ve to take a look…
BTW the nodejs part is well covered in the script of my friend Peter Scargill, script to which a dedicate A LOT of time (with the author of course) to add always newer options and let it install on as many SBCs as we can… take a look here: https://tech.scargill.net/a-christmas-script/

no, you can have that automatic, too, we added that install part to Peter’s script quite some time ago… if it’s an old RPi, the script will recognize it and install the correct version… look my other comment up here for link

1 Like

@fragolinux Well my old RPi was just too unstable it seems (lots of stuttering and flat out stopped running many times), so I set it aside…

Then today, I remembered I have a couple of C.H.I.P.s that I had once installed Blynk Server on ages ago… so I reflashed one with the latest headless firmware (Debian I believe) and ran your script on it.

It loaded up just fine and I have it running a test project to see if it is a worthy Blynk Server replacement for my netbook.

Once concern I have… your install seems to dump everything in the “main?” directory instead of in a Blynk folder off the home/chip directory (in my case)… that makes it a bit messy in my view.

Also, didn’t you have a “pre-done” server.properties and mail.properties file at one time… all ready for customising? I can’t find them anymore.

Wowzer… my life goals never included “learning Linux”… but here I am, regardless of my (lazyish) tendencies :persevere:

OK, I found the Blynk folder, locked away in the root folder (of which I originally had no access to, as a normal user login). I managed to move everything Blynk related into the /home/chip/Blynk folder and switch said folder to user permissions, and setup my email… then, for some reason, I needed to redo the /etc/rc.local for proper server action at bootup.

Pheww… a bit more “attendance needed” then I originally hoped for :stuck_out_tongue: But it seems to be working as “normal” now. EDIT - only now I have no idea how to update the server down the road… arggg, more learning needed :stuck_out_tongue_winking_eye:

Perhaps there was a reason for having it in Root access… but might I recommend keeping it more like the “official” install locations and permissions?

New development… When I powered down the server to move it into its permanent location under a shelf…

While it rebooted fine and the server is running… it had wiped out the user account?? (well the account file was still there, just as 0 data and unregistered in the administration page).

Copying the file over from the backup folder and rebooting the server again brought everything back to “normal”.

Honestly, I am unsure if this is related to this install method or my ministrations in moving everything into a single, user provisionable, folder… it has happened once before (yesterday), but I can’t remember the time frame, and had written it off as a one-time glitch… guess it’s not :stuck_out_tongue:

Any ideas on this?

1 Like