Commit Graph

733 Commits (ed763b8034eebb84dd3682ab0230276b1bb23845)

Author SHA1 Message Date
Daniel Smith 86b7dbb2c6 Merge pull request #23844 from Random-Liu/proper-fake-docker-version
Set fake docker client to minimum required version.
2016-04-14 16:55:47 -07:00
Harry Zhang c31ec5607a Refactor version cache into kubelet util 2016-04-13 00:42:22 -04:00
harry f9e2f522b4 Add cache for api version
Expose runtime interface
2016-04-12 22:34:59 -04:00
Harry Zhang b4244a079f Implement OomScoreAdj in kubelet 2016-04-12 22:34:58 -04:00
Random-Liu 2b9f6bea18 Fix PullImage and corresponding node e2e test. 2016-04-12 10:42:25 -07:00
k8s-merge-robot 6a87dba0b8 Merge pull request #22733 from resouer/flow-control
Automatic merge from submit-queue

Add flow control pkg

minor fix ref #15634
Refactor pkg names in back off related files
2016-04-11 06:18:51 -07:00
Jeff Lowdermilk 1a9cb97bdd Merge pull request #23658 from Random-Liu/fix-termination-message-path
Fix TerminationMessagePath
2016-04-08 20:54:14 -07:00
Minhan Xia 3c58d1ffd3 switch to use ContainerID instead of DockerID in network plugin interface 2016-04-06 16:04:52 -07:00
Random-Liu 8fb7ee38b0 Set fake docker client to minimum required version. 2016-04-04 17:41:01 -07:00
k8s-merge-robot a2145d7b1c Merge pull request #23613 from Random-Liu/remove-out-of-date-code
Automatic merge from submit-queue

Kubelet: Remove nsinit related code and bump up minimum docker apiversion

Docker has native exec support after 1.3.x. We never need this code now.

