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

Add a script to run local docker based cluster #18425

Merged
merged 1 commit into from Dec 10, 2015

Conversation

fgrzadkowski
Copy link
Contributor

This introduces a script to run a local docker based cluster, which is similar to what we already have for a regular cluster. Once we fix remaining issues with docker based setup I'd like to serve it from get.k8s.io/local so that user can play with kubernetes using just one command.

Output from the successful run of this script:

$ ./cluster/get-kube-local.sh 
Downloading kubectl binary...SUCCESS

Creating a local cluster:
    Starting kubelet...SUCCESS
    Waiting for master components to start...................SUCCESS
Cluster created!

Kubernetes master is running at http://localhost:8080


To list the nodes in your cluster run
    kubectl -s=http://localhost:8080 get nodes

To run your first pod run
    kubectl -s http://localhost:8080 run nginx --image=nginx --port=80

@brendandburns - I assigned this to you as wrote the other script for regular clusters, but feel free to reassign.

@roberthbailey @mikedanese

Ref #12722

This depends on #18351

@k8s-github-robot
Copy link

Labelling this PR as size/L

@k8s-github-robot k8s-github-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Dec 9, 2015
@k8s-bot
Copy link

k8s-bot commented Dec 9, 2015

GCE e2e build/test failed for commit bd7cd74.

@brendandburns
Copy link
Contributor

@k8s-bot test this please

@brendandburns
Copy link
Contributor

This LGTM, but you might want to at least add a TODO to integrate/share code with:

https://github.com/kubernetes/kubernetes/blob/master/docs/getting-started-guides/docker-multinode/master.sh

@brendandburns brendandburns added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Dec 10, 2015
@@ -0,0 +1,168 @@
#!/bin/bash

# Copyright 2014 The Kubernetes Authors All rights reserved.
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: 2015 (at least for a few more weeks)

@k8s-bot
Copy link

k8s-bot commented Dec 10, 2015

GCE e2e test build/test passed for commit bd7cd74.

@wojtek-t
Copy link
Member

@k8s-bot unit test this please

@k8s-github-robot
Copy link

Automatic merge from submit-queue

k8s-github-robot pushed a commit that referenced this pull request Dec 10, 2015
@k8s-github-robot k8s-github-robot merged commit f326c4d into kubernetes:master Dec 10, 2015
fgrzadkowski added a commit to fgrzadkowski/kubernetes that referenced this pull request Dec 10, 2015
@fgrzadkowski
Copy link
Contributor Author

@roberthbailey I addressed your comments in #18512

timstclair pushed a commit to timstclair/kubernetes that referenced this pull request Dec 10, 2015
openshift-publish-robot pushed a commit to openshift/kubernetes that referenced this pull request Mar 23, 2018
Automatic merge from submit-queue.

UPSTREAM: 59301: dockershim: don't check pod IP in StopPodSandbox

We're about to tear the container down, there's no point.  It also suppresses
an annoying error message due to kubelet stupidity that causes multiple
parallel calls to StopPodSandbox for the same sandbox.

docker_sandbox.go:355] failed to read pod IP from plugin/docker: NetworkPlugin cni failed on the status hook for pod "docker-registry-1-deploy_default": Unexpected command output nsenter: cannot open /proc/22646/ns/net: No such file or directory

1) A first StopPodSandbox() request triggered by SyncLoop(PLEG) for
a ContainerDied event calls into TearDownPod() and thus the network
plugin.  Until this completes, networkReady=true for the
sandbox.

2) A second StopPodSandbox() request triggered by SyncLoop(REMOVE)
calls PodSandboxStatus() and calls into the network plugin to read
the IP address because networkReady=true

3) The first request exits the network plugin, sets networReady=false,
and calls StopContainer() on the sandbox.  This destroys the network
namespace.

4) The second request finally gets around to running nsenter but
the network namespace is already destroyed.  It returns an error
which is logged by getIP().

Fixes: openshift/origin#18414

@danwinship

Origin-commit: 73e9c8fa185d0f7bb9a0798185f78598cf4bb42b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants