masternodes / vps

A handy bash script to setup crypto masternodes in no time. Initially developed for $PIVX. Now many more ;-)
https://masternodes.github.io/vps/
GNU General Public License v3.0
250 stars 489 forks source link

Adding additional nodes after first run #133

Closed ImTheDeveloper closed 6 years ago

ImTheDeveloper commented 6 years ago

I've setup a vps with 3 nodes right now and I planned on adding a couple more today however noticed the script doesnt seem to handle the situation too well.

Initially running something like: ./install.sh -p jew -c 3 -n 6 Will provide 3 masternode services, on three separate ipv6 addresses along with 3 configuration files of the order:

jew_n1.conf
jew_n2.conf
jew_n3.conf

If I were to then run the script again with: ./install.sh -p jew -c 2 -n6

I would expect the script to check the current ipv6 addresses in use, allocate another 2 and also to check the masternode config folder for the given coin and do the same with an output similar to:

jew_n1.conf
jew_n2.conf
jew_n3.conf
jew_n4.conf
jew_n5.conf

What actually happens right now is the script runs through quite quickly, since all of the compiles are done but it outputs:

There is still work to do in the configuration templates.
These are located at /etc/masternodes, one per masternode.
Add your masternode private keys now.
eg in /etc/masternodes/jew_n1.conf

=>  All configuration files are in: /etc/masternodes
=>  All Data directories are in: /var/lib/masternodes

We are left with the same jew_n1-3.conf files, there are no additional ones created. It hasn't over-written the data in any of those configuration files, everything remains as is.

Am I missing anything here or is this the current behaviour? If I want to add additional nodes can I still use the script with some edits? It's a great setup and I'd like to continue using it in this scenario.

ImTheDeveloper commented 6 years ago

Just realised that if the script isn't messing up my existing configuration then I might be able to just run with -c 10 and it would leave the current nodes in place and add on additional ones as it's looping through.