As for the apiversion, because Kubernetes supports 1.8.x - 1.10.x now, we should bump up the minimum docker apiversion.
@yujuhong I checked the [changes](https://github.com/docker/engine-api/blob/master/types/versions/v1p20/types.go), we are not relying on any of those changes. So #23506 should work with docker 1.8.x+
2016-04-03 07:34:26 -07:00
harry 5fe773d37c Add flow control pkg
Refactor pkg names in flow control related files
2016-04-03 11:28:03 +08:00
k8s-merge-robot b43ccd6e2b Merge pull request #23506 from Random-Liu/new-docker-client
Automatic merge from submit-queue

Kubelet: Start using the official docker engine-api

For #23563.

This is the **first step** in the roadmap of switching to docker [engine-api](https://github.com/docker/engine-api).
In this PR, I keep the old `DockerInterface` and implement it with the new engine-api.
With this approach, we could switch to engine-api with minimum change, so that we could:
* Test the engine-api without huge refactoring.
* Send following PRs to refactor functions in `DockerInterface` separately so as to avoid a huge change in one PR.

I've tested this PR locally, it passed all the node conformance test:
```
make test_e2e_node

Ran 19 of 19 Specs in 823.395 seconds
SUCCESS! -- 19 Passed | 0 Failed | 0 Pending | 0 Skipped PASS

Ginkgo ran 1 suite in 13m49.429979585s
Test Suite Passed
```
And it also passed the jenkins gce e2e test:
```
go run hack/e2e.go -test -v --test_args="--ginkgo.skip=\[Slow\]|\[Serial\]|\[Disruptive\]|\[Flaky\]|\[Feature:.+\]"

Ran 161 of 268 Specs in 4570.214 seconds
SUCCESS! -- 161 Passed | 0 Failed | 0 Pending | 107 Skipped PASS

Ginkgo ran 1 suite in 1h16m16.325934558s
Test Suite Passed
2016/03/25 15:12:42 e2e.go:196: Step 'Ginkgo tests' finished in 1h16m18.918754301s
```

I'm writing the design document, and will post the switching roadmap in an umbrella issue soon.

@kubernetes/sig-node
2016-04-02 04:51:33 -07:00
Random-Liu 5dbac3a8b8 Fix TerminationMessagePath 2016-03-30 16:03:49 -07:00
k8s-merge-robot 6226cbe6ca Merge pull request #23308 from yifan-gu/rkt_bump
Automatic merge from submit-queue

rkt: bump rkt version to 1.2.1

Upon bumping the rkt version, `--hostname` is supported. Also we now gets the configs from the rkt api service, so `stage1-image` is deprecated. 

cc @yujuhong @Random-Liu
2016-03-30 05:42:58 -07:00
k8s-merge-robot 2a690cc5e2 Merge pull request #23059 from luxas/auto_arch_pause
Automatic merge from submit-queue

Make kubelet use an arch-specific pause image depending on GOARCH

Related to: #22876, #22683 and #15140
@ixdy @pwittrock @brendandburns @mikedanese @yujuhong @thockin @zmerlynn
2016-03-29 23:27:42 -07:00
Random-Liu 1459a17dbe Remove nsinit related code and bump up minimum docker apiversion 2016-03-29 18:21:50 -07:00
Rudi Chiarito ca6bdba014 Allow lazy binding in credential providers; don't use it in AWS yet
This is step one for cross-region ECR support and has no visible effects yet.
I'm not crazy about the name LazyProvide. Perhaps the interface method could
remain like that and the package method of the same name could become
LateBind(). I still don't understand why the credential provider has a
DockerConfigEntry that has the same fields but is distinct from
docker.AuthConfiguration. I had to write a converter now that we do that in
more than one place.

In step two, I'll add another intermediate, lazy provider for each AWS region,
whose empty LazyAuthConfiguration will have a refresh time of months or years.
Behind the scenes, it'll use an actual ecrProvider with the usual ~12 hour
credentials, that will get created (and later refreshed) only when kubelet is
attempting to pull an image. If we simply turned ecrProvider directly into a
lazy provider, we would bypass all the caching and get new credentials for
each image pulled.
2016-03-29 15:39:30 -04:00
Yifan Gu d4dc037bf7 rkt: Add '--hostname' support for rkt.
Add GeneratePodHostNameAndDomain() to RuntimeHelper to
get the hostname of the pod from kubelet.

Also update the logging flag to change the journal match from
_HOSTNAME to _MACHINE_ID.
2016-03-28 17:06:14 -07:00
Random-Liu d2524bf291 Start using docker engine-api 2016-03-28 15:39:11 -07:00
k8s-merge-robot e44ad7a083 Merge pull request #22735 from resouer/throttle-dev
Auto commit by PR queue bot
2016-03-26 06:44:48 -07:00
goltermann 32d569d6c7 Fixing all the "composite literal uses unkeyed fields" Vet errors. 2016-03-25 15:25:09 -07:00
Lucas Käldström c6172e58cf Make kubelet use an arch-specific pause image depending on GOARCH 2016-03-25 23:45:59 +02:00
harry 8472cfa214 Refactor throttle into util pkg
Fix missing throttle.go
2016-03-25 08:32:23 +08:00
goltermann 34d4eaea08 Fixing several (but not all) go vet errors. Most are around string formatting, or unreachable code. 2016-03-22 17:26:50 -07:00
Vishnu kannan 516559022c 1. Make kubelet default to 10ms for CPU quota if limit < 10m for
backwards compat.
2. Update documentation to reflect minimum CPU limits.

Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-03-17 13:30:06 -07:00
Thomas Graf 90623d9b51 DockerManager: Support IPv6 addresses
Falls back to the GlobalIPv6Address or ip -6 addr output in case no
IPv4 is configured for the container.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
2016-03-17 01:27:16 +01:00
tobad357 3d530f7f37 Fix for issue #22932 infinite pod restarts
This fixes an issue when using CNI where the hash of a Container object will differ between creation and change checks due to the docker image exporting ports
2016-03-16 22:43:39 +08:00
Brian Grant c6b4518aed Merge pull request #22666 from pmorie/pod-ip-flake-redux
Fix flake in pod IP as env var e2e
2016-03-11 09:42:40 -08:00
Paul Morie 5194c12d9e Fix flake in pod IP as env var e2e 2016-03-10 16:32:03 -05:00
k8s-merge-robot 8b186991e2 Merge pull request #22607 from Random-Liu/restart-unknown-state-container
Auto commit by PR queue bot
2016-03-08 05:02:35 -08:00
Yu-Ju Hong b1a6ee26ef Ignore "no such container" error when generating pod status
This allows the pod continue to sync if one container in a corrupt state.
2016-03-06 08:46:31 -08:00
k8s-merge-robot fa0bf812d6 Merge pull request #22467 from Random-Liu/push-down-runtime-version-check
Auto commit by PR queue bot
2016-03-05 22:34:19 -08:00
k8s-merge-robot f359bd96a7 Merge pull request #20578 from dcbw/dont-cni-hostnet-pods
Auto commit by PR queue bot
2016-03-05 09:03:12 -08:00
Lantao Liu 45064d7a1e Always restart container in unknown state. 2016-03-05 10:42:26 +00:00
k8s-merge-robot e9d3be83ae Merge pull request #22241 from Random-Liu/recover-back-off-behaviour
Auto commit by PR queue bot
2016-03-05 00:05:15 -08:00
Random-Liu 07b21c50fa Add Status in runtime interface and use it for runtime health check. 2016-03-04 21:26:41 -08:00
Abhishek Shah a3c00aadd5 Specify hostname, subdomain via annotation on podspec.
The hostname is a DNS A record, if the subdomain maps to a service name
in the same namespace
2016-03-04 13:28:33 -08:00
Dan Williams bc62096ad5 Clean up host networking plugin checks for docker manager
We can save a docker inspect in podInfraContainerChanged() because
it's only used within the useHostNetwork() block.  We can also
consolidate some code in createPodInfraContainer() because if
the pod uses the host network, no network plugin will be involved.

Finally, in syncPodWithSyncResult() we can consolidate some
conditionals because both hairpin setup and getting the container
IP are only relevant when host networking is *not* being used.

More specifically, putting the dm.determineContainerIP() call
into the !useHostNetwork() block is OK since if no network plugin
was called to set the container up, it makes no sense to call
the network plugin to retrieve the IP address that it did not
handle.  The CNI plugin even calls back into the docker manager
to GetContainerIP() which grabs the IP from docker, which will
always be "" for host networked containers anyway.
2016-03-04 09:27:14 -06:00
Jeff Lowdermilk 402e44d26e Merge pull request #22320 from timstclair/network
Use the default interface for reporting network stats.
2016-03-03 15:18:34 -08:00
Tim St. Clair 3ad59de829 Garbage collect containers for deleted pods 2016-03-02 14:35:17 -08:00
Random-Liu a88dad1c3e Backoff restart container with liveness probing failure 2016-03-01 17:36:12 -08:00
Tim St. Clair 3b9feb561c Use the default interface for reporting network stats. 2016-03-01 16:17:04 -08:00
Saad Ali f9b1a33b12 Merge pull request #21953 from timstclair/testing
Move kubelet test-only files to test-only packages
2016-03-01 15:48:10 -08:00
k8s-merge-robot 6dee237d85 Merge pull request #21790 from vishh/seccomp
Auto commit by PR queue bot
2016-03-01 12:21:47 -08:00
Tim St. Clair 7b6d843309 Move test-only files to test-only packages 2016-03-01 09:11:32 -08:00
Random-Liu 98283d894c dockertools: fix error exited container list in fake docker client 2016-02-28 13:19:57 -08:00
Fabio Yeon 9eed320088 Merge pull request #21740 from Random-Liu/fix-syncpod-unit-test
Fix error logic and leaking goroutine in docker unit test.
2016-02-26 15:51:35 -08:00
Fabio Yeon 7d0684e9c4 Merge pull request #21628 from smarterclayton/suppress_debug_logging
Reduce volume of logs generated at v(3)
2016-02-26 15:47:31 -08:00
Fabio Yeon a56a315d99 Revert "kubelet: fix duplicated status updates at pod cleanup" 2016-02-26 14:39:11 -08:00
Random-Liu 61f7a5d228 Fix bug in fake docker client 2016-02-24 21:23:41 -08:00
Vishnu kannan 5db37b0b2d Disable seccomp policy by default on docker versions >= v1.10
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-02-24 10:26:21 -08:00
Random-Liu 3338304c7b Fix error logic and leaking goroutine in docker unit test. 2016-02-23 01:29:05 -08:00
k8s-merge-robot 24d82b6c4a Merge pull request #21286 from smarterclayton/fix_keyring
Auto commit by PR queue bot
2016-02-21 21:44:27 -08:00
Clayton Coleman ae2f6a833a Reduce volume of logs generated at v(3)
Node controller is generating a huge amount of logging at v(3) that is
more appropriate for v(5). Split the log into two levels and ensure it
also ends up on one line (so grep works).

The pod manager generates a v(4) pod output on sync that always contains
a newline - since the size of the pod is so excessive in output, kick it
to v(5) for deep debugging (we're pretty happy with this loop).
2016-02-20 15:29:05 -05:00
Clayton Coleman 8c27314915 Unqualified host:port pairs are valid Docker auth fields
The dockercfg and .docker/config.json files can contain host:path
combos, which are not correctly parsed by the keyring.
2016-02-18 13:18:34 -05:00
laushinka 7ef585be22 Spelling fixes inspired by github.com/client9/misspell 2016-02-18 06:58:05 +07:00
k8s-merge-robot 180d34ed52 Merge pull request #21120 from Random-Liu/minor-probe-manager-refactor
Auto commit by PR queue bot
2016-02-15 19:41:45 -08:00
k8s-merge-robot 44d12a1389 Merge pull request #20782 from nickschuch/readonly_container_2
Auto commit by PR queue bot
2016-02-14 13:18:24 -08:00
k8s-merge-robot b6056f9a45 Merge pull request #21014 from Random-Liu/unit-test-for-pod-sync-result
Auto commit by PR queue bot
2016-02-14 09:53:59 -08:00
Nick Schuch 5d511aeb54 Adds ReadOnlyRootFilesystem support for containers 2016-02-14 15:39:51 +10:00
k8s-merge-robot 24b33964c9 Merge pull request #20954 from Random-Liu/add-missing-pod-sync-result
Auto commit by PR queue bot
2016-02-13 20:02:31 -08:00
Random-Liu ae759dc206 Add unit test for PodSyncResult 2016-02-12 14:15:25 -08:00
Lantao Liu 77b6f14f86 Change pod in probe update to pod uid. 2016-02-12 05:02:31 +00:00
k8s-merge-robot 55267640bc Merge pull request #20842 from Random-Liu/deprecate-hostconfig-at-container-start
Auto commit by PR queue bot
2016-02-10 20:00:08 -08:00
Lantao Liu c341cee65b Fix network configuration 2016-02-10 16:51:34 -08:00
Random-Liu b7292f6672 Add missing PodSyncResult in KillPod 2016-02-09 18:28:26 -08:00
Prashanth Balasubramanian c3a3a2bacd Pipe hairpin-mode flag through kubelet, enable on soak. 2016-02-09 12:12:19 -08:00
k8s-merge-robot fce98f3cf2 Merge pull request #20827 from smarterclayton/fix_manager
Auto commit by PR queue bot
2016-02-08 21:13:42 -08:00
Clayton Coleman 5aca495d73 Regression: Kubelet fails on older distro Dockers
Changes broke compatibility with released versions of Docker on some
distributions like Fedora and RHEL (value 1.8.1.fc21 is in the wild).
2016-02-08 19:00:01 -05:00
k8s-merge-robot 14653d6b5a Merge pull request #20169 from vishh/20117
Auto commit by PR queue bot
2016-02-08 15:25:45 -08:00
k8s-merge-robot 230f593058 Merge pull request #20383 from smarterclayton/allow_prefix_changes
Auto commit by PR queue bot
2016-02-08 12:04:46 -08:00
James DeFelice 1aec798aa0 support optional envvars for pod-infra-container 2016-02-08 13:48:25 +00:00
Daniel Smith 75e1451363 Merge pull request #20742 from kubernetes/revert-20615-deprecate-hostconfig-at-container-start
Revert "Deprecate HostConfig at container start"
2016-02-05 14:01:43 -08:00
Lantao Liu bb9457e7a3 Revert "Deprecate HostConfig at container start" 2016-02-05 12:50:35 -08:00
Random-Liu 45e3a1f596 Remove old reason cache 2016-02-05 19:19:46 +00:00
Random-Liu 2b7d0182ca Remove ConvertPodStatusToAPIPodStatus from runtime interface 2016-02-05 19:19:46 +00:00
k8s-merge-robot bd67b8a5db Merge pull request #20192 from Random-Liu/remove-get-api-podstatus
Auto commit by PR queue bot
2016-02-05 11:00:42 -08:00
k8s-merge-robot ae15a4437b Merge pull request #19944 from mwielgus/simple-cm
Auto commit by PR queue bot
2016-02-05 06:41:28 -08:00
k8s-merge-robot df0bbd45d7 Merge pull request #20615 from Random-Liu/deprecate-hostconfig-at-container-start
Auto commit by PR queue bot
2016-02-05 04:54:28 -08:00
Marcin Wielgus bf0c881263 Set Docker custom metric label for cAdvisor if custom metric volume is mounted 2016-02-05 12:00:02 +01:00
k8s-merge-robot 2084fba199 Merge pull request #18842 from vishh/kubelet_docker
Auto commit by PR queue bot
2016-02-04 17:08:34 -08:00
Lantao Liu 8118092d11 Deprecate HostConfig at container start 2016-02-04 15:35:14 -08:00
Phillip Wittrock ba5be34574 Kubelet Metrics Summary Api Implementation 2016-02-04 14:05:28 -08:00
Vishnu kannan df1f164b34 Do not fail container creation if the contaienr exits before applyting
oom score adjust.

Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-02-04 13:39:19 -08:00
Saad Ali 7d70edc91f Merge pull request #20553 from jonboulle/yifan-gu-rkt_dns
rkt: Add DNS support
2016-02-04 10:55:38 -08:00
Lantao Liu 4a386f881f Deprecate HostConfig at container start 2016-02-04 01:00:03 +00:00
Dan Williams fabb65c13f Add a network plugin that duplicates "configureCBR0" functionality 2016-02-03 10:08:08 -06:00
Yifan Gu e9139bb0e5 kubelet: Rename RunContainerOptionsGenerator to RuntimeHelper.
Also add GetClusterDNS() to the interface to let rkt get the
DNS servers, DNS names.
2016-02-03 14:54:08 +01:00
Jeff Lowdermilk caa9433234 Merge pull request #20433 from lavalamp/fix-bad-rv
Add timeout, fix potential startup hang
2016-02-02 17:27:23 -08:00
Random-Liu 7b4cdb6f8f Remove GetAPIPodStatus from runtime interface 2016-02-02 23:41:55 +00:00
k8s-merge-robot c0fd002fbb Merge pull request #20019 from thockin/dont-cni-hostnet-pods
Auto commit by PR queue bot
2016-02-02 01:43:24 -08:00
Daniel Smith 4a7d70aef1 extend fake clock 2016-02-01 15:36:15 -08:00
harry 1032067ff9 Replace runtime reference by pkg 2016-02-01 21:06:44 +08:00
Clayton Coleman e3f4e823ba Allow the Kubelet Docker container prefix to be changed
Enables running multiple Kubelets on the same instance for testing and
for node bootstrapping experimentation
2016-01-31 01:03:05 -05:00
k8s-merge-robot 9fef5f2938 Merge pull request #19785 from Random-Liu/remove-get-podstatus-and-apipodstatus
Auto commit by PR queue bot
2016-01-30 11:35:26 -08:00
Alex Robinson 5c53b3a13b Merge pull request #20335 from aveshagarwal/master-integration-tests-issue
Fix docker version errors in integration tests.
2016-01-30 10:40:06 -08:00
k8s-merge-robot 29c640d5ba Merge pull request #19579 from Random-Liu/add-new-reason-cache
Auto commit by PR queue bot
2016-01-30 02:06:49 -08:00
Random-Liu f116a5eb8f Remove temporary function GetPodStatusAndAPIPodStatus() 2016-01-30 00:39:26 -08:00
Random-Liu e93febfd61 Start returning PodSyncResult in SyncPod 2016-01-30 00:25:50 -08:00
k8s-merge-robot 2d061aa199 Merge pull request #19784 from Random-Liu/cleanup-kubelet-syncpod
Auto commit by PR queue bot
2016-01-30 00:25:49 -08:00
k8s-merge-robot deef16d2b3 Merge pull request #19354 from jimmidyson/system-container-fix
Auto commit by PR queue bot
2016-01-29 19:13:43 -08:00
Avesh Agarwal de804332f4 Fix docker version errors in integration tests. 2016-01-29 13:48:07 -05:00
Fabio Yeon eb2c2d1af4 Merge pull request #20111 from fabioy/fix-tmp-tests
Add temp directory creation method for tests.
2016-01-29 09:51:12 -08:00
Jimmi Dyson 1c289943f5 Ensure kubelet pid is not moved to system container 2016-01-29 09:30:20 +00:00
Fabio Yeon 547a2e2387 Merge pull request #20131 from thockin/logs-for-19574
Augment logs in runContainer path
2016-01-28 13:49:59 -08:00
Andy Goldstein 86ae623a09 Help debug port forward flakes 2016-01-28 15:28:40 -05:00
Fabio Yeon 7205a160ac Remove all instances of "/tmp" from unit tests and replace with a common
tmp directory creator. Exception is documented.
2016-01-27 16:11:22 -08:00
Tim Hockin df4c1ccd14 Don't apply net plugins to net=host pods 2016-01-27 15:43:33 -08:00
Eric Paris 8e1ca68760 Merge pull request #20020 from apcera/cleanup-docker-engine-check
kubelet: Update engine version parsing to handle semantic versioning
2016-01-26 11:44:02 -05:00
Tim Hockin 45e5912c3d Augment logs in runContainer path
Generating errors that are useful is hard.
2016-01-25 16:31:32 -08:00
Ken Robertson 66c99d5e9c kubelet: Update FakeDockerClient used in integration tests
This updates the mock for the docker client used in integration tests to
include the engine version in its VersionInfo response.
2016-01-22 17:14:01 -08:00
Ken Robertson fff8a7c371 kubelet: Update engine version parsing to handle semantic versioning
This updates the dockertools.dockerVersion to use a semantic versioning
library to more gracefully support engine versions which include
additional version fields.

Previously, go-dockerclient's APIVersion struct was use which only
handles plain numeric x.y.z version strings. With #19675, the library
was now used on the Docker engine string, however it is possible for the
engine string to include include additional information for beta, rc, or
distro specific builds.

This PR also enables the TestDockerRuntimeVersion test which was
previously just a FIXME and updates it to pass, and be used to test the
version string that cause #20005.

This negates the need for fsouza/go-dockerclient#451, since even with
that change, if a user was running Docker 1.10.0-rc1, this would cause
the kubelet to report it as simply 1.10.0.
2016-01-22 13:18:52 -08:00
Clayton Coleman 4a6935b31f Remaining codec change refactors 2016-01-22 13:27:27 -05:00
Clayton Coleman 33085c0cf2 Update tests to handle codec changes 2016-01-22 13:27:26 -05:00
nikhiljindal 2ad642d370 Merge registered and latest and move to apimachinery 2016-01-21 14:42:21 -08:00
Alex Mohr c52122cab5 Merge pull request #19675 from apcera/kubelet-report-runtime-version
Update container runtime to properly report the engine and version
2016-01-21 10:31:19 -08:00
k8s-merge-robot d0f59e2126 Merge pull request #18172 from Random-Liu/generate-sync-event
Auto commit by PR queue bot
2016-01-20 22:48:35 -08:00
Random-Liu eb56d46b74 Minor clean up in kubelet syncPod() 2016-01-20 17:31:59 -08:00
Ken Robertson a7b07c01df Update container runtime to properly report the engine and version
This address a TODO when collecting the node version information so it
will properly report the configured runtime and its version. Previously,
this was hardcoded to "docker://" and the docker version, and would show
"docker://1.9.1" even when the kubelet was configured to use rkt.

With this change, it will use the runtime's Type() and Version() data.

This also changes the container.Runtime interface to add an APIVersion()
method. This can be used when the runtime has separate versions for the
engine and the API, such as with Docker. The Docker minimum version
validation has been updated to use APIVersion(), and
DockerManager.Version() now returns the engine version.
2016-01-20 16:42:25 -08:00
Random-Liu 0e612afa98 Start using PodSyncResult in dockertools 2016-01-17 00:42:45 -08:00
Mike Danese 33c72db59c Merge pull request #19528 from resouer/strings-util
Create strings pkg to fix util issue
2016-01-14 21:19:17 -08:00
harry 7405c7899b Add strings pkg to hold strings utils
Replace funtions with strings pkg

Fix all references and rename the pkg
2016-01-15 12:37:50 +08:00
Mike Danese 41df8749a8 Merge pull request #19470 from gmarek/kubemark-performance
Shorten the sleep amount in the fake docker client
2016-01-14 11:55:24 -08:00
k8s-merge-robot c255181509 Merge pull request #18248 from resouer/images-dev
Auto commit by PR queue bot
2016-01-11 23:53:43 -08:00
Saad Ali 651206fd90 Merge pull request #19393 from yujuhong/fix_dockerclient
Fix fake docker client to corretly report status of containers
2016-01-11 13:56:41 -08:00
gmarek 573c3ca320 Shorten the sleep amount in the fake docker client 2016-01-11 12:15:11 +01:00
k8s-merge-robot 609cdfd267 Merge pull request #19331 from resouer/hash-util
Auto commit by PR queue bot
2016-01-09 13:08:01 -08:00
harry zhang 27ca7dc71e Expose image list in node status
Change image manager to use repotag
2016-01-08 17:01:31 +08:00
Yu-Ju Hong b969599daf Fix fake docker client to corretly report status of containers 2016-01-07 18:20:41 -08:00
Clayton Coleman 791d160b42 Split the Kubelet flag options and struct
Reduces the size of the app/server.go file and ensures that the flags
and their defaults are clearly separated.
2016-01-06 21:23:06 -05:00
harry 2a52976983 Use hashutil to hold hash tools 2016-01-06 22:28:58 +08:00
k8s-merge-robot 38f926dbb9 Merge pull request #19206 from Random-Liu/remove-wired-docker-label
Auto commit by PR queue bot
2016-01-05 19:32:01 -08:00
Random-Liu 884dc5c9e5 Put TerminationGracePeriod, DeletionGracePeriod and PreStopHandler to docker labels 2016-01-05 15:45:29 -08:00
Random-Liu 2ea11690b8 Remove running pod from SyncPod() of container runtime 2016-01-04 10:18:46 -08:00
Random-Liu b2a72ca384 Change my TODO to be the same with others 2015-12-31 00:41:05 -08:00
Random-Liu 6e92ddf9e1 Cleanup pod print in dockertools/manager.go, prober/prober.go and
runonce.go
2015-12-28 14:07:37 -08:00
Vishnu Kannan 3c0745211f Fix docker root dir detection. 2015-12-17 10:24:30 -08:00
deads2k d0aaf13920 use constants for group names 2015-12-14 10:04:10 -05:00
k8s-merge-robot 3d24d25fd8 Merge pull request #17764 from jiangyaoguo/make-containerspecchange-private
Auto commit by PR queue bot
2015-12-11 17:40:34 -08:00
Yu-Ju Hong c646255579 Replace podFullName with format.Pod() in logging messages 2015-12-07 13:41:52 -08:00
jiangyaoguo 5f77f2b5a9 make PodContainerSpecChange private 2015-12-07 09:28:15 +08:00
k8s-merge-robot 810181fb7b Merge pull request #17278 from ZJU-SEL/fix-nil-tag
Auto commit by PR queue bot
2015-12-06 12:52:39 -08:00
Random-Liu 3cbdf79f8c Change original PodStatus to APIPodStatus, and start using kubelet internal PodStatus in dockertools 2015-12-04 17:37:39 -08:00
Harry Zhang 5552d7007c Add default when latest not claimed 2015-11-30 17:10:50 +08:00
harry zhang 121c7046aa Move parsers into util 2015-11-29 22:15:11 -08:00
k8s-merge-robot 4eb010b1f7 Merge pull request #17694 from hongchaodeng/ratelimit
Auto commit by PR queue bot
2015-11-26 13:12:26 -08:00
Random-Liu c6d02b83e5 Cleanup container_gc_test.go 2015-11-25 10:37:39 -08:00
k8s-merge-robot ff3f240de2 Merge pull request #17533 from Random-Liu/fix-fake-docker-client
Auto commit by PR queue bot
2015-11-25 08:44:26 -08:00
Avesh Agarwal 3d5207fd73 This commit adds type information to events.
This addresses issue #15624.
2015-11-24 09:59:54 -05:00
Hongchao Deng 13d152a873 RateLimiter: change CanAccept() to TryAccept() 2015-11-23 16:42:53 -08:00
k8s-merge-robot 8a306a7527 Merge pull request #17234 from Random-Liu/move-more-info-to-docker-label
Auto commit by PR queue bot
2015-11-21 10:45:09 -08:00
Daniel Smith 874b4f85d9 Merge pull request #17259 from yujuhong/raw_pod_status
kubelet: add RawPodStatus and related functions
2015-11-20 14:23:19 -08:00
Lantao Liu 90ac508524 Cleanup fake_docker_client.go and manager_test.go 2015-11-19 19:03:35 -08:00
Lantao Liu f08097515f Move more things into docke label, and add label test 2015-11-18 23:17:16 -08:00
Yu-Ju Hong 760309f349 kubelet: add RawPodStatus and related functions
RawPodStatus will be the internal status of the pod that kubelet relies on for
syncing.
2015-11-17 17:04:05 -08:00
k8s-merge-robot 1334401888 Merge pull request #17202 from brendandburns/fix2
Auto commit by PR queue bot
2015-11-17 00:49:13 -08:00
k8s-merge-robot 0c9bc3215d Merge pull request #14469 from thockin/intstr
Auto commit by PR queue bot
2015-11-16 23:20:37 -08:00
k8s-merge-robot 138a78db1f Merge pull request #16580 from jiangyaoguo/check-image-exist-after-pulled
Auto commit by PR queue bot
2015-11-16 22:53:34 -08:00
Jeff Lowdermilk 70d89a3541 Merge pull request #13571 from yujuhong/lifecycle_v0
kubelet: add a generic pod lifecycle event generator
2015-11-16 14:59:40 -08:00
Tim Hockin ba383bcfeb Refactor IntOrString into a new pkg
pkg/util/intstr is a cleaner encapsulation for this type and supporting
functions.  No behavioral change.
2015-11-16 10:57:52 -08:00
k8s-merge-robot ebe5649939 Merge pull request #16824 from mattmoor/master
Auto commit by PR queue bot
2015-11-16 09:12:35 -08:00
zhengguoyong d5f2bb00a7 Del unused var 2015-11-16 15:53:20 +08:00
Matt Moore b750d1dddc Drop the beta for GCR v2 images.
beta.gcr.io is no longer needed to pull through v2.
2015-11-14 12:19:02 -08:00
Brendan Burns fb576f30c8 Refactor an interface for style 2015-11-13 15:56:27 -08:00
Yu-Ju Hong 3beae6b70b Add Status in the runtime Container type
This is necessary for the generic PLEG to distinguish container events.
2015-11-13 09:55:36 -08:00
k8s-merge-robot 0bb894173c Merge pull request #17187 from Random-Liu/deprecate-container-without-termination-message-path
Auto commit by PR queue bot
2015-11-13 04:49:17 -08:00
k8s-merge-robot 0d9f2dc5fd Merge pull request #17081 from yujuhong/docker_tests
Auto commit by PR queue bot
2015-11-12 22:56:29 -08:00
Lantao Liu 1018d32d4f Deprecate old containers without TerminationMessagePath label 2015-11-12 15:30:14 -08:00
k8s-merge-robot 8761ad3ec1 Merge pull request #15464 from jiangyaoguo/bubble-up-reason-when-killing-pod
Auto commit by PR queue bot
2015-11-11 14:17:27 -08:00
Yu-Ju Hong 543391f1dc Clean up unit tests using FakeDockerClient
Add a helper method to set the container map and list at the same time, without
having to specify them separately. This reduces the effort required for
adding/modifying tests as well as making the code more concise.
2015-11-10 16:51:35 -08:00
k8s-merge-robot 7b3f37a892 Merge pull request #17003 from jiangyaoguo/fix-error-sync-pod-message
Auto commit by PR queue bot
2015-11-10 04:01:28 -08:00
jiangyaoguo b0f0c294d9 make reasons constants with clarity 2015-11-09 23:42:14 +08:00
jiangyaoguo 55bf786216 adjust container event message 2015-11-09 23:42:13 +08:00
jiangyaoguo 02f8e4277f bubble up reason when killing pod 2015-11-09 23:42:13 +08:00
k8s-merge-robot 5fe3733f95 Merge pull request #16272 from jiangyaoguo/remove-infra-container-event
Auto commit by PR queue bot
2015-11-09 06:05:35 -08:00
jiangyaoguo 85d554bfc4 fix FailSync event message 2015-11-09 15:49:52 +08:00
jiangyaoguo 3b512add9c check image present after pulled image with no error 2015-11-06 10:58:55 +08:00
jiangyaoguo 39858db29e add new event when infra-container change 2015-11-04 17:04:32 +08:00
jiangyaoguo 3ce5a51007 remove implicitly required container event 2015-11-04 16:47:17 +08:00
Yu-Ju Hong 2eb17df46b kubelet: independent pod syncs and backoff on error
Currently kubelet syncs all pods every 10s. This is not preferred because
 * Some pods may have been sync'd recently.
 * This may cause all the pods to be sync'd at once, causing undesirable
   CPU spikes.

This PR replaces the global syncs with independent, periodic pod syncs. At the
end of syncing, each pod worker will enqueue itslef with a future timestamp (
current time + sync interval), when it will be due for another sync.
 * If the pod worker encoutners an sync error, it may requeue with a different
   timestamp to retry sooner.
 * If a sync is triggered by the update channel (events or spec changes), the
   pod worker would enqueue a new sync time.

This change is necessary for moving to long or no periodic sync period once pod
lifecycle event generator is completed. We will still rely on the mechanism to
requeue the pod on sync error.

This change also makes sure that if a sync does not succeed (either due to
real error or the per-container backoff mechanism), an error would be propagated
back to the pod worker, which is responsible for requeuing.
2015-11-03 13:29:08 -08:00
k8s-merge-robot fe2d44e842 Merge pull request #16653 from Random-Liu/remove-unused-type
Auto commit by PR queue bot
2015-11-03 02:45:22 -08:00
Lantao Liu 894dc5a5a2 Move TerminationMessagePath into docker label. 2015-11-02 14:32:58 -08:00
Lantao Liu eff4533efc Move findPodContainer to docker_test.go 2015-11-02 09:49:07 -08:00
Lantao Liu b127901871 Remove unused type DockerContainers.
Type DockerContainers and function FindPodContainer() are never used.
Remove them to simplify the docker runtime api.
2015-11-01 18:49:05 -08:00
Alex Robinson 0eb7243b95 Merge pull request #15994 from dchen1107/docker
Failed docker health check and mark the node NotReady when docker version is below 1.6.2 (API ve…
2015-10-30 15:39:04 -07:00
Dawn Chen a39e1e96dc Mark NodeNotReady for docker version below 1.6.2 2015-10-30 13:48:51 -07:00
k8s-merge-robot eb140495ab Merge pull request #16414 from Random-Liu/put-podname-into-label
Auto commit by PR queue bot
2015-10-30 12:45:25 -07:00
Lantao Liu b3585a5209 Move docker label related functions into labels.go and add pod name, pod namespace and pod uid into docker label 2015-10-29 22:42:25 -07:00
Clayton Coleman 2335bfa351 Allow Docker container logs to be tail'd and follow'd
Relaxes the very very ancient restriction we put in place to keep the
original API surface area PR small. Better to be consistent with actual
expected use of tail.
2015-10-29 17:12:38 -04:00
Sami Wagiaalla 1d352a16b8 Support volume relabling for pods which specify an SELinux label 2015-10-28 09:26:58 -04:00
k8s-merge-robot df265b2d6e Merge pull request #15510 from aveshagarwal/master-selflink-objref
Auto commit by PR queue bot
2015-10-27 00:37:21 -07:00
Daniel Smith 3cc2ae4da6 Merge pull request #15831 from zhengguoyong/modify_pod_networkplugin_setup_errmsg
Modify duplicate err msg
2015-10-26 17:07:18 -07:00
k8s-merge-robot 5280540384 Merge pull request #15965 from Random-Liu/use-docker-label
Auto commit by PR queue bot
2015-10-24 13:19:40 -07:00
Lantao Liu 67a7633202 Put restart count into docker label 2015-10-23 13:02:32 -07:00
Filip Grzadkowski 165169ab1c Merge pull request #16052 from ArtfulCoder/mount_etc_hosts
kubelet manages /etc/hosts file
2015-10-23 14:07:34 +02:00
Filip Grzadkowski edd10d8a83 Merge pull request #15914 from vishh/serialize-pull
make kubelet image pulls serialized by default.
2015-10-23 14:04:23 +02:00
Vishnu kannan 0df4b46d4c Adding a kubelet flag to optionally enable parallel image pulls. 2015-10-22 17:19:51 -07:00
Abhishek Shah ba6469d478 kubelet manages /etc/hosts file 2015-10-22 13:27:05 -07:00
Paul Morie 393e2bc019 Inline some SecurityContext fields into PodSecurityContext 2015-10-21 19:01:17 -04:00
Vishnu kannan 94b45830c3 make kubelet image pulls serialized by default. 2015-10-20 14:50:44 -07:00