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

Wrap master node in docker container #296

Merged
merged 88 commits into from Dec 4, 2018
Merged

Wrap master node in docker container #296

merged 88 commits into from Dec 4, 2018

Conversation

folex
Copy link
Member

@folex folex commented Nov 30, 2018

Changes

  • refactor work with config files
  • simplify docker entrypoints
  • use alpine instead of ubuntu in docker containers, heavily reduce image size
  • wrap master node in docker container
  • start solver containers from within master container by sharing host docker.sock

Usage

  • You can run master node as docker run -e "TENDERMINT_IP=host.docker.internal" -e "PORTS=20000:20002" -v /var/run/docker.sock:/var/run/docker.sock -it fluencelabs/master
    • NOTE: host.docker.internal should be used for macOS, on linux you can just pass your IP

@@ -26,7 +27,7 @@ import io.circe.parser.parse
*
* @param masterTendermintPath Tendermint's home directory
*/
case class KeysPath(masterTendermintPath: String) extends slogging.LazyLogging {
case class KeysPath(masterTendermintPath: String)(implicit ec: ContextShift[IO]) extends slogging.LazyLogging {
Copy link
Member

Choose a reason for hiding this comment

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

why the implicit is needed here?

Copy link
Member

Choose a reason for hiding this comment

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

+1

alari
alari previously requested changes Dec 4, 2018
@@ -7,7 +7,8 @@ matrix:
services:
- docker
install:
- docker pull fluencelabs/solver:latest
- docker pull fluencelabs/solver:2018-dec-demo
Copy link
Member

Choose a reason for hiding this comment

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

Should it be merged to master?

Copy link
Member Author

@folex folex Dec 4, 2018

Choose a reason for hiding this comment

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

There problem is that I can't really release new docker images before I merge this PR to master, and tests in the PR won't pass before I release new docker images.

So this is a workaround, I will create the next pull request after I release new docker images as 'latest', where I will change images to latest everywhere.

build.sbt Show resolved Hide resolved
node/src/main/scala/fluence/node/Configuration.scala Outdated Show resolved Hide resolved
node/src/main/scala/fluence/node/Configuration.scala Outdated Show resolved Hide resolved
node/src/main/scala/fluence/node/Configuration.scala Outdated Show resolved Hide resolved
@@ -26,7 +27,7 @@ import io.circe.parser.parse
*
* @param masterTendermintPath Tendermint's home directory
*/
case class KeysPath(masterTendermintPath: String) extends slogging.LazyLogging {
case class KeysPath(masterTendermintPath: String)(implicit ec: ContextShift[IO]) extends slogging.LazyLogging {
Copy link
Member

Choose a reason for hiding this comment

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

+1

node/src/main/scala/fluence/node/tendermint/NodeInfo.scala Outdated Show resolved Hide resolved
@DieMyst DieMyst merged commit 6f08053 into master Dec 4, 2018
@folex folex deleted the network/node-docker branch December 18, 2018 07:26
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.

None yet

4 participants