mirror of https://github.com/k3s-io/k3s
Fix build on 32 bit processors.
parent
9f2750694c
commit
ffcdb9dfb7
|
@ -40,8 +40,8 @@ var (
|
|||
dockerEndpoint = flag.String("docker_endpoint", "", "If non-empty, use this for the docker endpoint to communicate with")
|
||||
etcdServer = flag.String("etcd_server", "http://localhost:4001", "If non-empty, path to the set of etcd server to use")
|
||||
// TODO: Discover these by pinging the host machines, and rip out these flags.
|
||||
nodeMilliCPU = flag.Int("node_milli_cpu", 1000, "The amount of MilliCPU provisioned on each node")
|
||||
nodeMemory = flag.Int("node_memory", 3*1024*1024*1024, "The amount of memory (in bytes) provisioned on each node")
|
||||
nodeMilliCPU = flag.Int64("node_milli_cpu", 1000, "The amount of MilliCPU provisioned on each node")
|
||||
nodeMemory = flag.Int64("node_memory", 3*1024*1024*1024, "The amount of memory (in bytes) provisioned on each node")
|
||||
)
|
||||
|
||||
func startComponents(etcdClient tools.EtcdClient, cl *client.Client, addr string, port int) {
|
||||
|
|
|
@ -114,11 +114,14 @@ func RunScheduler(cl *client.Client) {
|
|||
}
|
||||
|
||||
// RunControllerManager starts a controller
|
||||
func RunControllerManager(machineList []string, cl *client.Client, nodeMilliCPU, nodeMemory int) {
|
||||
func RunControllerManager(machineList []string, cl *client.Client, nodeMilliCPU, nodeMemory int64) {
|
||||
if int64(int(nodeMilliCPU)) != nodeMilliCPU || int64(int(nodeMemory)) != nodeMemory {
|
||||
glog.Fatalf("Overflow, nodeCPU or nodeMemory too large for the platform")
|
||||
}
|
||||
nodeResources := &api.NodeResources{
|
||||
Capacity: api.ResourceList{
|
||||
resources.CPU: util.NewIntOrStringFromInt(nodeMilliCPU),
|
||||
resources.Memory: util.NewIntOrStringFromInt(nodeMemory),
|
||||
resources.CPU: util.NewIntOrStringFromInt(int(nodeMilliCPU)),
|
||||
resources.Memory: util.NewIntOrStringFromInt(int(nodeMemory)),
|
||||
},
|
||||
}
|
||||
minionController := minionControllerPkg.NewMinionController(nil, "", machineList, nodeResources, cl)
|
||||
|
|
Loading…
Reference in New Issue