Wojciech Tyczynski
a973f57d6b
Thread per pod
2015-02-27 13:27:29 +01:00
Sami Wagiaalla
9150cb9d95
Catch kubelet-master hostname mismatch during health check
...
During the kubelet's /healthz responce check to see if the
hostname used by the master matches the hostname the kubelet
knows itself by. If not fail the health check.
Signed-off-by: Sami Wagiaalla <swagiaal@redhat.com>
2015-02-26 10:22:03 -05:00
Vish Kannan
e3af23e6e9
Merge pull request #4792 from vmarmol/mon-containers-per-pod
...
Add Kubelet metrics for pod and container counts.
2015-02-25 18:51:22 -08:00
Victor Marmol
95464349d5
Add Kubelet metrics for pod and container counts.
...
Part of #4604 .
2015-02-25 12:18:59 -08:00
Daniel Smith
ec8ecf3993
Merge pull request #4494 from brendandburns/race
...
Add protection for the pods member varaible.
2015-02-25 10:41:32 -08:00
Brendan Burns
801ad909ca
Add protection for the pods member varaible.
...
Address comments.
2015-02-24 19:36:11 -08:00
Vish Kannan
0b15f2ff65
Merge pull request #4784 from vmarmol/pod-restart
...
Kill infra pod when a container is restarted.
2015-02-24 13:37:08 -08:00
Vish Kannan
c561c8b0b1
Merge pull request #4753 from vmarmol/mon
...
First Kubelet metric and overall plumbing.
2015-02-24 12:51:34 -08:00
Victor Marmol
aadbf221d2
Kill infra pod when a container is restarted.
...
Revert 0e20f7d736
.
Fixes #4759 .
2015-02-24 11:52:05 -08:00
Rohit Jnagal
e77322a561
Merge pull request #4755 from yifan-gu/cleanup
...
pkg/kubelet: Fix logging.
2015-02-24 10:12:02 -08:00
Rohit Jnagal
590a62ffe5
Merge pull request #4767 from mikedanese/kind-to-type
...
Rename {Node,Pod}ConditionKind -> {Node,Pod}ConditionType
2015-02-24 10:10:57 -08:00
Yifan Gu
1a5a842ac5
pkg/kubelet: Fix logging.
2015-02-24 09:47:10 -08:00
Wojciech Tyczynski
dcef5e2955
Introduce DockerCache in Kubelet.
2015-02-24 09:10:07 +01:00
Mike Danese
5267127af1
api: rename conditionkind -> conditiontype
2015-02-23 22:13:21 -08:00
Victor Marmol
c40a60e945
Adding image pull latency metric.
...
Also adding TODOs for other metrics.
Part of #4604 .
2015-02-23 16:30:29 -08:00
Rohit Jnagal
50700419ea
Merge pull request #4732 from yifan-gu/cleanup
...
Remove outdated const.
2015-02-23 16:06:32 -08:00
Victor Marmol
f5beb04c53
Adding Prometheus /metrics handler.
2015-02-23 15:42:04 -08:00
Victor Marmol
d880be0301
Merge pull request #4738 from vmarmol/fix-pull
...
Remove pullLock from Kubelet.
2015-02-23 14:34:10 -08:00
Rohit Jnagal
b261d8c60a
Merge pull request #4724 from mikedanese/readiness-states-cleanup
...
Don't lock readinessStates on concurrent reads
2015-02-23 14:29:11 -08:00
Rohit Jnagal
cbcd35539f
Merge pull request #4718 from cjcullen/pdtest
...
Fix PD detach (fix the mount path/device name calculation).
2015-02-23 14:28:02 -08:00
Daniel Smith
650f6cb826
Revert "Multi-port Endpoints"
2015-02-23 13:53:21 -08:00
Tim Hockin
eed36455a7
Merge pull request #4653 from thockin/secret_fixups
...
Secrets fixups
2015-02-23 13:49:19 -08:00
Victor Marmol
a6d975c929
Remove pullLock from Kubelet.
...
The lock was only ever used to grab a read lock before container pulls.
2015-02-23 13:27:55 -08:00
Tim Hockin
607b736a3f
Rename volume source types to be consistent.
2015-02-23 12:39:57 -08:00
CJ Cullen
54e8240916
Fix PD detach (fix the mount path/device name calculation).
...
Fix readonly PD attach (don't try to format).
Add an e2e test to verify that PDs are attached and detached correctly.
Add an e2e test to verify that readonly PDs can be attached to >1 pods.
2015-02-23 12:19:22 -08:00
Yifan Gu
a631252abf
Remove outdated const.
2015-02-23 11:00:38 -08:00
Mike Danese
d6fb8ce05a
Don't lock readinessStates on concurrent reads.
2015-02-23 10:49:39 -08:00
Tim Hockin
e0fd83096c
Rename type Port to ContainerPort
...
Sadly I had to do this by hand - I just could not get gorename to fix up
users of it.
2015-02-21 22:26:38 -08:00
Victor Marmol
ccdbad89ce
Merge pull request #4677 from vmarmol/ooms
...
Check Docker init PID is valid before we use it.
2015-02-20 13:53:01 -08:00
Andy Goldstein
bd2eb2fa8f
Fix flaky exec/portforward tests
...
Fixes #4676
2015-02-20 16:29:57 -05:00
Victor Marmol
da2f4b6d61
Check Docker init PID is valid before we use it.
...
This gives us an error if the PID is not returned as we expect.
2015-02-20 13:10:40 -08:00
Tim Hockin
7fe7f8a542
move pkg/kubelet/server to cmd/kubelet/app
2015-02-20 08:49:12 -08:00
Tim Hockin
646621e0e8
Merge pull request #3763 from ncdc/remote-exec-port-forward
...
Add streaming remote command execution and port forwarding
2015-02-20 08:40:33 -08:00
Victor Marmol
d22fefd72d
Merge pull request #4650 from xiang90/cadvisor
...
pkg/kubelet: minor fixes for cadvisor.go
2015-02-20 08:35:27 -08:00
Andy Goldstein
5bd0e9ab05
Add streaming command execution & port forwarding
...
Add streaming command execution & port forwarding via HTTP connection
upgrades (currently using SPDY).
2015-02-20 09:57:02 -05:00
rsokolowski
e81ef667c2
Fix broken kubelet_test.go.
2015-02-20 11:20:12 +01:00
Dawn Chen
efac150039
Merge pull request #4563 from xiang90/syncpod
...
pkg/kubelet: recreate infra pod if the pod is changed
2015-02-20 00:29:26 -08:00
Dawn Chen
530c1559e1
Merge pull request #4647 from vmarmol/ooms
...
Make POD container last OOM victim
2015-02-20 00:25:52 -08:00
Xiang Li
5dc20421dc
pkg/kubelet: drop the unnecessary method receiver
2015-02-19 21:40:17 -08:00
Xiang Li
c6d8bd8f5e
pkg/kubelet: return error when there is no cadvisor connection
2015-02-19 21:35:57 -08:00
Xiang Li
ce1ced4322
pkg/kubelet: make comments follow go-style
2015-02-19 21:34:52 -08:00
Xiang Li
6433e2dd2b
pkg/kubelet: uncaptialize the error message in cadvisor.go
2015-02-19 21:30:24 -08:00
Victor Marmol
8649628c6c
Make POD container last OOM victim.
...
Setting the oom_score_adj of the PID of the POD container to -100 which is less
than the default of 0. This ensures that this PID is the last OOM victim
chosen by the kernel.
Fixes #3067 .
2015-02-19 19:24:01 -08:00
Victor Marmol
2d1a8d0da0
Allow ApplyOomScoreAdj to specify what PID to adjust for.
2015-02-19 17:16:31 -08:00
Daniel Smith
b7b537efc7
fix confusing defer
2015-02-19 17:11:32 -08:00
Victor Marmol
40cb417901
Merge pull request #4531 from wojtek-t/batch_requests_in_kubelet
...
Batch updates of multiple Pods.
2015-02-19 10:50:26 -08:00
Jerzy Szczepkowski
d614fc7fcc
Fire event for pod when mount fails.
...
Implemented firing event for pod when mount of external volume fails. Fixes #4540 .
2015-02-19 11:08:36 +01:00
Wojciech Tyczynski
702ad7732f
Applied comments
2015-02-19 08:01:16 +01:00
Eric Tune
af67829eca
Merge pull request #4515 from pmorie/secrets_wip
...
Secret volume plugin iteration 1
2015-02-18 15:57:31 -08:00
Xiang Li
0e20f7d736
pkg/kubelet: recreate infra pod if the pod is changed
2015-02-18 15:05:16 -08:00
Dawn Chen
8022c74b55
Merge pull request #4473 from xiang90/server
...
pkg/kubelet/server.go: minor fixes
2015-02-18 14:50:51 -08:00
Paul Morie
a42ff94c8f
Add secret volume plugin and e2e test
2015-02-18 16:27:44 -05:00
Xiang Li
6b91901bd3
pkg/kubelet: minor fixes in server.go
2015-02-18 13:18:45 -08:00
Prashanth Balasubramanian
9427f75788
Cadvisor returns richer errors to the kubelet server.
2015-02-18 09:31:28 -08:00
Wojciech Tyczynski
25c8f07c67
Batch updates of multiple Pods.
2015-02-18 16:46:16 +01:00
Dawn Chen
c843adbd8f
Create docker.Container obj with Name. Integration test is using fake_docker_client
...
to create and start a fake container. When StartContainer, it pass a name as docker
ID for testing purpose, but leave Name uninitialized. This PR fixes such issue.
Fixed #4472 .
2015-02-17 15:23:21 -08:00
Dawn Chen
bafa240187
Add debugging information for #4472
2015-02-17 13:28:15 -08:00
Clayton Coleman
4859aa7cd8
Merge pull request #4453 from derekwaynecarr/make_quota_more_efficient
...
Make ListWatch work with a ListFunc and WatchFunc
2015-02-17 14:48:11 -05:00
Nikhil Jindal
81d0a88f1e
Merge pull request #4459 from xiang90/kubulete
...
kubelet: minor cleaning up
2015-02-17 10:18:47 -08:00
Xiang Li
042dc1faa3
pkg/kubelet: uncaptialize error message
2015-02-16 09:33:20 -08:00
Xiang Li
2437e94248
pkg/kubelet: fix wrong code path in runContainer
2015-02-16 09:32:37 -08:00
Xiang Li
13bb378d1c
pkg/kubelet: reduce indentation
2015-02-16 08:46:41 -08:00
Xiang Li
edc926ffcb
pkg/kubelet: capitalize message in print
2015-02-16 08:40:07 -08:00
Xiang Li
da6d1da12d
pkg/kubelet: remove unused var in handlers.go
2015-02-16 08:38:10 -08:00
Mike Danese
4ba8ecd1fb
move api.Probe timeout default to central defaults
2015-02-15 23:44:55 -08:00
Xiang Li
3c2ead5b29
pkg/kubelet: minor cleanup for probe.go
2015-02-15 22:25:14 -08:00
derekwaynecarr
c0ce15c588
Make list watch take a ListFunc and WatchFunc, provide default funcs from client
2015-02-15 22:26:05 -05:00
Dawn Chen
20dc1c2481
Merge pull request #4410 from brendandburns/fixer
...
Don't delete the pod infrastructure container on health check failures.
2015-02-13 15:18:27 -08:00
Victor Marmol
5d6ad845cc
Use Docker name (not ID) to parse Kubernetes components.
...
Since the parsing function doesn't return an error all the components
returned empty strings. This caused us to enforce the MaxContainerLimit
as a global limit instead of a per-container limit.
Fixes #4413 .
2015-02-13 13:08:15 -08:00
Brendan Burns
4ad3ea438d
Revert "Revert "Add an event for health check failures.""
...
This reverts commit fc4e711a8c
.
2015-02-13 09:23:13 -08:00
Clayton Coleman
09f18031fe
Merge pull request #4285 from brendandburns/auth
...
Add a more detailed error message for potential auth fails in docker pull.
2015-02-13 12:08:48 -05:00
Saad Ali
fc4e711a8c
Revert "Add an event for health check failures."
2015-02-13 08:10:45 -08:00
Saad Ali
c112f8f1bb
Merge pull request #4408 from brendandburns/printing
...
Add an event for health check failures.
2015-02-13 07:59:26 -08:00
Brendan Burns
5e49a606e1
Address changes.
2015-02-12 21:39:42 -08:00
Brendan Burns
8b7dfc9359
Return logs for failed and succeeded pods too.
2015-02-12 21:36:25 -08:00
Brendan Burns
4dbf98e98f
Don't delete the pod infrastructure container on health check failures.
2015-02-12 21:28:32 -08:00
Brendan Burns
c03a435501
Add an event for health check failures.
2015-02-12 19:08:23 -08:00
Brendan Burns
0532c46217
Add a more detailed error message for potential auth fails in docker pull.
2015-02-12 17:00:59 -08:00
Eric Tune
dd8f335380
Merge pull request #4376 from dchen1107/podstatus
...
Fix podstatus issue caused by docker's resource temporarily unavailable issue
2015-02-12 13:16:09 -08:00
Dawn Chen
af54c62766
Fix podstatus issue caused by docker's resource temporarily unavailable error
2015-02-11 23:52:58 -08:00
Vishnu Kannan
922881fcd2
Improve error handling for '/containerLogs' API in kubelet.
2015-02-12 02:22:26 +00:00
Eric Tune
9ea4d2f814
Merge pull request #4323 from dchen1107/podstatus
...
Check if kubelet does know such Pod before querying status.
2015-02-11 11:13:50 -08:00
Dawn Chen
f5f2b6f773
Check if kubelet does know such Pod before querying status.
2015-02-11 10:16:04 -08:00
Dawn Chen
c55921676c
Merge pull request #4271 from ArtfulCoder/logging_etcd
...
Updated etcd-pod-dir-fetch logging.
2015-02-10 13:41:06 -08:00
Abhishek Shah
febf8c9b2c
Fixed formattting issues in etcd.go
2015-02-10 12:03:40 -08:00
Mike Danese
c72c2a0d1e
added tests
2015-02-10 08:30:13 -08:00
Mike Danese
3d0cd81feb
refactor pkg/probe ProbeRunners to interfaces and move global probers into kubelet field for testability
2015-02-10 08:30:11 -08:00
Mike Danese
043794492e
implement readiness.
2015-02-10 08:30:09 -08:00
Abhishek Shah
f136886dde
Updated logging. If etcd-pod-dir-fetch fails because dir was absent, an info message is logged. 2) For all other reasons, the regular error message is logged.
2015-02-09 18:03:58 -08:00
Brendan Burns
cc7279f6a8
Actually use the safeFormatAndMounter...
2015-02-06 17:01:05 -08:00
Zach Loafman
b77abb5945
Merge pull request #4221 from brendandburns/pd_fix
...
Make gce_safe_format_and_mount actually work correctly.
2015-02-06 14:50:20 -08:00
Brendan Burns
3d6c9fc9e8
Fix gce_pd to only use safe_format_and_mount when mounting block devices.
2015-02-06 12:41:21 -08:00
Brendan Burns
35fa143b29
Revert "Revert "Start using GCE safe format and mount for mounting disks.""
...
This reverts commit 858a85e8fe
.
2015-02-06 10:09:00 -08:00
Brendan Burns
94d852e8a6
Merge pull request #4214 from brendandburns/pd_fix
...
Revert "Start using GCE safe format and mount for mounting disks."
2015-02-06 09:58:51 -08:00
Brendan Burns
858a85e8fe
Revert "Start using GCE safe format and mount for mounting disks."
...
This reverts commit 3f109d6d46
.
2015-02-06 09:58:03 -08:00
Dawn Chen
05de54249f
Merge pull request #4191 from simon3z/master
...
api: add image's id to ContainerStatus
2015-02-06 09:35:44 -08:00
Federico Simoncelli
e01df69565
api: add image's id to ContainerStatus
...
Sometimes for external applications it is important to identify
exactly what images are running. Since tags can be moved to point
to newer builds this information can be used to identify old images
running.
Signed-off-by: Federico Simoncelli <fsimonce@redhat.com>
2015-02-06 09:01:14 -05:00
Brian Grant
175e9caa55
Merge pull request #4194 from dchen1107/podstatus
...
Kubelet decides podStatus
2015-02-05 17:18:39 -08:00
Brendan Burns
3f109d6d46
Start using GCE safe format and mount for mounting disks.
...
This removes the need for disks to be formatted.
2015-02-05 17:01:37 -08:00
Mike Danese
14bfec92f2
rename probe.Status to probe.Result.
2015-02-05 15:49:58 -08:00
Dawn Chen
f762e062f2
Kubelet decides podStatus
2015-02-05 15:49:41 -08:00
Brendan Burns
8e6f5c7201
Merge pull request #3593 from commonlisp/master
...
Add timeouts to HealthChecks and retry checks
2015-02-05 15:40:22 -08:00
Brendan Burns
8b25b43039
Merge pull request #4117 from wojtek-t/validate_docker_version
...
Check Docker version in Kubelet /healthz handler
2015-02-05 10:06:33 -08:00
George Kuan
e8c33b7916
Add timeouts to HealthChecks and retry checks
...
Fixes issue #3532 . Added timeouts for HTTP and TCP checks
and enabled kubelet/probe to kubelet#maxRetries times
before declaring Failure.
Added Probe.TimeoutSecs to API
Probe variants now check container.LivenessProbe.TimeoutSeconds
Also added a test for timeouts in http_test.go.
2015-02-05 06:04:45 -08:00
Wojciech Tyczynski
1a3419f970
Fix the min allowed Docker version.
2015-02-05 02:34:04 +01:00
Brendan Burns
cfe5b14114
Wait until containers actually finish running before trying to clean up
...
volumes or pods.
2015-02-04 17:28:41 -08:00
Wojciech Tyczynski
524cdba101
Fix hack/test-cmd.sh test.
2015-02-05 01:58:26 +01:00
Brendan Burns
6e897524be
Merge pull request #4093 from nelcy/master
...
Fix orphaned pod & volume cleanup order. Volumes need to be unmounted before pod cleanup.
2015-02-04 14:38:20 -08:00
Wojciech Tyczynski
ead67108ce
Use existing method to get Docker version.
2015-02-04 20:50:21 +01:00
Wojciech Tyczynski
78f66a6ce9
Check Docker version in Kubelet /healthz handler
2015-02-04 18:31:24 +01:00
chakri
9508b2bf12
Fix orphaned pod & volume cleanup order. Volumes need to be unmounted before pod cleanup.
2015-02-04 01:46:28 +00:00
Yu-Ju Hong
4a72addaeb
Factor out API defaulting from validation logic
...
Currently, the validation logic validates fields in an object and supply default
values wherever applies. This change factors out defaulting to a set of
defaulting callback functions for decoding (see #1502 for more discussion).
* This change is based on pull request 2587.
* Most defaulting has been migrated to defaults.go where the defaulting
functions are added.
* validation_test.go and converter_test.go have been adapted to not testing the
default values.
* Fixed all tests with that create invalid objects with the absence of
defaulting logic.
2015-02-03 00:55:42 -08:00
Brian Grant
2903fce2b8
Merge pull request #4031 from jbeda/hyperkube-kubelet
...
Convert kubelet and proxy to hyperkube
2015-02-02 18:08:59 -08:00
Tim Hockin
1ee1702be0
Merge pull request #3808 from brendandburns/master
...
Add a mounter that uses google's safe_format_and_mount.
2015-02-02 16:29:10 -08:00
Brendan Burns
ac21ac24fa
Add a mounter that uses google's safe_format_and_mount.
2015-02-02 16:16:20 -08:00
Tim Hockin
ac399fb354
Merge pull request #3967 from brendandburns/fixer
...
Be a little more careful when removing mount points.
2015-02-02 15:46:18 -08:00
Joe Beda
76df5471b5
Covert the kubelet binary to hyperkube.
...
This leaves `pkg/kubelet/server/server.go` looking a little ugly as there is an extra layer of "config" structs that isn't needed. This is left as a TODO for now.
2015-02-02 14:03:13 -08:00
Joe Beda
d96afdd645
Move 'pkg/standalone' package to 'pkg/kubelet/server'.
...
This paves the way to hyperkube for the kubelet.
2015-02-02 14:03:13 -08:00
Brendan Burns
7f06fbb081
Be a little more careful when removing mount points.
2015-02-02 12:35:24 -08:00
Vishnu Kannan
5e36f63f8b
Adding ResourceRequirementSpec to v1beta1, v1beta2, and v1beta3 APIs. The old resource
...
quantities 'CPU' and 'Memory' will be preserved until support for v1beta1 and v1beta2 APIs are
dropped.
Improved resource validation in the process.
2015-02-01 02:19:55 +00:00
Clayton Coleman
556e59b512
Merge pull request #3810 from ironcladlou/cache-namespacing
...
Support namespacing in cache.Store
2015-01-30 13:19:41 -05:00
Brian Grant
207d0f5d40
Merge pull request #3878 from thockin/infra_name
...
Use a constant for the pod infra container name
2015-01-30 09:18:00 -08:00
Ye Yin
248624fc1f
Add docker's add/drop capabilites
2015-01-30 15:09:31 +08:00
Brendan Burns
a0b8429d2e
Reverse the order of unmounting and removing the pd disk.
...
This should mean that we retry detaching if the original detach fails for some reason.
2015-01-29 16:13:12 -08:00
Dan Mace
5ee943d683
Support namespacing in cache.Store implementations
...
Support namespacing in cache.Store by framing the interface functions
around interface{} and providing a key function to each Store implementation.
Implementation of a fix for #2294 .
2015-01-29 17:39:49 -05:00
Mrunal Patel
19e0605f5b
Replace "net" by "pod infra" in docs and format strings.
2015-01-28 15:03:06 -08:00
Tim Hockin
804643a04b
Merge pull request #3818 from mikedanese/probe-refactor
...
break api.Probe out of api.LivenessProbe
2015-01-28 12:41:35 -08:00
Dawn Chen
b0bcee7b40
Increase timeout for all testcases in file_test.go
2015-01-28 11:27:15 -08:00
Mike Danese
78f33e950a
rename api.LivenessProbe to api.Probe and break out Actions
2015-01-28 11:20:44 -08:00
Tim Hockin
c8f61885df
Merge pull request #3695 from mikedanese/ready
...
refactor pkg/health into more reusable pkg/probe
2015-01-28 11:00:32 -08:00
Tim Hockin
70ab406751
Use a constant for the pod infra container name
...
This is an implementation detail that has leaked out of kubelet. Use a
constant to prevent divergence, for now. Plan to get rid of it.
@dchen1107
2015-01-28 10:13:02 -08:00
Paul Morie
962bdda0dc
Fix typo in kubelet
2015-01-28 12:00:53 -05:00
Tim Hockin
371637a5fc
Merge pull request #3845 from brendandburns/disk
...
Detach the PD disk from the VM in some failure cases.
2015-01-27 15:46:36 -08:00
Tim Hockin
7e6f3af937
Merge pull request #3817 from mrunalp/feature/shared_ipc
...
Shared IPC namespace for containers in a pod
2015-01-27 15:41:34 -08:00
Brendan Burns
bc055d2bd0
Detach the PD disk from the VM in some failure cases.
2015-01-27 13:58:42 -08:00
Mike Danese
5dc6362f8a
rename probe.Healthy to probe.Success and renam probe.Unhealthy to probe.Failure.
2015-01-27 11:20:30 -08:00
Mike Danese
6eb0b89cbd
add Probers to Probe pkgs.
2015-01-27 11:20:30 -08:00
Mike Danese
a298402bd4
remove pkg/health and move everything over to pkg/probe
2015-01-27 11:20:30 -08:00
Mike Danese
5ee4071cf1
migrated tests
2015-01-27 11:20:29 -08:00
Mike Danese
ee56a1d3e3
create pkg/probe as successor to pkg/health.
2015-01-27 11:20:29 -08:00
Brendan Burns
7e558a7535
Merge pull request #3813 from mattmoor/master
...
Fix for issue 3797.
2015-01-27 09:56:49 -08:00
Mrunal Patel
b6a0ff1003
IP: Shared IPC.
2015-01-27 09:26:36 -08:00
Brendan Burns
e5c38a825b
Fix unit tests @ main.
2015-01-26 22:12:24 -08:00
Matt Moore
2d396797a9
Fix for issue 3797.
...
Docker's logic for resolving credentials from .dockercfg accepts two kinds of matches:
1. an exact match between the dockercfg entry and the image prefix
2. a hostname match between the dockercfg entry and the image prefix
This change implements the latter, which permits the docker client to take .dockercfg entries of the form:
https://quay.io/v1/
and use them for images of the form:
quay.io/foo/bar
even though they are not a prefix-match.
2015-01-26 14:06:12 -08:00
Tim Hockin
d63162b7e7
Make kubelet's HTTP source go through conversion
2015-01-22 14:09:37 -08:00
Tim Hockin
4ff2865cd1
Make kubelet's file source go through conversion
...
See comments for details. Same problem exists in HTTP source, but I want to
float this for review first.
2015-01-22 13:10:59 -08:00
Tim Hockin
ffb2b62726
Merge pull request #3725 from dchen1107/cleanup
...
Generate pod.Name when pod.Name == "" for both HTTP and file sources.
2015-01-22 13:10:27 -08:00
Dawn Chen
ec77507915
Generate pod.Name when pod.Name == "" for both HTTP and file sources.
...
Fix #3584
2015-01-22 12:53:30 -08:00
Tim Hockin
30219f8dfa
Merge pull request #3664 from thockin/pull-if
...
Pull if
2015-01-21 13:05:28 -08:00
Tim Hockin
81343aac63
Change PullPolicy constants to match
2015-01-21 12:48:56 -08:00
Tim Hockin
819803b79f
Make VolumeSource not be a pointer
...
There's no reason for it to be a pointer.
2015-01-20 17:54:04 -08:00
Brian Grant
dd45246150
Merge pull request #3587 from dchen1107/image
...
Clean up Kubernetes PullPolicy
2015-01-20 17:18:26 -08:00
Tim Hockin
60ec08db93
Rename HostDir to HostPath in v1beta3
2015-01-20 15:56:44 -08:00
Brendan Burns
9192a4ce22
Merge pull request #3642 from dchen1107/clean
...
Remove image GC.
2015-01-20 14:07:00 -08:00
Dawn Chen
d1af520bd0
Merge pull request #3589 from filbranden/fix_nil_interface_pointer_without_reflect1
...
Fix comparison of EtcdClient to nil so that it does not run into the pointer vs. interface issue
2015-01-20 13:55:25 -08:00
Dawn Chen
2299c04cea
Remove image GC.
...
Fix #3617,#3611, and #3393 .
2015-01-20 13:43:08 -08:00
Dawn Chen
3101a33d32
Kubelet stop using api/helper.go for PullPolicy
2015-01-20 11:54:22 -08:00
Dawn Chen
aec4594a8d
Introduce validatePullPolicyWithDefault to validation.
2015-01-20 11:54:22 -08:00
Tim Hockin
6cb275829f
Implement volumes as plugins.
...
Break up the monolithic volumes code in kubelet into very small individual
modules with a well-defined interface. Move them all into their own packages
and beef up testing along the way.
2015-01-20 11:45:45 -08:00
Andrew Seidl
6dee1d7fa4
Fix typos in user-facing strings
2015-01-18 01:32:34 -06:00
Filipe Brandenburger
79ff06ffa1
Fix comparison of EtcdClient to nil so that it does not run into the pointer vs. interface issue
...
This is a partial rollback of commit 6e6f465a36
("Fix a crash for
kubelet when without EtcdClient") in which we used the `reflect` module
to inspect that the pointer stored inside the interface was `nil`, but
as pointed out by @lavalamp, the correct solution is to make the
function return the interface type, in which case a `return nil` will
return the interface nil and not a nil pointer that turns into a non-nil
value when coerced into an interface.
For more details, see http://golang.org/doc/faq#nil_error and the
discussion in PR #3356 .
Tested by installing a kubelet built from head with this patch into a
containervm instance and confirming it did not crash on standalone.go.
Confirmed that by only removing the `reflect.IsNil()` comparison but not
changing the return type of `EtcdClientOrDie()` did indeed cause that
same crash, so changing the return type does indeed fix the issue.
Signed-off-by: Filipe Brandenburger <filbranden@google.com>
2015-01-16 16:43:05 -08:00
Brendan Burns
d54242a649
Merge pull request #3552 from commonlisp/master
...
Replace kubelet logging %s--%s--%s with dockertools.BuildDockerName()
2015-01-16 14:31:43 -08:00
Eric Tune
98bdd3f7c4
Test for and fix crash with nil client in kubelet.
...
Added test that fails before fix.
Fixed use of nil pointer.
2015-01-16 13:39:31 -08:00
Brendan Burns
e86c8f9e53
Merge pull request #3565 from dchen1107/podstatus
...
Introduce PodStatusResult, and deprecate PodContainerInfo.
2015-01-16 12:05:07 -08:00
Dawn Chen
15e9fa8a9d
Introduce PodStatusResult, and deprecate PodContainerInfo.
2015-01-16 09:10:40 -08:00
George Kuan
af4bbd1a1b
Replace kubelet logging %s--%s--%s with dockertools.BuildDockerName()
...
Fixes issue #3454
2015-01-15 19:47:54 -08:00
Eric Tune
5aeda8a5bb
Remove dead code in test.
2015-01-15 14:49:08 -08:00
Daniel Smith
46f8a56dba
Merge pull request #3376 from erictune/channel_api
...
Kublet watches Pods.
2015-01-15 14:48:12 -08:00
Eric Tune
2e002b1095
Add second pod to test.
2015-01-15 13:36:49 -08:00
saadali
b57cc6a11c
Increase timeout for TestEtcdSourceExistingBoundPods test
2015-01-14 17:06:04 -08:00
Daniel Smith
46827720b3
Merge pull request #3493 from saad-ali/testFor3467
...
Add test case for EtcdSource ExistingBoundPods
2015-01-14 16:35:26 -08:00
saadali
a1c287ede9
Add test case for EtcdSource ExistingBoundPods
2015-01-14 16:15:08 -08:00
Eric Tune
b759f67ee3
Kublet watches Pods.
...
Added a kubelet config source for watching pods on apiserver.
The pods are converted to boundpods for merging with other
config sources.
The preferred way to create a kubelet is now to pass an apiserver
client but not an etcd client. Changed cmd/integration to use
apiserver to talk to kubelets. And cmd/kubernetes.
Unit, integration, and e2e tests pass, except for a failure of the pd
e2e test which was unrelated.
2015-01-14 15:31:26 -08:00
Tim Hockin
1be3de895c
Move util.UID to pkg/types
2015-01-14 15:22:21 -08:00
Daniel Smith
c13ae34b02
Merge pull request #3445 from saad-ali/fix3172
...
Remove CONDITION from event object completely
2015-01-14 15:03:06 -08:00
Eric Tune
88c68e0349
Merge pull request #3331 from pmorie/services
...
Service visibility w/in namespaces, master services, set env vars in kubelet
2015-01-14 15:01:05 -08:00
Daniel Smith
8a764c02d5
Merge pull request #3478 from thockin/uid_type
...
Use a strong type for UID fields
2015-01-14 14:20:22 -08:00
saadali
90dfdcecd5
Remove CONDITION from event object completely
...
# *** ERROR: *** Some files have not been gofmt'd. To fix these
# errors, run gofmt -s -w <file>, or cut and paste the following:
# gofmt -s -w pkg/kubecfg/resource_printer.go pkg/proxy/config/config.go pkg/runtime/types.go
#
# Your commit will be aborted unless you override this warning. To
# commit in spite of these format errors, delete the following line:
# COMMIT_BLOCKED_ON_GOFMT
2015-01-14 14:17:16 -08:00
Paul Morie
fd834ae84d
Pods should see services only from their own ns
2015-01-14 17:06:36 -05:00
Dawn Chen
009c5e1129
Using ExtractObj instead of ExtractToList since BoundPods is not a List type
2015-01-14 14:05:47 -08:00
Tim Hockin
e86d4cd3c6
Use a strong type for UID fields
2015-01-14 13:53:43 -08:00
Dawn Chen
0716df8f2b
Fix Event.Source for hostname_override case.
2015-01-14 09:43:13 -08:00
saadali
826b61c76d
Address nits from PR #3423
2015-01-13 23:34:37 -08:00
Tim Hockin
ca89aa6528
Make data dirs for all pods when syncing
2015-01-13 17:18:21 -08:00
saadali
110ab6f1bd
Split up kubelet "source seen" logic
2015-01-12 21:48:55 -08:00
Daniel Smith
55653568ae
Merge pull request #3385 from erictune/source_api
...
Added kubelet config source from apiserver.
2015-01-12 15:47:15 -08:00
Eric Tune
18bcef5235
Added kubelet config source from apiserver.
2015-01-12 15:29:16 -08:00
Tim Hockin
0d92da6b15
Remove logic to handle if UID is blank
...
This should only have been triggered by tests, and those should now be fixed.
I tested by calling panic() if UID was blank in BuildDockerName() or if number
of fields was < 5 in ParseDockerName(). All errors were fixed.
2015-01-12 14:27:34 -08:00
Tim Hockin
905514a12b
Ensure Namespace and UID are set in kubelet
...
Make all kubelet config sources ensure that UID and Namespace are defaulted, if
need be.
We can *almost* disable the "if blank" logic for UID, except for tests that
call APIs that do not run through SyncPods. We really ought to be enforcing
invariants better.
2015-01-12 14:27:34 -08:00
Tim Hockin
af0e2fd551
Merge pull request #3403 from thockin/klet-dirs-structure
...
Apply more structure to pod data dirs
2015-01-12 14:19:22 -08:00
saadali
e1917cf900
Fix "Kubelet doesn't kill old pods when BoundPods is empty" issue
2015-01-12 12:39:47 -08:00
Tim Hockin
523a80bec7
Apply more structure to pod data dirs
...
This is makes it possible to read back "known" pods from disk without
getting other (non-pod) kubelet dirs in the mix. Ditto for containers
within a pod. This is just saner overall. Pods now nest in a pods/
dir. Likewise containers.
2015-01-12 06:16:32 -08:00
Eric Tune
29d084c4d3
Pass client into Kubelet.
...
Subsequent PR will make use of it.
2015-01-08 15:35:17 -08:00
Tim Hockin
eac982137f
Merge pull request #3260 from commonlisp/master
...
NewMainKubelet validates SyncFrequency, minimum GC age, etc.
2015-01-08 08:20:55 -08:00
George Kuan
06475fc4b4
NewMainKubelet validates Kubelet config parameters
...
Fixes issue #3202 .
* Validates SyncFrequency and minimum GC age and propagates error to RunKubelet
* Defaults for Kubelet config and minor cleanup
* cmd Kubelet MinimumGCAge to 1m instead of 0
2015-01-07 18:50:53 -08:00
Daniel Smith
95dd2d7ca6
reuse function; never ever unlock without defer
2015-01-07 17:07:12 -08:00
Tim Hockin
5f2dae4dd8
Merge pull request #3195 from lavalamp/numericWire
...
Add numeric type into api
2015-01-07 16:15:52 -08:00
Daniel Smith
35f54addca
Update more packages, tests, binaries for quantity
...
make etcd registry pass test
fix kubelet config for quantity
fix openstack for quantity
fix controller for quantity
fix last tests for quantity
wire into binaries
fix controller manager
fix build for 32 bit systems
2015-01-07 15:21:35 -08:00
Daniel Smith
7f49ba0dcf
Put quantity into packages
...
kubelet, GCE, validation, client
2015-01-07 15:21:34 -08:00
Clayton Coleman
ba53d723d3
Clean up how client is passed to Kubelet in preparation for reading pods
...
Also fixes how Kubelet server looks up pods by name when there are multiple
sources.
2015-01-07 14:40:37 -05:00
Brendan Burns
7c69570663
Add a lock around the other docker pull.
...
Fixes e2e (I hope), certainly passes e2e in my client.
2015-01-07 00:17:57 -08:00
Brendan Burns
733e12e19b
Revert "Avoid race between image pull and garbage collect"
...
This reverts commit 6f14e2e210
.
2015-01-06 23:23:23 -08:00
Brendan Burns
e84b4d03a4
Merge pull request #3183 from anguslees/pull-lock
...
Avoid race between image pull and garbage collect
2015-01-06 21:23:29 -08:00
Dawn Chen
e3c019128e
Add EventSource to api to have both Component and Host information.
2015-01-06 16:08:20 -08:00
Dawn Chen
2b91c1417c
Create selfLink for pods from config files and indicate hostname as part of event source.
2015-01-06 16:08:20 -08:00
Tim Hockin
8b42534f77
Fix kubelet config tests
2015-01-06 13:02:41 -08:00
Tim Hockin
88fe5c6f46
Never set pod.Name in kubelet config code
...
I think it is time to tighten up input requirements. The validation code will
reject a pod that has an empty name field.
2015-01-06 11:14:19 -08:00
Tim Hockin
cae572290b
Merge pull request #3230 from saad-ali/hashingLogging
...
Improve kubelet logging around container being killed due to hash change
2015-01-05 16:48:29 -08:00
saadali
d6d18a32e7
Replace %s with %q to make empty strings more obvious
2015-01-05 16:38:47 -08:00
Tim Hockin
03baa7234a
Merge pull request #3225 from dchen1107/clean
...
Move GetHostName and GetDockerEndpoint methods to pkg/util
2015-01-05 16:21:51 -08:00
saadali
eb831919d9
Improve kubelet logging around container being killed due to hash change
2015-01-05 16:20:40 -08:00
saadali
f92f830e1f
Modify hash to be computed using spew library so that nested object values are used instead of pointer
2015-01-05 15:48:06 -08:00
Dawn Chen
f718957a79
Move GetHostName and GetDockerEndpoint methods to pkg/util
2015-01-05 11:44:21 -08:00
Dawn Chen
78547d9a87
Merge pull request #3194 from vishh/stats
...
Update "/stats" endpoint on kubelet.
2015-01-05 11:23:00 -08:00
Vishnu Kannan
3ef9e404c1
Update "/stats" endpoint on kubelet to take namespace as an argument as part of the API.
2015-01-03 02:17:25 +00:00
Angus Lees
6f14e2e210
Avoid race between image pull and garbage collect
...
Hold the pullLock while pulling regular container images, not just the
network container.
Also: previously, the locks were grabbed at too-low a layer in the
callstack, leaving a (narrow) window where images could be pulled and
then garbage collected before being used.
This change takes the existing pullLock a layer higher in the call stack
so the critical regions encompass the entire find+delete and pull+use
operation in both cases.
2014-12-31 11:50:40 +11:00
saadali
e8d30f019d
Modify "kubectl get events" to print FieldPath so BoundPod events for the same Pod but different containers can be differentiated
2014-12-29 21:32:49 -08:00
Dawn Chen
d38613777b
Propagate syncPod error as event to upper layer.
2014-12-29 15:42:47 -08:00
Tim Hockin
652479a3b1
Add kubelet DNS flags & api disable for DNS
...
This adds --cluster_dns and --cluster_domain flags to kubelet. If
non-empty, kubelet will set docker --dns and --dns-search flags based on
these. It uses the cluster DNS and appends the hosts's DNS servers.
Likewise for DNS search domains.
This also adds API support to bypass cluster DNS entirely, needed to
bootstrap DNS.
2014-12-29 09:18:12 -08:00
Brendan Burns
b8781c04bb
Add support for garbage collecting images.
2014-12-22 16:56:58 -08:00
Dawn Chen
f073ecf4cc
Understand OOMKilled reason
2014-12-18 15:59:44 -08:00
Vish Kannan
c34f2d354c
Merge pull request #3035 from dchen1107/master
...
Update fsouza/go-dockerclient pkg to latest revision and fix some compiling issues.
2014-12-18 14:07:40 -08:00
Dawn Chen
608c3d5046
Update kubelet package on latest go-dockerclient package.
2014-12-18 13:49:13 -08:00
Brendan Burns
845fb5013d
Remove some dead code.
2014-12-18 13:32:20 -08:00
Dawn Chen
71fc5940f1
suppress unnecessary stacktrace when http status code is redirect related.
2014-12-17 18:42:11 -08:00
Brendan Burns
928f52056e
Remove HTTP Server support for pushing pods onto the kubelet.
2014-12-17 17:15:36 -08:00
Brendan Burns
7da0378f3c
Track the sources that the kubelet has seen, and only delete pods
...
when every source has been seen at least once.
2014-12-17 13:08:43 -08:00
Brendan Burns
bb28949291
Merge pull request #2831 from jdef/unit_test_for_2815
...
unit test for #2815 , as requested by @brendandburns
2014-12-16 15:08:41 -08:00
Brendan Burns
3a0d16ff35
Add an e2e test for exec liveness probes. Fix the docker exec integration.
2014-12-16 13:53:32 -08:00
Daniel Smith
6902f6ab21
Merge pull request #2844 from brendandburns/fix
...
Handle a missing apiserver flag better.
2014-12-15 17:25:09 -08:00
bgrant0607
9bc8915eeb
Merge pull request #2912 from smarterclayton/small_v1beta3_refactors_2
...
More small refactors for v1beta3 -> internal
2014-12-15 15:16:36 -08:00
Brendan Burns
1a5a7ebd69
Handle a missing apiserver flag better.
2014-12-15 15:14:41 -08:00
Brendan Burns
2c64db5943
Merge pull request #2938 from vishh/exec
...
Updated docker version that supports exec to '1.3.0'.
2014-12-15 14:49:12 -08:00
Clayton Coleman
dadb8431c4
Remove internal PodState in favor of internal PodStatus object
2014-12-15 16:50:05 -05:00
Vishnu Kannan
f4ef05bc20
Updated docker version that supports exec to '1.3.0'.
2014-12-15 20:44:58 +00:00
Brendan Burns
a6f967b6e7
Revert "Revert "Add an api object for the kubelet, and a versioned endpoint.""
...
This reverts commit dcfcf315e5
.
2014-12-15 09:29:04 -08:00
Brendan Burns
dcfcf315e5
Revert "Add an api object for the kubelet, and a versioned endpoint."
...
This reverts commit d4b9979382
.
2014-12-12 21:13:44 -08:00
James DeFelice
3afc9fffba
fixed minor formatting
2014-12-12 20:43:07 -05:00
Brendan Burns
d4b9979382
Add an api object for the kubelet, and a versioned endpoint.
2014-12-12 15:26:28 -08:00
Jordan Liggitt
51bfb50698
Use util.Time consistently in types.go
2014-12-11 11:14:25 -05:00
Federico Simoncelli
4af64b8911
api: add container's id to ContainerStatus
...
Sometimes for external applications it is useful to correlate the pod
containers to the real docker instances.
This patch adds a new entry in the container status (containerID) which
is used to identify the instance.
Signed-off-by: Federico Simoncelli <fsimonce@redhat.com>
2014-12-10 20:38:41 +00:00
James DeFelice
85b4b4677e
unit test for #2815 , as requested by @brendandburns
2014-12-10 15:33:38 -05:00
Dawn Chen
17475cdbe7
Merge pull request #2821 from lavalamp/fix
...
Allow, when testing, SelfLinks to be unset.
2014-12-10 12:10:51 -08:00
Dawn Chen
5c79668854
Merge pull request #2815 from jdef/inspect_tagged_image
...
inspect the full repo/image:tag name
2014-12-10 11:53:14 -08:00
Daniel Smith
e46bfcf699
Allow, when testing, SelfLinks to be unset. Kubelet now makes events in tests.
2014-12-09 17:53:42 -08:00
Saad Ali
9a1fea6927
Merge pull request #2817 from lavalamp/fix
...
Compare containers by name, not by pointer equality.
2014-12-09 17:33:56 -08:00
Daniel Smith
ba62943b8e
Compare containers by name, not by pointer equality.
2014-12-09 17:06:39 -08:00
Brendan Burns
4985f58eb5
Merge pull request #2759 from mikedanese/configure-cadvisor-port
...
make cadvisor port configurable on the kubelet
2014-12-09 15:21:35 -08:00
James DeFelice
ca2840a8e8
inspect the full repo/image:tag name
2014-12-09 15:41:08 -05:00
Tim Hockin
acc6b95c21
Add functions to get kubelet directories.
...
Gets rid of some magic constants and makes volume plugins (coming later)
cleaner.
2014-12-06 11:00:19 -08:00
Mike Danese
722abf1a95
- make cadvisor port configurable on the kubelet.
...
- added cadvisor port documentation.
2014-12-06 09:48:08 -08:00
James DeFelice
76ef747927
avoid panics when docker CT has no name
2014-12-05 15:48:25 -05:00
Victor Marmol
b1c7893916
Merge pull request #2683 from jimmidyson/cadvisor-0.6.2
...
Fixes #2681 : update to cadvisor 0.6.2
2014-12-04 03:48:40 +08:00
Sam Ghods
9a9a1e0939
Move from go-yaml/yaml to ghodss/yaml
2014-12-02 16:24:05 -08:00
Tim Hockin
f4b031d025
Merge pull request #2514 from thockin/label-ns
...
Add label key namespacing
2014-12-02 13:38:46 -08:00
Brendan Burns
993ef88eec
Merge pull request #2689 from brendandburns/standalone
...
Refactor kubelet, standalone k8s and integration test to all use the same code.
2014-12-01 21:53:41 -08:00
Brendan Burns
d47b510104
Refactor kubelet, standalone k8s and integration test to all use the same code.
2014-12-01 15:37:21 -08:00
Tim Hockin
89875ef09d
Loosen DNS 952 for labels
2014-12-01 12:30:43 -08:00
Jimmi Dyson
5109ce3356
Fixes #2681 : update to cadvisor 0.6.2
2014-12-01 11:38:03 +00:00
Eric Tune
54859cf1ea
Remove format specifiers with no options.
2014-11-26 12:05:00 -08:00
Brendan Burns
a5bc6301a4
Revert "Using util.Time for ContainerStatus"
2014-11-24 21:32:31 -08:00
Daniel Smith
610ab9a0db
Merge pull request #2586 from dchen1107/cleanup
...
Using util.Time for ContainerStatus
2014-11-24 15:35:07 -08:00
Dawn Chen
acb0f1198b
Using util.Time for ContainerStatus
2014-11-24 15:15:33 -08:00
Eric Tune
f122fc94bf
Move service enviroment vars code.
...
GetServiceEnvironmentVariables (originally in pkg/registry/service/rest.go)
is split into two parts: one that lists services, and one that turns
a ServiceList into environment vars. This will allow a subsequent PR
to add a call to the latter function with an existing ServiceList.
The former part is moved into pkg/registry/pod/bound_pod_factory.go.
The latter part is put in a new package, pkg/kubelet/envvars/envvars.go.
The new package is under kubelet because the container enviroment is more
associated with kubelet than with registry.
Test code moved too.
2014-11-23 05:50:34 -08:00
Eric Tune
7d3e00c679
Remove never-needed return value.
...
Make some types private.
2014-11-21 15:11:45 -08:00
bgrant0607
9f5ebef3d8
Merge pull request #2513 from lavalamp/verifyNetwork
...
Fix crash (loop?) in kubelet
2014-11-21 10:10:32 -08:00
Daniel Smith
9116c27040
Fix crash (loop?) in kubelet
2014-11-20 18:28:23 -08:00
Tim Hockin
95a9098311
fix 'go vet' warnings
2014-11-21 09:45:28 +08:00
Tim Hockin
ea960711ff
Clean up error logs.
...
Use %v for errors, tidy some messages, make error messages start lowe-case
(as per go guidelines). Just accumulated nits.
2014-11-21 09:45:26 +08:00
Dawn Chen
6d3324c3fd
Add image related events to kubelet.
2014-11-19 15:16:14 -08:00
Brendan Burns
cea52d7e4f
Merge pull request #2409 from mattmoor/master
...
Implements a credentialprovider library for use by DockerPuller.
2014-11-17 21:53:25 -08:00
Matt Moore
0c5d9ed0d2
Implements a credentialprovider library for use by DockerPuller.
...
This change refactors the way Kubelet's DockerPuller handles the docker config credentials to utilize a new credentialprovider library.
The credentialprovider library is based on several of the files from the Kubelet's dockertools directory, but supports a new pluggable model for retrieving a .dockercfg-compatible JSON blob with credentials.
With this change, the Kubelet will lazily ask for the docker config from a set of DockerConfigProvider extensions each time it needs a credential.
This change provides common implementations of DockerConfigProvider for:
- "Default": load .dockercfg from disk
- "Caching": wraps another provider in a cache that expires after a pre-specified lifetime.
GCP-only:
- "google-dockercfg": reads a .dockercfg from a GCE instance's metadata
- "google-dockercfg-url": reads a .dockercfg from a URL specified in a GCE instance's metadata.
- "google-container-registry": reads an access token from GCE metadata into a password field.
2014-11-17 21:46:54 -08:00
Eric Tune
0ca192889f
Fix namespace of minion birthcry event.
2014-11-17 15:34:07 -08:00
Daniel Smith
eeb4547bec
Merge pull request #2392 from dchen1107/upstream1
...
Generate container related events from kublet
2014-11-17 11:28:52 -08:00
Dawn Chen
736c4ffb0b
more events from kublet
2014-11-17 11:00:46 -08:00
Dawn Chen
8a508bcce3
Merge pull request #2391 from lavalamp/fix3
...
Remove confusing function; add TODO and explanation for (nonfatal) error...
2014-11-14 17:24:18 -08:00
Daniel Smith
c412540cf2
Remove confusing function; add TODO and explanation for (nonfatal) error message in integration test.
2014-11-14 17:16:05 -08:00
Dawn Chen
ce145545b9
Add unittests to test PullPolicy.
2014-11-14 16:09:53 -08:00
Dawn Chen
f729d748ac
If the image with :latest tag specified in Spec, kubelet should try
...
to pull the latest one even the policy is PullIfNotPresent.
2014-11-14 16:09:53 -08:00
Clayton Coleman
6d31c2bf8a
util.EncodeJSON proven harmful, remove it everywhere
...
People were misusing EncodeJSON in tests when they should be using
runtime.EncodeOrDie(testapi.Codec(), obj). Removing the potential
for cutting self on sharp objects.
2014-11-13 10:38:13 -05:00
jhadvig
f2f1708687
Setting RawTerminal attribute in LogOptions to false
2014-11-12 17:47:52 +01:00
Clayton Coleman
b5a88a4662
Merge pull request #2283 from dchen1107/deathrattle
...
Fixed Eventf with wrong arguments.
2014-11-11 10:41:51 -05:00
Dawn Chen
ada43ae233
Fixed Eventf with wrong arguments.
2014-11-10 23:53:48 -08:00
Brendan Burns
db0d98daa2
Merge pull request #2257 from jhadvig/kubelet_timeout
...
Bumping kubelet write/read timeout
2014-11-10 21:18:25 -08:00
Eric Tune
08c8f2cde1
Record event of kubelet restart re: minion obj.
2014-11-10 13:46:48 -08:00
bgrant0607
3cf17c0094
Merge pull request #2225 from dchen1107/deathrattle
...
Capture application termination messages/output
2014-11-10 11:25:14 -08:00
Dawn Chen
57454cce81
Add support to capture application termination message and propagate
...
the message to the upper layer through ContainerStatus.
2014-11-10 10:56:23 -08:00
Dawn Chen
8ffbced280
Introduce terminationMessagePath to Container, and update conversion code
...
to assign the default path.
Move default setting for terminationMessagePath to conversion
from validation. Addressed other comments.
2014-11-10 10:55:56 -08:00
jhadvig
dfa076b79a
Dumping kubelet write/read timeout
2014-11-10 17:09:50 +01:00
Dawn Chen
b4ab6e6ecc
Remove dead code.
2014-11-07 11:05:35 -08:00
Mike Danese
1d76452bc2
added support for authentication against the default docker registry when provided in the .dockercfg
...
a
2014-11-06 11:52:25 -08:00
Dawn Chen
e88e490614
Merge pull request #2143 from lavalamp/eventing2.1
...
Begin putting event emission into kubelet
2014-11-05 15:37:26 -08:00
Brendan Burns
0a1493a5ce
Merge pull request #2160 from dchen1107/fix
...
Restart network container when container's configure is changed.
2014-11-05 15:13:05 -08:00
Daniel Smith
dcc111bf13
Start putting event generation into kubelet (not enabled yet)
2014-11-05 15:09:14 -08:00
bgrant0607
fc0dab630c
Merge pull request #2086 from markturansky/v1beta3_refactor
...
Refactor internal API for Services to match v1beta3
2014-11-04 21:48:02 -08:00
Daniel Smith
4b16e979e6
Fix nil docker client (how did this ever work???)
2014-11-04 16:58:37 -08:00
Dawn Chen
03958f5049
Restart network container when container's configure is changed.
...
Fix #2099
2014-11-04 14:38:33 -08:00
markturansky
bd7643c033
refactor services to v1beta3
2014-11-04 14:23:53 -05:00
Brendan Burns
4ae3e99177
Change a spammy log to V(3)
2014-11-03 08:38:02 -08:00
Brendan Burns
69ca97a41c
Fix a flaky test by draining the worker pool after syncing.
2014-10-31 09:52:01 -07:00
Brendan Burns
69ad5c9bff
Merge pull request #2077 from dchen1107/cleanup
...
PodUpdate only has the delta changes, not full snapshot of all desired
2014-10-30 21:46:26 -07:00
Deyuan Deng
acf9d23b32
Stop httptest server.
2014-10-30 21:37:08 -04:00
Dawn Chen
a1e79048a6
Add /podSpecs to Kubelet
2014-10-30 16:38:08 -07:00
Dawn Chen
445ec719c9
PodUpdate only has the delta changes, not full snapshot of all desired
...
BoundPods on a node. PR #1865 has a wrong assumption, with which any
PodUpdate operation will cause rest of running containers without updates
are killed as an unexpected ones.
Fix #2028
2014-10-30 11:22:59 -07:00
Brendan Burns
51bf451932
Add container garbage collection.
2014-10-28 12:52:06 -07:00
Tim Hockin
2bbd11eda6
Merge pull request #1975 from smarterclayton/split_type_meta
...
Split TypeMeta into ObjectMeta/ListMeta
2014-10-24 08:43:00 -07:00
Clayton Coleman
644eb70085
Refactor tests to split ObjectMeta from TypeMeta
2014-10-24 11:22:21 -04:00
Clayton Coleman
7550c146dc
Replace struct initializers for TypeMeta with ObjectMeta
2014-10-24 11:22:21 -04:00
Tim Hockin
0a202354b9
Fix race between syncPod and syncPods
2014-10-23 15:53:26 -07:00
Tim Hockin
099934d49f
Cleanups in syncPod
2014-10-23 15:53:26 -07:00
Tim Hockin
76c33a88b6
Remove redundancy in SyncPods
2014-10-23 15:53:26 -07:00
Tim Hockin
36a05ee871
Improve kubelet logging
2014-10-23 15:53:26 -07:00
Tim Hockin
487867bd01
Extract cadvisor code to cadvisor.go
2014-10-23 15:53:26 -07:00
Tim Hockin
de3060e4eb
Rename httpGetInterface to httpGetter
2014-10-23 15:53:26 -07:00
Clayton Coleman
bb77a5d15f
Rename ID -> Name
2014-10-22 15:00:26 -04:00
Daniel Smith
91efe51770
Merge pull request #1829 from jhadvig/proxy_flush
...
Flush data periodically instead of their buffering
2014-10-21 17:01:15 -07:00
Johan Euphrosine
14c3b9d900
runonce: handle inspect error
2014-10-21 13:38:11 -07:00
Johan Euphrosine
6cd0c261b3
runonce: better container state detection
2014-10-21 12:00:51 -07:00
Brendan Burns
b47486abe7
Merge pull request #1771 from vishh/native_exec
...
Use native exec support in docker instead of exec'ing nsinit in kubelet.
2014-10-21 07:32:07 -07:00
Brendan Burns
b74854895e
Merge pull request #1921 from smarterclayton/http_listen_err_is_fatal
...
ListenAndServe on Kubelet server should be a fatal error
2014-10-21 07:23:59 -07:00
jhadvig
f759bfdf71
Implementing Flush method to httplog
2014-10-21 09:33:00 +02:00
Clayton Coleman
d0ef3f0596
ListenAndServe on Kubelet server should be a fatal error
2014-10-21 00:10:35 -04:00
Clayton Coleman
3f8d30881c
Sort of pods in test case was incorrect
2014-10-20 17:45:01 -04:00
Tim Hockin
87b0b3ad67
Better config-file logging in kubelet
2014-10-20 08:49:55 -07:00
Michal Fojtik
0bccce4520
Move error about connecting to healthz server to V(1)
2014-10-20 15:31:01 +02:00
Tim Hockin
783c0d7532
Merge pull request #1865 from brendandburns/kubelet
...
Support updates in the kubelet.
2014-10-17 17:21:16 -07:00
Dawn Chen
8858c5f897
Merge pull request #1871 from derekwaynecarr/handle_container_logs_on_alternate_namespace
...
handleContainerLogs needs a namespace to address a pod
2014-10-17 15:42:11 -07:00
Dawn Chen
7611c839e9
Merge pull request #1873 from derekwaynecarr/kubelet_handleRun_namespace_aware
...
Make kubelet handleRun work for pods in non-default namespace
2014-10-17 15:23:40 -07:00
derekwaynecarr
1f094d973d
make kubelet handleRun work for pods in non-default namespace
2014-10-17 16:12:26 -04:00
derekwaynecarr
897f1b3ab5
handleContainerLogs needs a namespace to address a pod
2014-10-17 16:00:50 -04:00
derekwaynecarr
d590af2ce5
Fixup kubelet handlePodInfo to be namespace aware
2014-10-17 14:42:46 -04:00
Brendan Burns
aa55e87ac2
Support updates in the kubelet.
2014-10-17 11:02:21 -07:00
Vishnu Kannan
7b3db4d41b
Use native exec support in docker instead of execing nsinit in kubelet.
2014-10-17 10:04:46 +00:00
Clayton Coleman
26cff8b9bf
Rename the etcd path for pods to be /registry/nodes/<>/boundpods
2014-10-16 19:29:08 -04:00
Clayton Coleman
892942af8f
Read BoundPods from etcd instead of ContainerManifestList
...
There are three values that uniquely identify a pod on a host -
the configuration source (etcd, file, http), the pod name, and the
pod namespace. This change ensures that configuration properly
makes those names unique by changing podFullName to contain both
name (currently ID in v1beta1, Name in v1beta3) and namespace.
The Kubelet does not properly handle information requests for
pods not in the default namespace at this time.
2014-10-16 19:29:08 -04:00
Dawn Chen
33ef0ca159
Make watching error logging message less severe since it is expected.
...
Fix #1653
2014-10-14 16:42:28 -07:00
Daniel Smith
a292d8c416
Merge pull request #1667 from hmrm/add-kubelet-disable-flags
...
Allow disabling non-necessary kubelet and apiserver endpoints
2014-10-10 13:38:11 -07:00
Dawn Chen
5f97413dd5
Merge pull request #1663 from smarterclayton/separate_pod_state_for_health_check
...
Refactor HealthCheck to take podUUID as its own argument
2014-10-10 09:11:59 -07:00
Tim Hockin
d84816aaec
Merge pull request #1709 from erictune/move_line
...
Fix format specifiers in Printf-type functions.
2014-10-09 20:40:35 -07:00
Daniel Smith
7bb1bdd693
Merge pull request #1711 from erictune/vets
...
Use pointer for struct holding lock.
2014-10-09 17:25:54 -07:00
Eric Tune
42f6324183
Use pointer for struct holding lock.
2014-10-09 17:16:21 -07:00
Eric Tune
800284164a
Fix format specifiers in Printf-type functions.
2014-10-09 17:06:32 -07:00
Haney Maxwell
c0bf974871
Allow disabling non-necessary kubelet and apiserver endpoints
2014-10-09 16:49:27 -07:00
Clayton Coleman
95cb2e3eb3
Refactor HealthCheck to take podUUID arguments
...
PodState is going away (won't have podUUID anymore)
2014-10-09 16:42:55 -04:00
Eric Tune
4e0a72734e
Handle and log errors when reading .dockercfg
2014-10-09 13:22:14 -07:00
Dawn Chen
ed4167a938
Merge pull request #1670 from proppy/fix-kubelet-runonce
...
kubelet: only check for container listed in the manifest
2014-10-09 09:31:12 -07:00
Johan Euphrosine
0fc5e68207
runonce: isPodRunning returns no error
2014-10-08 22:34:40 -07:00
Johan Euphrosine
8f010c3ec0
dockertools: add todo for container lookup
2014-10-08 22:31:59 -07:00
Johan Euphrosine
dbb2342688
runonce: list kubelet container between each iteration
2014-10-08 22:28:41 -07:00
Johan Euphrosine
14c5fd405d
kubelet: only check for container listed in the manifest
...
also wait 1 retryDelay before polling state after syncing.
2014-10-08 17:49:21 -07:00
Daniel Smith
1fc92bef53
Load cadvisor connection in background.
2014-10-08 17:06:41 -07:00
Daniel Smith
e1cb72f1ae
Merge pull request #1643 from smarterclayton/make_resource_version_a_string
...
Make ResourceVersion internally a string instead of uint64
2014-10-08 14:00:37 -07:00
Tim Hockin
2f2ef05fa8
Merge pull request #1646 from dchen1107/termination
...
Fix an issue on GetContainerInfo.
2014-10-07 17:27:56 -07:00
Dawn Chen
300c2c5f6f
Fix an issue on GetContainerInfo.
...
I believe the issue was first introduced when we append namespace to docker
container's name. This is a temporary fix for #160 .
2014-10-07 17:21:24 -07:00
Clayton Coleman
82bcdd3b3b
Make ResourceVersion a string internally instead of uint64
...
Allows us to define different watch versioning regimes in the future
as well as to encode information with the resource version.
This changes /watch/resources?resourceVersion=3 to start the watch at
4 instead of 3, which means clients can read a resource version and
then send it back to the server. Clients should no longer do math on
resource versions.
2014-10-07 19:00:26 -04:00
Tim Hockin
48a9ed3147
Merge pull request #1637 from lavalamp/fix
...
Fix 'go vet' issues
2014-10-07 14:25:41 -07:00
Daniel Smith
2d048bc0f2
fix captured loop variable
2014-10-07 13:57:30 -07:00
Dawn Chen
73c8f41737
Add the missing arg in Errorf.
2014-10-07 13:53:25 -07:00
Brendan Burns
7ecd8d7207
Fix a problem with for loops, copy semantics and async routines.
2014-10-06 21:20:00 -07:00
Dawn Chen
4fdfeaa30e
Addressed comments.
2014-10-06 14:41:20 -07:00
Dawn Chen
a86d496f9a
Fix e2e tests.
2014-10-06 13:37:24 -07:00
Dawn Chen
39f648bda2
Fix rebase issues.
2014-10-06 13:37:23 -07:00
Dawn Chen
8d0ed93aa1
Clean unittests
2014-10-06 13:37:22 -07:00
Dawn Chen
9861eb7c8e
Initial support of propogating the termination reasons and image failure
...
to apiserver. Deprecated docker.Container from API completely.
Conflicts:
pkg/api/types.go
pkg/kubelet/kubelet.go
2014-10-06 13:37:22 -07:00
Tim Hockin
0ad0a247c4
Flag-compatible IP type
2014-10-06 11:29:22 -07:00
Johan Euphrosine
fa1dcd0a8b
kubelet: add basic test for runonce
2014-10-03 18:02:30 -07:00
Johan Euphrosine
f91162cf78
kubelet: add --runonce flag, exits after starting pod from the manifest
2014-10-03 18:02:30 -07:00
Deyuan Deng
a9e7cf8e40
Fix integration test read volume dir error.
2014-10-03 19:51:07 -04:00
Clayton Coleman
6881db64a9
Allow configurable Kubelet net image for isolated networks
...
Public access to the DockerHub is not guaranteed in all environments,
add a flag to the kubelet that allows it to use a different image (like
one on a private registry) as well as only pull the first time the
image is needed.
Fixes #1545
2014-10-02 15:56:03 -04:00
Eric Tune
9c0769422d
Directory renamed to Dir to match json property
2014-10-01 13:35:21 -07:00
Tim Hockin
db49dc0012
Merge pull request #1458 from brendandburns/dontpull
...
Add the ability to turn off image pulling.
2014-10-01 12:40:47 -07:00
Brendan Burns
4c456015b6
Add the ability to turn off image pulling.
2014-10-01 12:34:22 -07:00
jhadvig
9b21053188
ListContainer filter
2014-09-30 23:30:32 +02:00
Tim Hockin
1c02af3d16
Kill LivenessProbe.Type
2014-09-27 21:16:30 -07:00
Tim Hockin
04cdf286a4
Make and use api.Protocol type
2014-09-27 20:31:37 -07:00
Tim Hockin
badeaef95f
Merge pull request #1457 from brendandburns/pull
...
Add a rate limiter, use it to rate limit docker pulls.
2014-09-26 12:39:25 -07:00
Brendan Burns
3ac706a32e
Add a rate limiter, use it to rate limit docker pulls.
2014-09-26 11:55:21 -07:00
Dawn Chen
01c9015ed3
use _ as the separator for docker container name.
2014-09-26 09:21:21 -07:00
Tim Hockin
7a96ed38b3
Merge pull request #1439 from jhadvig/err_handler
...
Handle invalid pod name
2014-09-25 15:00:47 -07:00
jhadvig
e5d8ee3811
Handle invalid pod name
2014-09-25 22:57:05 +02:00
Clayton Coleman
4e56dafecc
Introduce some default log verbosity control
...
Move a lot of common error logging into better buckets:
glog.Errorf() - Always an error
glog.Warningf() - Something unexpected, but probably not an error
glog.V(0) - Generally useful for this to ALWAYS be visible
to an operator
* Programmer errors
* Logging extra info about a panic
* CLI argument handling
glog.V(1) - A reasonable default log level if you don't want
verbosity
* Information about config (listening on X, watching Y)
* Errors that repeat frequently that relate to conditions
that can be corrected (pod detected as unhealthy)
glog.V(2) - Useful steady state information about the service
* Logging HTTP requests and their exit code
* System state changing (killing pod)
* Controller state change events (starting pods)
* Scheduler log messages
glog.V(3) - Extended information about changes
* More info about system state changes
glog.V(4) - Debug level verbosity (for now)
* Logging in particularly thorny parts of code where
you may want to come back later and check it
2014-09-25 16:30:14 -04:00
Clayton Coleman
a5ed10235e
Merge pull request #1354 from lavalamp/eventing
...
Add Event to api types
2014-09-25 16:20:49 -04:00
Daniel Smith
283eaf3931
Add new Event type
...
* replaces previous Event type, which is too limited.
* Remove writing of old event type.
* Fix serialiazation test to automatically test all types.
2014-09-25 11:31:35 -07:00
Brendan Burns
431caa93df
Merge pull request #1335 from dchen1107/exit1
...
Convert existing kubernetes system to use ContainerStatus, instead of
2014-09-24 21:37:24 -07:00
Daniel Smith
bb0cd95a83
fix non-gofmt'd things
2014-09-24 14:27:10 -07:00
Dawn Chen
0e6ec3cbfc
Convert existing kubernetes system to use ContainerStatus, instead of
...
docker.Container directly.
Conflicts:
pkg/kubelet/dockertools/docker.go
pkg/registry/pod/rest.go
2014-09-24 11:16:46 -07:00
jhadvig
d2709ab9c1
Typo fix
2014-09-24 01:33:39 +02:00
Daniel Smith
f211e46f20
handle watch errors everywhere
2014-09-22 17:37:12 -07:00
Tim Hockin
0f9cd4301d
Merge pull request #1401 from jhadvig/k8s_log_retrieval_update
...
stdout/stderr writer container log stream
2014-09-22 16:38:11 -07:00
jhadvig
9ba71528e4
stdout/stderr container log stream
2014-09-23 00:15:36 +02:00
Tim Hockin
486dbd165f
Merge pull request #1318 from jhadvig/k8s_log_retrieval
...
Adding endpoint for log retrieval on the minion
2014-09-22 13:21:28 -07:00
Eric Paris
a32400f47f
Remove all code dealing with cadvisor Percentiles
...
This was removed upstream beween cadvisor 0.3.0 and 0.4.0
2014-09-22 14:22:40 -04:00
jhadvig
960f1b2693
Consistency update
2014-09-21 22:25:44 +02:00
jhadvig
9f34eaef9e
kubelet server test cases
2014-09-18 14:17:10 +02:00
jhadvig
f3f5d0200c
Using podID+containerName for querying the logs
2014-09-17 21:00:09 +02:00
Dave Bailey
14fcf68edc
Improve error detection for URL manifests, and skip parsing if content unchanged.
2014-09-17 17:43:44 +00:00
Brendan Burns
dc5a4a8c3f
Refactor to clean up names.
2014-09-16 15:19:02 -07:00
erictune
506f51b186
Merge pull request #1330 from brendandburns/privilege
...
Only allow privileged containers if API server flag set. Adds capabilities package.
2014-09-16 15:12:26 -07:00
Clayton Coleman
61e3ce7ddc
Make runtime less global for Codec
...
* Make Codec separate from Scheme
* Move EncodeOrDie off Scheme to take a Codec
* Make Copy work without a Codec
* Create a "latest" package that imports all versions and
sets global defaults for "most recent encoding"
* v1beta1 is the current "latest", v1beta2 exists
* Kill DefaultCodec, replace it with "latest.Codec"
* This updates the client and etcd to store the latest known version
* EmbeddedObject is per schema and per package now
* Move runtime.DefaultScheme to api.Scheme
* Split out WatchEvent since it's not an API object today, treat it
like a special object in api
* Kill DefaultResourceVersioner, instead place it on "latest" (as the
package that understands all packages)
* Move objDiff to runtime.ObjectDiff
2014-09-16 16:26:43 -04:00
Clayton Coleman
fe614aeda2
Simple refactor for ease of readability
...
runtime.DefaultCodec -> latest.Codec
2014-09-16 16:12:35 -04:00
Brendan Burns
5b9e2a55b5
Add a flag to reject privileged containers in the apiserver.
2014-09-16 11:22:32 -07:00
jhadvig
6da2653b4a
Update according to review
2014-09-16 15:40:12 +02:00
jhadvig
f351691493
Adding endpoint for log retrieval on the minion
2014-09-15 17:02:56 +02:00
Brendan Burns
46d0cbd645
Add a global flag to enable/disable privileged containers
2014-09-12 09:56:45 -07:00
Dan Mace
3a3fab3f82
FEATURE: Support privileged containers in a pod
...
Add a Privileged field to containers in a pod, in order to facilitate pods
performing administrative tasks such as builds via Docker-in-Docker.
Discussion: https://github.com/GoogleCloudPlatform/kubernetes/issues/391
2014-09-12 09:38:11 -07:00
Brian Waldon
2f87857b0f
kubelet: generate keyring from .dockercfg
2014-09-11 21:01:39 -07:00
Brian Waldon
0bf4fabc19
kubelet: move docker-related code into sub-package
2014-09-11 13:12:28 -07:00
Dawn Chen
b48834e198
Fix PodInfo to include last terminated container info when calling
...
GetPodInfo based on name and UUID. With this fix, if some of containers
are dead, the pod status will stay as Running, not reset back to Waiting.
2014-09-10 14:41:18 -07:00
Tim Hockin
4ff76add57
Merge pull request #1147 from dchen1107/restart
...
Introduce the simplest RestartPolicy and handling.
2014-09-09 14:44:42 -07:00
Dave Bailey
5ec748dc5e
avoid dumping error pages into error messages
2014-09-09 17:20:58 +00:00
Dawn Chen
15cab4d053
Introduce the simplest RestartPolicy and handling.
2014-09-08 22:41:38 -07:00
Dawn Chen
7ace5a3e83
Passing pod UUID to Kubelet.
2014-09-08 14:24:09 -07:00
Daniel Smith
1c2b65788d
Rename Codec and ResourceVersioner to add Default in front, to allow for types of those names
2014-09-07 22:19:24 -07:00
Tim Hockin
6ebe69a875
Merge pull request #1156 from brendandburns/api
...
Add support for the PostStart event handler.
2014-09-05 22:13:56 -07:00
Daniel Smith
7790961011
Rename Object to EmbeddedObject
2014-09-05 14:43:35 -07:00
Brendan Burns
d0884accd7
Add support for the PostStart event handler.
2014-09-05 12:37:57 -07:00
Daniel Smith
779de7361a
Merge pull request #1138 from bcwaldon/common-watch-code
...
Use shared watch code in kubelet etcd config
2014-09-03 23:47:09 -07:00
Brian Waldon
85bf7064bb
Use shared watch code in kubelet etcd config
2014-09-03 15:51:02 -07:00
Clayton Coleman
34c40e4e48
Errors should be part of api/errors, not apiserver
...
Renames constructor methods to be errors.New<name> which changed a few
places.
2014-09-03 17:16:00 -04:00
Daniel Smith
a63966e73c
Combine pkg/apitools and pkg/api/common and call the result pkg/runtime
2014-09-02 11:15:44 -07:00
Daniel Smith
099c8fd36f
Propagate rename; tests pass again.
2014-09-02 10:42:06 -07:00
Vojtech Vitek (V-Teq)
42c656501c
Add several missing pkg Godoc files
...
Signed-off-by: Vojtech Vitek (V-Teq) <vvitek@redhat.com>
2014-09-02 13:41:11 +02:00
Vojtech Vitek (V-Teq)
59f58cd043
Unify Godoc formatting, fix various typos
...
Signed-off-by: Vojtech Vitek (V-Teq) <vvitek@redhat.com>
2014-09-02 13:41:03 +02:00
Daniel Smith
aa9b9b9fa8
Invert api and api/v1beta1 dependencies
...
This is some cleanup that has been needed for a while.
There's still one more step that could usefully be done, which is to
split up our api package into the part that provides the helper
functions and the part that provides the internal types. That can come
later.
The v1beta1 package is now a good example of what an api plugin should
do to version its types.
2014-08-29 12:15:30 -07:00
Dawn Chen
223fb6e610
Fixed kubelet /healthz by using healthz package
...
Fixed #1094
2014-08-28 15:34:39 -07:00
Daniel Smith
97b05619f1
Remove deprecated bits from kubelet
2014-08-26 22:39:00 -07:00
Brendan Burns
556eb0f400
Add a run command to the kublet server
2014-08-26 13:57:44 -07:00
Brendan Burns
4f1fa939f7
Switch the hostname in a container to be the pod id.
2014-08-26 11:13:53 -07:00
Daniel Smith
3ab35c63f3
Merge pull request #828 from roberthbailey/config
...
Add validation when processing pod manifests from a URL.
2014-08-21 14:34:25 -07:00
brendandburns
8f5dd8cf63
Merge pull request #984 from thockin/make_vs_new
...
Rename a bunch of "Make" functions to "New"
2014-08-20 22:06:57 -07:00
Tim Hockin
0f97a73c1b
Rename a bunch of "Make" functions to "New"
...
Also rename some to other names that make better reading. There are still a
bunch of "make" functions but they do things like assemble a string from parts
or build an array of things. It seemed that "make" there seemed fine. "New"
is for "constructors".
2014-08-20 21:27:19 -07:00
brendandburns
1bd4ae0c62
Merge pull request #943 from smarterclayton/only_wait_for_acceptance
...
Clients must wait for completion of actions
2014-08-20 21:01:21 -07:00
Clayton Coleman
493863eb93
Return immediately when controllers/pods are committed
...
Add client waiting conditions.
2014-08-20 18:46:10 -04:00
Clayton Coleman
34031dbc6a
Remove excessive waiting in kubelet etcd loop
...
Listen to etcd longer, and wait a shorter time before reconnecting.
No longer an argument to the source.
2014-08-20 18:46:10 -04:00
derekwaynecarr
fd8741edf2
Refactor kubelet to use http.ServeMux
2014-08-20 16:08:08 -05:00
Vishnu Kannan
2b61831c22
Improve kubelet logging - log the docker container image name when docker pull fails.
2014-08-20 10:30:42 -07:00
Dawn Chen
5a2365b323
Fix #926
...
Make HostPort a real option without being set to ContainerPort if absent.
2014-08-19 15:44:50 -07:00
Brendan Burns
0caae9c1d4
Add a in container exec based health check.
2014-08-18 12:00:11 -07:00
Robert Bailey
ce572050a8
Add tests for invalid container manifests.
2014-08-18 00:44:46 -07:00
Robert Bailey
fecfe23ed1
Refactor tests to be table driven.
2014-08-18 00:17:06 -07:00
Robert Bailey
9ce364d498
Add validation when processing pod manifests from a URL.
2014-08-17 22:50:53 -07:00
Tim Hockin
b9e65c2438
Use new api/errors, get rid of api.* error code
2014-08-15 00:14:38 -07:00
Daniel Smith
ab24790e8f
Fix go files with wrong boilerplate
2014-08-12 17:48:00 -07:00
Daniel Smith
1a5a22c539
Fix files missing gofmt
2014-08-12 17:48:00 -07:00
Brendan Burns
2986db9885
Add container hashing to the container name, and restart containers on changes.
2014-08-08 13:32:07 -07:00
Daniel Smith
2297bf8cea
Merge pull request #830 from brendandburns/net
...
Delete containers for a pod if we have to create the network container.
2014-08-08 13:12:42 -07:00
Brendan Burns
38900a9c58
Delete containers for a pod if we have to create the network container.
2014-08-08 12:34:59 -07:00
Victor Marmol
adc57da3f3
Merge pull request #825 from brendandburns/runin
...
Add support for "run in"
2014-08-07 23:47:19 -07:00
Brendan Burns
d31d0781b2
Add support for "run in"
2014-08-07 20:27:58 -07:00
Clayton Coleman
d7f46718a8
Kubelet should have a max think time before auto resync
...
The sync frequency should be part of the syncLoop and resync no
less often than every X seconds. The current implementation runs
even if a config update was delivered less than X seconds ago.
2014-08-07 10:40:03 -04:00
Danny Jones
7c28e0849f
Reorganization; Directory traversal less ugly
...
Directory traversal is no longer recursive and only goes as deep as it
needs to. Moved GetActiveVolumes to volume packages and added a simple
test.
2014-08-06 11:20:34 -07:00
Danny Jones
3f7f6cb2dc
Modifies tests to use new volume objects.
2014-08-06 10:21:59 -07:00
Danny Jones
6191ffc0de
Modifies directory walker to use a regex
...
Now a regex is used to determine active volume properties from
their directory paths.
2014-08-06 10:21:59 -07:00
Danny Jones
47bca30edc
Splits volume interface into Builders and Cleaners
...
Different information is needed to perform setup versus teardown. It
makes sense to separate these two interfaces since when we call teardown
from the reconciliation loop, we cannot rely on having the
information provided by the api definition of the volume.
2014-08-06 10:21:59 -07:00
Danny Jones
dfc9cb86f0
Initial reconciliation loop.
...
Determines the set of active volumes versus the set of valid volumes
defined by the manifests. If there is an active volume that is not
defined in any of the manifests, deletes and cleans up that volume.
2014-08-06 10:21:59 -07:00
Kouhei Ueno
22522cd003
PodConfigListener is never used
2014-08-06 06:43:16 +09:00
brendandburns
d4860c21a9
Merge pull request #752 from smarterclayton/remove_expect_no_error_util
...
Remove expectNoError from client, kubelet, and util
2014-08-04 09:15:22 -07:00
Clayton Coleman
f7149926c0
Remove expectNoError from client, kubelet, and util
2014-08-04 09:39:06 -04:00
Clayton Coleman
10564e447b
Generate valid file Pod Names and test for them
...
Ensure that pods coming from the unit test configuration validate,
and that proper names are generated.
Lowercases source filenames, strips all but a-z0-9, and tests
for consistent results.
2014-08-03 18:46:59 -04:00
Brendan Burns
490bb28bf9
Add TCP socket based health checking.
2014-08-01 14:13:56 -07:00
Dawn Chen
2e8020be8c
Update the entire cAdvisor package. There is a version mismatch issue
...
which cause #707
2014-07-31 10:11:25 -07:00
Dawn Chen
76ec7acf91
bump(github.com/google/cadvisor): bdd574b728e8a1e5eb08649d631197620dd09650
2014-07-31 09:14:04 -07:00
Francisco Souza
2a345ffa9e
third_party: update go-dockerclient
...
math.MaxInt64 represents 8 exabytes, which is a good limit for memory.
Also, this is the type used by Docker, so it's not possible to get any
value bigger than math.MaxInt64 as memory limit (both ram and swap) on a
Docker container.
Relevant discussion at #589 (more precisely,
https://github.com/GoogleCloudPlatform/kubernetes/pull/589#issuecomment-50640605 ).
2014-07-30 15:18:42 -03:00
brendandburns
b0d18b2af0
Merge pull request #571 from lavalamp/master
...
Decode/Encode everywhere
2014-07-29 17:19:33 -07:00
Rohit Jnagal
fbd3e85e9c
Fix handling of default cpu shares.
2014-07-29 18:34:16 +00:00
Daniel Smith
31a78c3e2b
Merge pull request #619 from brendandburns/controller
...
Make individual controller actions asynchronous.
2014-07-28 15:35:19 -07:00
Brendan Burns
1a3e4f8baf
Add some more synchronization.
2014-07-28 15:05:39 -07:00
Daniel Smith
b3cc696486
All types stored in etcd are now API objects.
...
This means I made an api.ContainerManifestList, and added a JSONBase to
endpoints (and changed Name -> JSONBase.ID).
2014-07-28 11:27:36 -07:00
Clayton Coleman
4ee3deaaf7
Merge pull request #647 from kelseyhightower/fix_extra_test_flags
...
Remove extra test flags from all commands
2014-07-28 12:58:57 -04:00
Dan McPherson
c4f4f69b93
Fixing Typos
2014-07-28 15:56:20 +02:00
Kelsey Hightower
87fa19cdfe
Remove extra test flags from all commands
...
Currently all commands are being build with extra flags. The extra
flags appear because of a direct import of the testing package from
the fake_etcd_client.go source file.
Remove the direct import of the testing package. Add a tools.T
interface to support existing behavior. Also clean up two TODO items
by remove using of the expectError and expectNoError functions.
Fixes #579
2014-07-27 14:19:18 -07:00
Daniel Smith
8881adc905
Merge pull request #606 from jonboulle/master
...
assorted formatting and typo fixes
2014-07-24 15:25:08 -07:00
Jonathan Boulle
c43035088b
assorted formatting and typo fixes
2014-07-24 15:10:36 -07:00
Daniel Smith
5ae20f9edb
Merge pull request #605 from Sarsate/setup-error
...
SetUp now returns an error.
2014-07-24 14:13:22 -07:00
Danny Jones
1117da4a55
SetUp now returns an error.
...
SetUp returns an error, kubelet now skips pod if error occurs.
2014-07-24 13:53:44 -07:00
Victor Marmol
b131da1cf5
Sync pods asynchronously in the Kubelet.
...
This makes two main changes:
- Runs syncPod in a separate Go routine (and enforces only one of those
runs at a time).
- Uses the pod list to determine if a container should be running or
should be killed (used to use the output of syncPod).
Since Docker pulls are synchronized by the Docker daemon we still block
on that, but pods can now be removed and prepared for starting without
blocking on long pulls.
2014-07-24 13:47:51 -07:00
Daniel Smith
41eb15bcff
Merge pull request #527 from Sarsate/rootdir-flag
...
Adds a flag to specify root working directory.
2014-07-24 13:12:55 -07:00
Danny Jones
bfa4642055
Adds a flag to specify root working directory.
...
--root_dir specifies the directory kubelet will use for it's
procedures. Currently used for volume mounts.
2014-07-24 13:04:05 -07:00
Daniel Smith
65575953c0
Merge pull request #589 from monnand/update-docker-client
...
update github.com/fsouza/go-dockerclient
2014-07-23 18:00:24 -07:00
Nan Deng
ea4224cbe7
update github.com/fsouza/go-dockerclient
2014-07-23 17:42:03 -07:00
Vojtech Vitek (V-Teq)
1f78b0fc6f
Fix reslice and data races in kubelet fake_docker_client
...
- Fix reslice in Pull() to remove the just returned error
- Fix data races found during the integration testing
- Remove one-liner helper method for better readability
2014-07-23 20:44:42 +02:00
Daniel Smith
ec0f639a21
Merge pull request #551 from erictune/private_kubelet
...
Private kubelet
2014-07-22 18:58:43 -07:00
Clayton Coleman
bc0ac1e81b
Kubelet etcd watch skipping indices
...
The next index to watch should always be current+1 if we got a
response from etcd, but otherwise it should always be current.
Moved the increment into fetchNextState which returns the next
index to watch for (or the same if an error occurs)
2014-07-22 20:24:18 -04:00
Eric Tune
ded67ead1e
Make Kubelet type members private and provide New functions.
2014-07-22 14:40:59 -07:00
Clayton Coleman
7767c2a2ac
Switch the Kubelet to use kubelet/config
...
Also transfer the Kubelet from using ContainerManifest.ID to source specific
identifiers with namespacing. Move goroutine behavior out of kubelet/ and
into integration.go and cmd/kubelet/kubelet.go for better isolation.
2014-07-21 21:27:26 -04:00
Clayton Coleman
09294b90ce
Refactor Kubelet config sources for clarity
...
Create a new "Pod" concept which can identify pods from
many config sources.
2014-07-21 21:18:36 -04:00
Daniel Smith
f672edd1cf
Merge pull request #457 from dchen1107/minionlogs
...
Add support to query kubelet's logs and cadvisor's stats through apiserver by passing rawquery
2014-07-21 16:02:44 -07:00
Daniel Smith
3f33bf78c5
Merge pull request #539 from vmarmol/pause
...
Add a pause image for the net container.
2014-07-21 15:47:39 -07:00
Dawn Chen
064237a5b8
Add support to query kubelet's logs and cadvisor's stats through
...
apiserver by passing rawquery.
minor changes
Fixed a minor rebase issues.
Using ioutil.ReadAll instead of httputil.DumpResponse
2014-07-21 11:52:32 -07:00
Victor Marmol
88317efb42
Add a pause image for the net container.
...
The pause image is a 240KB image that simply pauses waiting on a signal.
Use this for the net container which only needs to act as a placeholder.
Current net image is ~2.5MB. From my tests, this reduces startup time
for the net container from ~14s to ~6s.
2014-07-21 10:28:49 -07:00
Kelsey Hightower
67efa0a53a
Add test cases for Docker image name parsing and cleanup
...
The tests for Docker image name parsing are repetitive and do not
cover enough test cases.
Refactor the tests to use table testing and add additional test cases.
2014-07-20 19:22:54 -07:00
Victor Marmol
0a2b1bf644
If no tag was specified, pull "latest" explicitly.
...
When no tag is given to Docker pull, it downloads all tags. This could be a
significantly large number of images and in the end we only ever run
:latest.
2014-07-20 10:51:31 -07:00
Kelsey Hightower
dc7ee7c333
normalize -etcd_servers flag across all commands
...
The -etcd_servers flag is used inconsistently by the Kubernetes commands,
both externally and internally.
This patch fixes the issue by using the same type to represent a list of
etcd servers internally, and declares the -etcd_servers flag consistently
across all commands.
This patch should be 100% backwards compatible with no changes in behavior.
2014-07-20 07:48:47 -07:00
Daniel Smith
05f01a3654
Revert "assorted formatting and typo fixes"
2014-07-18 17:16:30 -07:00
Daniel Smith
211f6b312f
Merge pull request #520 from jonboulle/master
...
assorted formatting and typo fixes
2014-07-18 17:15:30 -07:00
Daniel Smith
d8faca9e81
Merge pull request #512 from smarterclayton/communicate_missing_pod_info
...
PodInfo should indicate when a pod is not found
2014-07-18 13:03:16 -07:00
Jonathan Boulle
9e63c3a633
assorted formatting and typo fixes
2014-07-18 13:02:59 -07:00
Tim Hockin
fda69bcca2
Merge pull request #452 from Sarsate/extvol-hostdir
...
Initial framework for external volumes.
2014-07-18 12:44:38 -07:00
Clayton Coleman
a17f0d04d4
PodInfo should indicate when a pod is not found
...
Client should react. Also, dial down the chattiness of errors for
pods which do not exist and stop processing NotFound earlier in
the podinfo chain
2014-07-18 13:32:10 -04:00
Daniel Smith
e9dbc4e8ad
Merge pull request #509 from xiangli-cmu/kubelet
...
kubelet: cleanup
2014-07-18 10:24:11 -07:00
Xiang Li
86288ca82a
kubelet: cleanup
2014-07-18 10:12:59 -07:00
Tim Hockin
2f593c92fa
Merge pull request #487 from yugui/fix/golint
...
Fixes Go lint errors and a style fix
2014-07-17 22:44:31 -07:00
Danny Jones
bb2843498d
API modified to use source; now supports EmptyDirectory
...
API is now modified to use a Source struct to handle multiple volumes.
Two volume types are supported now, HostDirectory and EmptyDirectory.
2014-07-17 15:25:50 -07:00
Nan Deng
564a58722c
Retrieve machine spec from cAdvisor
2014-07-17 15:21:47 -07:00
Clayton Coleman
15e791fc5b
Rename kubelet_server*.go to server*.go
2014-07-17 13:42:24 -04:00
Danny Jones
f84ff740f0
Adds initial volumes package; Supports host-dirs
...
Adds the framework for external volume mounts.
Currently supports bare host directory mounts.
Modifies the API to support host directory mounts from Volumes
instead of VolumeMounts.
2014-07-17 10:08:45 -07:00
Clayton Coleman
185a97b037
Make container lookup in the Kubelet cleaner
...
Reduce duplicate calls to list lookups for parallel go routines.
2014-07-16 14:12:13 -04:00
Yuki Sonoda (Yugui)
df9da65939
Rename a function according to go convention
2014-07-16 22:05:06 +09:00
Yuki Sonoda (Yugui)
d2db5cdffc
Fix a build failure of a test
2014-07-16 21:33:26 +09:00
Yuki Sonoda (Yugui)
c1eee00a57
Correct an error message
2014-07-16 21:33:26 +09:00
Yuki Sonoda (Yugui)
a702be8e63
Fixes new golint errors in pkg/kubelet after merge
2014-07-16 21:33:26 +09:00
Yuki Sonoda (Yugui)
07b8be4d4c
Merge branch 'master' into fix/golint2
...
Conflicts:
pkg/api/types.go
pkg/health/health_check.go
pkg/kubelet/kubelet.go
pkg/kubelet/kubelet_server.go
pkg/kubelet/kubelet_server_test.go
pkg/kubelet/kubelet_test.go
2014-07-16 21:33:21 +09:00
Daniel Smith
90afdb06c1
Move logger to own package; clean up apiserver to use serve mux.
2014-07-15 21:25:33 -07:00
Daniel Smith
c7d31fabbc
Merge pull request #480 from monnand/cadvisor-update-1
...
Update kubelet package to use most recent cAdvisor's code
2014-07-15 18:25:54 -07:00
Brendan Burns
c331849e69
Add support for CPU limiting to the kubelet.
2014-07-15 16:49:34 -07:00
Daniel Smith
3d63d733e3
Merge pull request #456 from brendandburns/health
...
Move health checking logic out to a utility. Add a minion registry that health checks.
2014-07-15 15:39:21 -07:00
Brendan Burns
c5db874090
Addressed comments.
2014-07-15 15:16:36 -07:00
Nan Deng
30bc2af9f1
gofmt -r "GetContainerStats->GetContainerInfo"
2014-07-15 11:53:00 -07:00
Nan Deng
8c573ee727
Update to latest cAdvisor and use data structures directly from cAdvisor
2014-07-15 11:53:00 -07:00
Clayton Coleman
e02ea37d9f
Move Docker specific function out of the Kubelet
2014-07-15 11:34:48 -04:00
Yuki Yugui Sonoda
edac5ce0b8
Fixes golint errors in pkg/kubelet
2014-07-15 22:56:31 +09:00
Yuki Yugui Sonoda
af38bf1ef7
Fixes golint errors in pkg/api
2014-07-15 22:56:09 +09:00
Clayton Coleman
07fafb1252
Merge pull request #453 from brendandburns/memory
...
Add support for memory limits in the kubelet.
2014-07-15 09:37:42 -04:00
Kouhei Ueno
bba23e28c2
Define EtcdErrorCode as constant and reuse EtcdError instances
2014-07-15 20:48:06 +09:00
Brendan Burns
62dfc74606
Move health checking logic out to a utility.
...
Add a minion registry that health checks.
2014-07-14 22:38:28 -07:00
Brendan Burns
92d83640c0
Add support for memory limits in the kubelet.
2014-07-14 20:57:26 -07:00
Brendan Burns
ae179121c6
Address comments.
2014-07-14 20:38:43 -07:00
Brendan Burns
9f99767b6c
Add a /healthz handler to the kubelet server, so that the master can validate kubelet health.
2014-07-14 20:38:18 -07:00
Yifan Gu
3a95572290
Changed the keepChannel to buffered channel.
...
Since the keepChannel is used to send data, not just for synchronizaiton,
so make it a buffered channel can avoid unnecessary goroutine yields.
2014-07-14 14:22:19 -07:00
Clayton Coleman
de51331808
Merge pull request #435 from claire921/kubelet_server
...
pkg/kubelet: clean up server http error handling
2014-07-12 14:35:36 -04:00
Claire Li
10de5b12fe
pkg/kubelet: explicitly return nil as error and nil as a result on error
2014-07-12 11:03:08 -07:00
Claire Li
cdc44387c6
pkg/kubelet: clean up server http error handling
2014-07-12 10:44:29 -07:00
Brendan Burns
1b4dfe7d14
Move from bool to HealthCheckStatus
2014-07-11 10:15:31 -07:00
Brendan Burns
6312ffebcf
Address some comments from thockin@
2014-07-11 10:14:45 -07:00
Tim Hockin
32bcdbeb53
Merge pull request #396 from brendandburns/hostname
...
Add Hostname to the docker run command.
2014-07-10 12:28:30 -07:00
Brendan Burns
dc61547b95
Add Hostname to the docker run command.
2014-07-10 12:25:57 -07:00
Yuki Sonoda (Yugui)
45b48e1668
Fixes golint errors in pkg/kubelet
2014-07-10 21:57:26 +09:00
Tim Hockin
b0b9606aea
Merge pull request #365 from brendandburns/health
...
add http health checks.
2014-07-09 16:14:30 -07:00
brendandburns
4c309862e3
Merge pull request #371 from thockin/valid3
...
Accumulate errors during validation
2014-07-09 13:36:37 -07:00
Tim Hockin
95fb7bc1ae
Merge pull request #379 from brendandburns/host
...
Add support for host up binding to the API (and kubelet)
2014-07-09 12:54:32 -07:00
Brendan Burns
41c6680943
add http health checks.
2014-07-09 12:01:43 -07:00
Dan Mace
00df67b0bf
Namespace "local" volume mounts by ContainerManifest ID on disk
...
Local volume mounts in a pod should result in host mounted directories
which are namespaced by the ContainerManifest ID.
2014-07-09 14:45:22 -04:00
Brendan Burns
4b22f7a462
Add support for host ip binding to the API (and kubelet)
2014-07-09 11:13:38 -07:00
Tim Hockin
54790080b3
Accumulate validation errors
...
Rather than report the first error, accumulate all errors and report them all
at once.
2014-07-09 07:55:15 -07:00
brendandburns
242627eaf0
Merge pull request #358 from thockin/valid2
...
Add validation of VolumeMounts
2014-07-08 21:58:32 -07:00
Dawn Chen
a0f94757a4
Instantiate cAdvisor client for kubelet to query both machine and container
...
information.
2014-07-08 16:37:43 -07:00
Tim Hockin
2eb2784725
Validation of HostPorts and Manifest IDs
...
Check that HostPorts are unique across the whole host and that Manifest IDs
are unique.
2014-07-08 15:22:47 -07:00
Tim Hockin
ad88fa48a5
Add validation of Ports
...
Also do caseless compares for "enum" strings.
2014-07-08 15:22:44 -07:00
Tim Hockin
92cf6662ed
Merge pull request #351 from discordianfish/use-api-for-pull
...
Use api for pulling images instead of shelling out
2014-07-08 09:08:12 -07:00
Johannes 'fish' Ziemke
3fa6c9671d
Use docker client lib instead of binary for pulls
2014-07-08 12:21:39 +02:00
Nan Deng
aa808a6505
fix data race introduced by 1798e0f
2014-07-02 23:23:14 -07:00
brendandburns
bf44347340
Merge pull request #350 from brendandburns/async
...
Fix an error in the async-path that led to dropping pods.
2014-07-02 23:15:35 -07:00
Brendan Burns
0655370ea2
Fix an error in the async-path that led to dropping pods.
2014-07-02 23:05:30 -07:00
brendandburns
d386c02dfd
Merge pull request #328 from monnand/root-container
...
Get root container stats from cAdvisor
2014-07-02 22:57:28 -07:00
Nan Deng
42fd4383a1
Get machine stats from cAdvisor
2014-07-02 16:59:50 -07:00
Daniel Smith
3b9735d787
Test atomic PUTs, and make them work.
...
Improve apiserver/logger.go's interface (it's pretty cool now).
Improve apiserver's error reporting to clients.
Improve client's handling of errors from apiserver.
Make failed PUTs return 409 (conflict)-- http status codes are amazingly
well defined for what we're doing!
2014-07-02 15:42:05 -07:00
Daniel Smith
a6144f656c
Move etcd helpers to tools package so they can depend on api package. Add ResourceVersion, hook it up to etcd index to get atomic PUTs.
2014-07-02 15:42:05 -07:00
Tim Hockin
d3da6b168e
nit: s/Id/ID/ for go style
2014-07-02 11:21:29 -07:00
brendandburns
a8a0039a39
Merge pull request #335 from vmarmol/add-kubelet-new
...
Add a New() for Kubelet.
2014-07-01 22:16:24 -07:00
Victor Marmol
e29ff512fc
Add a New() for Kubelet.
...
This will make it easier to add new fields that need to be initialized. Also refactors tests to ease making fake Kubelets.
2014-07-01 19:23:26 -07:00
Daniel Smith
969586a214
Add logging, fix crash
...
Crash was in kublet_server when fake docker client gives it nil pointer.
2014-07-01 17:38:07 -07:00
Daniel Smith
587fb75a7a
rearrange RunKubelet's parameters so that address and port are next to each other
2014-07-01 16:47:37 -07:00
Daniel Smith
11d6451d2a
Change kublet to serve podInfo instead of containerInfo. Plumb through system.
2014-07-01 16:41:10 -07:00
Daniel Smith
049bc6b6d4
Fix interface{} in api/types.go; plumb through system.
2014-07-01 16:41:09 -07:00
brendandburns
664c9faa43
Merge pull request #327 from lavalamp/etcdChanFix
...
Improvements to integration test & logging
2014-07-01 15:40:48 -07:00
brendandburns
ec01289aeb
Merge pull request #326 from thockin/valid2
...
First piece ofn actual validation
2014-07-01 15:40:13 -07:00
brendandburns
67eae1f645
Merge pull request #331 from dchen1107/cleanup
...
Fixed the data race found in kubelet_test.go
2014-07-01 15:30:36 -07:00
Dawn Chen
17bad028ce
Fixed the data race found in kubelet_test.go
2014-07-01 15:15:40 -07:00
Daniel Smith
b820e026f6
Improve logging.
2014-07-01 14:02:14 -07:00
Tim Hockin
a92e1aa1bf
First piece of validation
...
I'm adding pieces incrementally to make sure we get full testing of each
piece.
Make syncLoop() private
2014-07-01 13:48:57 -07:00
Brendan Burns
1798e0fea3
Make each pod synchronization async.
2014-07-01 12:20:13 -07:00
Brendan Burns
7999983311
Added async behavior.
2014-07-01 11:11:10 -07:00
Clayton Coleman
15c96508a9
Use ID instead of Id (go style) everywhere
...
Fixes #278
2014-07-01 13:16:47 -04:00
Tim Hockin
6c79937a42
Reduce logging noise
...
Don't use %#v for errors.
Do use %+v when more detail than %v is needed.
Fix typos Kublet -> Kubelet.
2014-06-28 22:16:26 -07:00
Justin Huff
28afe91855
Allow empty lists when polling manifests via http
2014-06-27 23:46:02 -07:00
Daniel Smith
b21facafb1
Merge pull request #273 from brendandburns/kubelet
...
Make the docker endpoint a flag.
2014-06-27 17:09:25 -07:00
Brendan Burns
f8060c5b3d
Make the docker endpoint a flag.
2014-06-27 17:01:12 -07:00
Daniel Smith
54ad4582e2
Fix unstable map ordering issue in test
2014-06-27 15:40:23 -07:00
Justin Huff
8c5562ef77
DockerContaineId->DockerId
2014-06-27 14:03:50 -07:00
Justin Huff
81663fdb80
Introduce a type for docker container ids
2014-06-27 14:03:50 -07:00
Justin Huff
fe0066d2e4
Cleaning up container ID handling inside kubelet
2014-06-27 14:03:50 -07:00
Brendan Burns
78d9538358
Set id width at 8 and pad with zeros.
2014-06-26 19:24:12 -07:00
Justin Huff
6fdebd6560
Watch and Get on the same Etcd key.
...
Kubelet was killing existing pods when creating a new one because new
files were being set as /registry/hosts/<machine>/pods/<id> and
/registry/hosts/<machine>/kubelet.
2014-06-26 18:59:49 -07:00
Daniel Smith
be39c3d646
Fix crash in test
2014-06-26 16:56:02 -07:00
Daniel Smith
001b07b292
Use net.JoinHostPort
2014-06-26 16:20:37 -07:00
Tim Hockin
3f0e7e790b
Less verbose logging for "normal" things.
...
Don't log things that we expect to happen every sync loop, unless the user
asks for --v > 0.
2014-06-24 22:05:25 -07:00
Tim Hockin
9f9e75f508
Switch to glog for logging, bridge logging to glog.
...
1) imported glog to third_party (previous commit)
2) add support for third_party/update.sh to update just one pkg
3) search-and-replace:
s/log.Printf/glog.Infof/
s/log.Print/glog.Info/
s/log.Fatalf/glog.Fatalf/
s/log.Fatal/glog.Fatal/
4) convert glog.Info.*, err into glog.Error*
Adds some util interfaces to logging and calls them from each cmd, which
will set the default log output to write to glog. Pass glog-wrapped
Loggers to etcd for logging.
Log files will go to /tmp - we should probably follow this up with a
default log dir for each cmd.
The glog lib is sort of weak in that it only flushes every 30 seconds, so
we spin up our own flushing goroutine.
2014-06-24 20:51:57 -07:00
Justin Huff
ddf0fd18f0
Remove extractMultipleFromReader and extractSingleFromReader. Unused now after improvements in #212 and #213
2014-06-24 18:59:57 -07:00
brendandburns
8b44f34e0f
Merge pull request #213 from lavalamp/fix_manifest
...
Better fix of #212
2014-06-24 17:42:22 -07:00
Daniel Smith
f7968ce00b
Make integration test the manifest url feature. Make kubelet's docker pull command testable.
2014-06-24 16:57:35 -07:00
Daniel Smith
fd66a8b59b
Readability fixes & address review comments.
2014-06-24 15:16:21 -07:00
Daniel Smith
6900431b13
Add kubelet testing to integration test. Test that kubelet makes the requested containers. Check that the url manifest feature works.
2014-06-24 15:14:40 -07:00
Daniel Smith
9d8a16f180
Make manifest url reader accept both single and multiple manifests.
2014-06-24 15:13:18 -07:00
Tim Hockin
c705593b62
Logging cleanup in Kubelet
...
Make it easier to see the signal when looking at kubelet logs. Make the
signal more consistent and legible.
2014-06-24 13:50:08 -07:00
Tim Hockin
7622bb871b
Rename Kubelet.Client -> EtcdClient
...
All the other *Client members are so named. Makes easier reading.
2014-06-24 13:17:38 -07:00
Justin Huff
4f714dd0fe
Ignore files that start with '.' when processing a config dir.
2014-06-24 12:02:49 -07:00
Tim Hockin
8c2a8b65c3
Escape manifest IDs when hunting the network container.
...
This makes it possible to have manifests with _ in the ID. I'm not sure we
want to allow this, but we do for now. I hope to follow this up with a deeper
change to make this a bit more robust.
2014-06-24 09:52:43 -07:00
brendandburns
e811e24b23
Merge pull request #216 from thockin/logging
...
Minor: log cleanups
2014-06-23 22:38:06 -07:00
Tim Hockin
60ad86c972
Minor: Log cleanups
...
Clean up log messages to be more obvious. Fix a typo (exit -> exist).
2014-06-23 22:11:18 -07:00
Tim Hockin
7218a4d165
Clarify config file code to be clear that it handles directories. ...
...
… Add a check for IsRegular() before reading a config path. Add a comment
about exec.Command("hostname", "-f").
2014-06-23 21:14:15 -07:00
Tim Hockin
228156dbc6
Remove noisy non-error lines from logs
2014-06-23 17:58:21 -07:00
Daniel Smith
77af24e7dc
manifest_url needs to take a single ContainerManifest.
2014-06-23 15:06:28 -07:00
Daniel Smith
b850d36166
Fix boilerplate everywhere
2014-06-23 11:32:11 -07:00
Daniel Smith
14e18a5308
Fix missing <-
2014-06-22 11:15:10 -07:00
Justin Huff
1441a84673
Cleanup handling of config channels in RunSyncLoop by passing a map
...
instead of a bunch of vars.
2014-06-22 09:32:49 -07:00
Justin Huff
460821e370
Add a k8s prefix to docker containers that we manage
2014-06-21 13:30:10 -07:00
Justin Huff
ecf7d11477
Make config dir handling deterministic
2014-06-20 09:31:52 -07:00
Justin Huff
d5bf045a6c
Make sure that config files are closed properly
2014-06-20 09:31:52 -07:00
Justin Huff
d204f76484
Add config dir support to kubelet
2014-06-20 09:31:52 -07:00
Justin Huff
f49b9c2429
Fix merge conflicts
2014-06-20 09:31:18 -07:00
Daniel Smith
8a13e5300d
Merge pull request #182 from brendandburns/net
...
Update IP assignment to be per-pod, not per-container
2014-06-20 09:06:34 -07:00
Brendan Burns
b46d8d2337
Merge branch 'net' of https://github.com/brendandburns/kubernetes-1 into net
2014-06-20 09:01:17 -07:00
brendandburns
3a9a3b1114
Merge pull request #174 from monnand/kubelet-cadvisor
...
Letting kubelet retrieve container stats from cAdvisor
2014-06-20 08:36:22 -07:00
brendandburns
0c8d556afb
Fix IP affinity to be per-pod, not per-container.
2014-06-19 23:09:21 -07:00
brendandburns
168ec29f54
Merge pull request #178 from vmarmol/add-external-mounts
...
Adding support for external mounts
2014-06-19 21:28:40 -07:00
Nan Deng
a10a64856d
use json.Marshal directly
2014-06-20 04:21:57 +00:00
Victor Marmol
e794f539d8
Adding support for external mounts
2014-06-19 21:14:19 -07:00
Nan Deng
7c7dfe3eeb
style
2014-06-20 04:06:28 +00:00
Brendan Burns
ae9fce1358
Fix the container manifest to so that Command is an array, not a string.
2014-06-19 20:21:20 -07:00
Nan Deng
865ba190ff
write headers after error checking
2014-06-19 22:28:48 +00:00
Nan Deng
979f832a0c
write StatusOK to the header after json.Encode()
2014-06-19 22:12:32 +00:00
Nan Deng
d001110df1
gofmt -s -w -l
2014-06-19 20:59:20 +00:00
Nan Deng
2cc3a88411
unit test for GetContainerStats()
2014-06-19 20:44:53 +00:00
Nan Deng
1b9cb5d501
more unit test
2014-06-19 20:44:53 +00:00
Nan Deng
b01a12fe34
more unit test for GetContainerStats()
2014-06-19 20:44:53 +00:00
Nan Deng
3080262f12
unit test for cadvisor
2014-06-19 20:44:53 +00:00
Nan Deng
c7eaa2095c
GOPATH...
2014-06-19 20:44:52 +00:00
Nan Deng
037cfd257f
add /containerStats
2014-06-19 20:44:52 +00:00
Nan Deng
2402e939c2
Add cAdvisor into third_party
2014-06-19 20:44:52 +00:00
Daniel Smith
bc02b3c21a
Rename [label] query to selector
2014-06-19 13:31:42 -07:00
Daniel Smith
7e464aa55c
Test controller's synchronize method. Requires fake etcd client to be relocated.
2014-06-18 13:10:39 -07:00
Daniel Smith
65d6280936
Move etcd helper to util so it can be used elsewhere, too
2014-06-18 13:10:39 -07:00
Brendan Burns
76148dc85f
gofmt
2014-06-15 21:57:29 -07:00
Brendan Burns
2e68d087a9
Add udp support.
2014-06-15 21:19:35 -07:00
Brendan Burns
482a360f9e
Make all error strings lower case, for readability.
2014-06-13 15:45:19 -07:00
Brendan Burns
d393838dfd
Only manage containers with '--' in the name.
2014-06-13 12:09:48 -07:00
Brendan Burns
164160adef
Address package level comments for readability.
2014-06-12 20:26:12 -07:00
brendandburns
f053a49988
Merge pull request #71 from brendandburns/container_info
...
Fix some problems in container info handling if the container's no present.
2014-06-12 20:17:05 -07:00
Joe Beda
353698558d
gofmt -s -w cmd/ pkg/
2014-06-12 18:34:47 -07:00
Brendan Burns
b05bc22a62
Refactor the kubelet for testability.
...
Add unit tests. Test coverage to 56.9%
2014-06-12 14:44:46 -07:00
Johan Euphrosine
4f6bed03ae
gofmt -s pkg/ cmd/
2014-06-12 14:16:19 -07:00
Brendan Burns
c36a7896fd
Added a comment explaining the function.
2014-06-12 11:27:50 -07:00
Daniel Smith
69acbf5a74
Fix build
2014-06-12 09:35:04 -07:00
Daniel Smith
7c17db672e
Move hostname detection logic to allow replacement
2014-06-12 09:35:04 -07:00
Brendan Burns
d83f407e43
Fix tests.
2014-06-09 16:50:44 -07:00
Brendan Burns
62f6291377
Fix a bug if the container is non-existent.
2014-06-09 16:45:17 -07:00
Brendan Burns
6018497174
Task -> Pod part #3
2014-06-08 22:38:45 -07:00
brendandburns
139be599e9
Merge pull request #25 from lavalamp/rename_kl
...
Change 'this' varable to more sensible abbreviation
2014-06-08 20:38:32 -07:00
Daniel Smith
62aba06180
Change 'this' varable to more sensible abbreviation
2014-06-08 20:35:07 -07:00
Daniel Smith
c3c739d6b4
Fix spelling
2014-06-08 19:48:04 -07:00
Daniel Smith
19343c6014
Add test to kubelet, coverage up to 37%
2014-06-08 16:10:29 -07:00
Joe Beda
2c4b3a562c
First commit
2014-06-06 16:40:48 -07:00