Allow OpenShift to start in roles master and node

Adds a "master" or "node" optional role argument to the start command.  Separates the --listen, --master, and --etcd parameters and makes them default to values that work for the local cluster more effectively.  Split code for starting components into their own packages.
glog.Fatalf prints an error then calls os.Exit(1)


> On Oct 14, 2014, at 1:36 PM, Ben Parees <notifications@github.com> wrote:
> 
> In pkg/cmd/master/kubernetes/node.go:
> 
> > +type NodeConfig struct {
> > +	BindHost   string
> > +	NodeHost   string
> > +	MasterHost string
> > +	VolumeDir  string
> > +
> > +	NetworkContainerImage string
> > +
> > +	EtcdClient   *etcd.Client
> > +	DockerClient *docker.Client
> > +}
> > +
> > +func (c *NodeConfig) EnsureDocker(docker *dockerutil.Helper) {
> > +	dockerClient, dockerAddr := docker.GetClientOrExit()
> > +	if err := dockerClient.Ping(); err != nil {
> > +		glog.Errorf("WARNING: Docker could not be reached at %s.  Docker must be installed and running to start containers.\n%v", dockerAddr, err)
> docker.getClientOrExit() claims that it does exit (though it does not appear to do so). It also claims that it does a docker ping, but does not appear to do so... should we move your ping logic into the GetClientOrExit method? and/or rename + cleanup the comments on GetClientOrExit?
> 
> // GetClientOrExit returns a valid Docker client and the address of the client,
> // or prints an error and exits. If Docker can't be reached via a ping it prints a
> // warning.
> 
> —
> Reply to this email directly or view it on GitHub.