-
Pre-Conditions: https://docs.docker.com/engine/swarm/swarm-tutorial/#/three-networked-host-machines For distributed Minio to run, you need 4 networked host machines.
-
Create a new swarm and set the manager. SSH to one of the host machine, which you want to set as manager and run:
docker swarm init --advertise-addr <MANAGER-IP>
-
Current node should become the manager. Check using:
docker node ls
-
Open a terminal and ssh into the machine where you want to run a worker node.
-
Run the command as output by the step where master is created. It will add the current machine (as a worker) to the swarm. Add all the workers similarly.
-
Check if all the machines are added as workers, SSH to the master and run:
docker node ls
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:model/blocs/base_bloc.dart'; | |
/// Used to give [child] and all it's subsequent children access to [blocs]. | |
/// To get a reference to 'SomeBloc' from a child use: BlocsProvider.of<SomeBloc>(context) | |
class BlocsProvider extends StatefulWidget { | |
BlocsProvider({Key key, @required this.child, @required this.blocs}) | |
: super(key: key); | |
final Widget child; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'package:model/blocs/base_bloc.dart'; | |
/// Used to give [child] and all it's subsequent children access to [blocs]. | |
/// To get a reference to 'SomeBloc' from a child use: BlocsProvider.of<SomeBloc>(context) | |
class BlocsProvider extends StatefulWidget { | |
BlocsProvider({Key key, @required this.child, @required this.blocs}) | |
: super(key: key); | |
final Widget child; |