Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix neo-scan and use latest version #19

Merged
merged 10 commits into from
May 23, 2018
Merged

Fix neo-scan and use latest version #19

merged 10 commits into from
May 23, 2018

Conversation

adrienmo
Copy link
Contributor

@adrienmo adrienmo commented May 18, 2018

Rather than building a neoscan image, the docker-compose can refer directly to a production ready container that supports custom variables to configure the host/nodes/notifications server.
For this reason the neo-scan folder is now useless.
One neo-python container in the docker network was added to act as the local notification server.

custom-config.json for the notification server was copied from the privnet example but the ip of nodes where changed (--privnet and --host options cannot be used together unfortunately).

@vncoelho
Copy link

Good moves, adrienmo.

You are good on it! 🗡️

…w image allowing running at localhost address
@adrienmo
Copy link
Contributor Author

The new version now run on : http://localhost:4000
it can be started with
docker-compose up -d

or

NOTIFICATIONS_SERVER=172.20.0.4 SEED_SERVER=172.20.0.2 docker-compose up -d

@jeroenptrs
Copy link
Contributor

You can now additionally configure the host name:
HOST_NAME=neoscanlocal.com NOTIFICATIONS_SERVER=172.20.0.4 SEED_SERVER=172.20.0.2 docker-compose up -d

This way, if you're setting up a central private testnet for an event, you can add your IP (let's say 123.4.5.6 for example) and everyone can connect to neoscan, the nodes (via neoscan) and the notifications-db with:
HOST_NAME=123.4.5.6 NOTIFICATIONS_SERVER=123.4.5.6 SEED_SERVER=123.4.5.6 docker-compose up -d

If you don't want to allow them access to the notifications server f.e., you can just leave out that part of the command

jeroenptrs
jeroenptrs previously approved these changes May 23, 2018
Copy link
Contributor

@jeroenptrs jeroenptrs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works like a charm, good stuff @adrienmo!

@revett revett self-requested a review May 23, 2018 09:18
@jeroenptrs
Copy link
Contributor

Just wanted to clarify that you can do this with make as well:
HOST_NAME=123.4.5.6 NOTIFICATIONS_SERVER=123.4.5.6 SEED_SERVER=123.4.5.6 make start

Copy link
Contributor

@revett revett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Really nice work!

Small comment around JSON formatting - easy fix.

Can you also please amend any Docker commands within the Makefile.

https://github.com/CityOfZion/neo-local/blob/master/Makefile

"RegisterTransaction": 10000
}
},

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove newline.

Easiest to run through a JSON linter, such as https://jsonlint.com

@jeroenptrs
Copy link
Contributor

@revett linted the json, no changes to any docker commands. This works out of the box with docker-compose and make 😆

Copy link
Contributor

@revett revett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🍰

@jeroenptrs jeroenptrs merged commit 6b41a2f into CityOfZion:master May 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants