Skip to content
This repository was archived by the owner on Dec 7, 2023. It is now read-only.

node: ? ?? New Release - a Docker image, plz #824

Closed
PureKrome opened this issue Sep 24, 2021 · 15 comments
Closed

node: ? ?? New Release - a Docker image, plz #824

PureKrome opened this issue Sep 24, 2021 · 15 comments
Labels

Comments

@PureKrome
Copy link

It's 2021. Lets not ask people to download code to install the CLI or even download an exe and then install an extra db, etc.

Lets make this really simple for developers and offer a docker image with everything in it.

please.

thank you kindly! 🍰

@vncoelho
Copy link
Member

Agreed.

@Jim8y
Copy link
Contributor

Jim8y commented Sep 24, 2021

Except for the docker image, i also think we need some scripts for different environment setup or tests.

@PureKrome
Copy link
Author

Except for the docker image, i also think we need some scripts for different environment setup or tests.

And what would these scripts be doing? As in ... as a developer, i don't want scripts because this means i have to do stuff to setup my environment to experiment with Neo3. Too much of a barrier to entry. All i should do is

=> docker run -it neo3

or whatever. and off i go.

@Jim8y
Copy link
Contributor

Jim8y commented Sep 24, 2021

And what would these scripts be doing? As in ... as a developer, i don't want scripts because this means i have to do stuff to setup my environment to experiment with Neo3. Too much of a barrier to entry. All i should do is

script to run in testnet, script to run in mainnet, script to run in private net, script to install everything needed in a new syste

@PureKrome
Copy link
Author

ah yes. misunderstood! yep, some simple CLI commands would definitely simplify things

@PureKrome PureKrome changed the title New Release - a Docker image, plz ❤ 🚀 New Release - a Docker image, plz Sep 24, 2021
@hurui200320
Copy link

For those who just want to spin up a node, I really like a docker image so I can docker run ....

However, I do notice the modular design for N3 nodes. Like the plugin system, if you're on the testnet, when you download a plugin, it's likely your node is running on testnet, but your plugin is configured for mainnet (because of the default value). So I'm expecting some code refactor first, like allowing plugins to fetch network id (and other common settings) from an internal API, or something else (I'm not writing any C#, so I'm sorry if I was wrong).

Then we can have a better experience with the docker image.

Or we can have some shell script to build docker image locally, based on what you need. For example, I need the plugin A, B, and C, and a node for testnet. Then the script will clone the node's code, compile it, download the desired plugins, make the config, then pack them into a docker image.

Or just offers different levels of docker images. Like light for bare nodes, medium for every plugin except consensus, and full for consensus nodes.

@Jim8y
Copy link
Contributor

Jim8y commented Apr 6, 2022

Is this what you are looking for #863 neo-project/neo#853 ?

@hurui200320
Copy link

hurui200320 commented Apr 6, 2022

Not exactly is. If you dig into the plugin's config, you will notice some plugins have their own network id in their config, if that value doesn't match with the node's config, the plugin won't work, and there is no warning or error. I think that can be achieved if the plugin can fetch config from the node, aka I only set the network id in the node's config, and there won't be the same config for plugins.

And I want a docker image because I like docker and use docker a lot in my Java development. With neow3j (N3's Java SDK), you can use test container to spin up some neo-express containers. But when I want to spin up a testnet or mainnet node on my own server, it's glad to use docker since I have already had containers running on it.

However, I think you can/should solve the plugin config issue if you want to switch back and forth from different configs. Otherwise the plugins' config would be a nightmare.

@Jim8y
Copy link
Contributor

Jim8y commented Apr 6, 2022

I've confirmed with other developers, the reason that we dont fetch network id from the node is because plugin could and might work in different networks with the node~~~~but i think it wont be a problem if we just add one more command to synchronize network settings here neo-project/neo#853. How do you think?

@hurui200320
Copy link

plugin could and might work in different network with the node

Hmmm, I can't figure out a situation where I need that feature.

But that reminds me of a feature in Java's springboot. I also see something like config.mainnet.json, config.testnet.json. In springboot, we have different "profiles". that refers to different configs. The config files are named application.<profile_name>.yml, and you can specify different profiles to active different configs.

So I'm wondering if you can implement that for the neo node. Maybe we can have something like that for both nodes and plugins. When someone wants mainnet, just run neo-cli --mainnet, and can be switched to testnet by running neo-cli --testnet. This should sync the node and plugins into a consistent config.

Or to give max flexibility, someone can have neo-cli --node mainnet --token-tracker testnet to run the whole node on mainnet, but token-tracker plugin on testnet.

@Jim8y
Copy link
Contributor

Jim8y commented Apr 6, 2022

Lmao, bro, that is basically what neo-project/neo#853 is doing. I added exactly the same command as you mentioned in neo2.x at #415, but for some unknown reason they are removed in N3.

@hurui200320
Copy link

Oh. I saw there are config files has that naming, so I'm infering (because I have never tried it) the node has that profile switch feature.

Anyway, I think with that pr, it would be much easier to pack docker image. Huge thanks to your work :)

@roman-khimov
Copy link

plugin could and might work in different network with the node

Hmmm, I can't figure out a situation where I need that feature.

NeoFS. C# implementation of it is structured as a plugin (or a set of plugins, neo-project/neo-modules#681, neo-project/neo-modules#630) and there is a sidechain there that is an independent network.

@gsmachado
Copy link
Contributor

gsmachado commented Oct 26, 2022

Hello folks 👋

I haven't seen this issue...

But, here it goes:
https://github.com/AxLabs/neo3-privatenet-docker

@shargon shargon changed the title ❤ 🚀 New Release - a Docker image, plz node: ? ?? New Release - a Docker image, plz Dec 5, 2023
@shargon shargon added the node label Dec 5, 2023
@shargon
Copy link
Member

shargon commented Dec 5, 2023

Duplicated with neo-project/neo#3016

@shargon shargon closed this as completed Dec 5, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

7 participants