Commit Graph

604 Commits

Author SHA1 Message Date
gmarek
d27ad5b714 Controller codebase refactoring 2015-08-03 17:06:25 +02:00
Muhammed Uluyol
4b334a90ba Add a simple diurnal controller.
The diurnal controller changes the number of replicas of a replication controller based on a list of times and replica counts. It is meant to be run under a replication controller.
2015-07-31 17:27:09 -07:00
Mike Danese
cf4cb1a6a3 Merge pull request #10474 from kargakis/scale-multiple-controllers
Enable scaling multiple controllers
2015-07-31 14:51:43 -07:00
Mike Danese
6be29336ee Merge pull request #12096 from mesosphere/km-minion
Add Mesos hyperkube minion server (fixed quick-release)
2015-07-31 13:15:08 -07:00
Mike Danese
a23ee556ad Merge pull request #11999 from brendandburns/attach2
Add support for attach to kubectl
2015-07-31 12:51:08 -07:00
Dr. Stefan Schimanski
76dc61bcfb Revert "Revert "Add Mesos hyperkube minion server ""
This reverts commit 8372b0d927.
2015-07-31 20:33:04 +02:00
Mike Danese
8372b0d927 Revert "Add Mesos hyperkube minion server " 2015-07-31 10:47:42 -07:00
Brendan Burns
c9bc1456ff Add session affinity flags to kubectl expose 2015-07-31 10:34:52 -07:00
Mike Danese
464e208f95 Merge pull request #11928 from mesosphere/km-minion
Add Mesos hyperkube minion server
2015-07-31 10:25:21 -07:00
Dr. Stefan Schimanski
c4d6f75e35 Disable private mount ns for now in Mesos hyperkube minion server
Until Docker learns parent mount namespace customization the container will
always have the root ns as a parent, not the one of the km minion. Hence, the
kubelet (which lives in the km minion mount ns) will create mounts that cannot
be seen by the Docker containers.

This feature can be enabled again when Docker learns to explicitly set the
parent mount ns, in analogy to the parent cgroup.
2015-07-31 12:28:41 +02:00
Dr. Stefan Schimanski
2b1ecd28f0 Add Mesos hyperkube minion server
The minion server will
- launch the proxy and executor
- relaunch them when they terminate uncleanly
- logrotate their logs.

It is a replacement for a full-blown init process like s6 which is not necessary
in this case.
2015-07-31 12:28:40 +02:00
Dr. Stefan Schimanski
1200125137 Share KM_* constants 2015-07-31 11:27:52 +02:00
Dr. Stefan Schimanski
0ebf1811f3 Add scheduler flag --executor-proxy-logv 2015-07-31 11:27:52 +02:00
kargakis
0e796ca09a Enable scaling multiple controllers 2015-07-31 10:24:59 +02:00
Dr. Stefan Schimanski
f59b5f503b Use BindingHostKey annotation to detect scheduled pods in k8sm-scheduler
Before NodeName in the pod spec was used. Hence, pods with a fixed, pre-set
NodeName were never scheduled by the k8sm-scheduler, leading e.g. to a failing
e2e intra-pod test.

Fixes mesosphere/kubernetes-mesos#388
2015-07-31 10:22:20 +02:00
Mike Danese
51a7a38f67 Merge pull request #12020 from wojtek-t/move_to_storage
Move storage-related code to pkg/storage
2015-07-30 16:23:03 -07:00
Mike Danese
ed9975b031 Merge pull request #11230 from mesosphere/resource-accounting
Implement resource accounting for pods with the Mesos scheduler
2015-07-30 14:36:41 -07:00
Brendan Burns
97cb1cd071 Add support for attach to kubectl 2015-07-30 12:56:18 -07:00
Dr. Stefan Schimanski
f3f617d9db Update documentation about resource accounting 2015-07-30 21:18:15 +02:00
Dr. Stefan Schimanski
a2fa41b73f Implement resource accounting for pods with the Mesos scheduler
This patch

- set limits (0.25 cpu, 64 MB) on containers which are not limited in pod spec
  (these are also passed to the kubelet such that it uses them for the docker
  run limits)
- sums up the container resource limits for cpu and memory inside a pod,
- compares the sums to the offered resources
- puts the sums into the Mesos TaskInfo such that Mesos does the accounting
  for the pod.
- parses the static pod spec and adds up the resources
- sets the executor resources to 0.25 cpu, 64 MB plus the static pod resources
- sets the cgroups in the kubelet for system containers, resource containers
  and docker to the one of the executor that Mesos assigned
- adds scheduler parameters --default-container-cpu-limit and
  --default-container-mem-limit.

The containers themselves are resource limited the Docker resource limit which
the kubelet applies when launching them.

Fixes mesosphere/kubernetes-mesos#68 and mesosphere/kubernetes-mesos#304
2015-07-30 21:18:04 +02:00
Mike Danese
33278e7910 Merge pull request #11844 from brendandburns/queue
Add an initial (simple) implementation of a submit queue.
2015-07-30 11:36:28 -07:00
Wojciech Tyczynski
3cbbe72f9f Move etcd storage to pkg/storage/etcd 2015-07-30 15:42:06 +02:00
Mike Danese
e9a56d9d6b Merge pull request #11939 from derekwaynecarr/unit_file_updates
Update kube-apiserver unit files for systemd
2015-07-29 17:43:44 -07:00
Brendan Burns
9bec48298b Add an initial (simple) implementation of a submit queue. 2015-07-29 15:39:10 -07:00
Paul Morie
5394aa979f Make emptyDir volumes work for non-root UIDs 2015-07-29 18:36:51 -04:00
Mike Danese
bed0e1e1b0 Merge pull request #11915 from AnanyaKumar/controller-refactor
Refactor package controller
2015-07-29 11:20:14 -07:00
Mike Danese
e864569f80 Merge pull request #11003 from jayunit100/prom-push
[contrib + e2e] prometheus: add pushgateway functionality to prometheus allinone deployment along w/ runRC Gauge reporting.
2015-07-29 11:12:02 -07:00
Ananya Kumar
47dd0bc6f9 Refactor package controller 2015-07-29 09:54:35 -07:00
Mike Danese
60ac834563 Merge pull request #10652 from JanetKuo/kubectl-o-name
Add '-o name' to mutations
2015-07-29 09:46:10 -07:00
Brendan Burns
0c07b66226 Skip another flaky mesos test. 2015-07-28 15:18:21 -07:00
David Oppenheimer
bfb6203627 Merge pull request #11940 from brendandburns/e2e2
Disable a couple of flaky tests.
2015-07-28 21:31:53 +02:00
Brendan Burns
660efc7583 Disable a couple of flaky tests. 2015-07-28 11:42:39 -07:00
derekwaynecarr
e62c47db8c Update kube-apiserver unit files for systemd 2015-07-28 14:36:56 -04:00
jayunit100
739e79dd9f Modularized implementation of prompush json with e2e running pending push gateway gauges. 2015-07-28 09:29:57 -04:00
Janet Kuo
0e42d0699a Add '-o name' to mutations 2015-07-27 14:06:53 -07:00
Alex Robinson
60611c253e Add a resync period for services in the service controller.
This should ensure all load balancers get deleted even if a reordering of
watch events causes us to strand one after its service has been deleted,
because the sync will notice that the service controller's cache has a
service in it that no longer exists in the apiserver.

It could still leak in the case that the controller manager is killed
between when it leaks something and the sync runs, but this should
improve things.
2015-07-27 18:03:13 +00:00
Mike Danese
078ec7518b Merge pull request #11825 from aveshagarwal/ansible-fixes
Fixes ansible errors.
2015-07-24 18:51:00 -07:00
Avesh Agarwal
0d4851a4ef Ansible updates for Atomic. 2015-07-24 18:29:55 -04:00
Mike Danese
01349cdbfa Merge pull request #11786 from a-robinson/fluentd
Update fluentd-gcp images to include latest Dockerfile changes
2015-07-24 12:40:41 -07:00
Mike Danese
de6d870569 Merge pull request #11741 from jsafrane/devel/service-test
Use a service between e2e volume tests clients and servers.
2015-07-24 11:21:28 -07:00
Mike Danese
b51b4e740f Merge pull request #10639 from caseydavenport/master
Allow specification of a network plugins directory when starting kubelet
2015-07-24 11:09:11 -07:00
Mike Danese
f0d7f70838 Merge pull request #11264 from eparis/total-ansible
Ansible updates
2015-07-24 10:39:34 -07:00
Mike Danese
c70d8d4c59 Merge pull request #11108 from mesosphere/fix-10795
Fix races in mesos scheduler plugin test
2015-07-24 09:35:29 -07:00
Eric Paris
1253ca52cd Ansible: start to support debian 2015-07-24 09:58:31 -04:00
Eric Paris
a25b34e1a4 Ansible: Vagrant: allow passing ansible tags to vagrant provision
Creating a cluster from scratch takes about 7 minutes. But if you just
rebuild the binaries and want to update those you don't want to have to
rerun the entire thing. There is an ansible tag 'binary-update' which
will do that. Now one can do
```
ANSIBLE_TAGS=binary-update vagrant provision
```
And it will push the new binaries.
2015-07-24 09:58:31 -04:00
Eric Paris
8ba4d85fa9 Ansible: Add kube-ui kube-addon support 2015-07-24 09:58:31 -04:00
Eric Paris
217f8eef95 Ansible: convert DNS from kube_config_dir to kube_addons_dir 2015-07-24 09:58:31 -04:00
Eric Paris
9aed89f816 Ansible: fast update of binaries
If you are using locally build binaries as a developer you likely will
want to just push those binaries to an existing cluster, not rerun the
entire playbook.  Add a tag to do just that.
2015-07-24 09:58:31 -04:00
Jeff Bean
0653156e1e Ansible: Updating README 2015-07-24 09:58:31 -04:00
Jeff Bean
29980851f7 Ansible: Adding variable for kubernetes apiserver port 2015-07-24 09:58:31 -04:00
Jeff Bean
90b1318168 Ansible: Adding variable for kubernetes addon dir 2015-07-24 09:58:30 -04:00
Eric Paris
ce4d2d41fb Ansible: Vagrant: Add libvirt support 2015-07-24 09:58:30 -04:00
Eric Paris
51a33d3ff5 Ansible: vagrant: generic set_provider() function 2015-07-24 09:58:30 -04:00
Eric Paris
dda42add54 Ansible: Vagrant: Add vbox support 2015-07-24 09:58:30 -04:00
Eric Paris
36e991742b Ansible: Vagrant: Update to os1 vagrant scripts
Do the /etc/host creation with vagrant, so it uses internal instead of
external ips (hostmanager only knew about the public ip)

Ignore errors on docker failure when 'restarting' docker in flannel
handler. If this is a clean install, we haven't run 'node' yet so docker
isn't installed so it doesn't need to be started. It would be better to
be more specific in ignoring errors though...
2015-07-24 09:58:30 -04:00
jayunit100
a008fe24bb Ansible: Vagrant: kubernetes openstack deployer
vbox deployer separated and deprecated. Readded-later
2015-07-24 09:58:25 -04:00
Eric Paris
fd1024baa2 Install openssl when using make-ca-certs.sh
easyrsa requires openssl. So make sure it is installed.
2015-07-24 09:56:42 -04:00
Eric Paris
90ecd96f84 Ansible: Run from locally built binaries
Instead of from distro packages
2015-07-24 09:48:36 -04:00
Eric Paris
c3849fd240 Ansible: Minor typo in play text (no functional change) 2015-07-24 09:48:36 -04:00
Eric Paris
605437f811 Ansible: Support new upstream non-default namespace for addons 2015-07-24 09:48:35 -04:00
Eric Paris
165aa56c1a Ansible: Do not fail flannel restart is docker not installed
On first install flannel runs before docker is installed. So do not fail
if docker is not installed
2015-07-24 09:48:35 -04:00
Eric Paris
8b57cc8918 Ansible: cert gen: use inventory hostname not ip address 2015-07-24 09:48:35 -04:00
Alex Robinson
0889307522 Update the fluentd-gcp images to include their latest Dockerfile changes.
Their Dockerfiles were changed in #11768.
2015-07-24 01:27:42 +00:00
Alex Robinson
081466918e Update the fluentd sidecar example yaml files to use the 1.2 version.
I missed this in #11721.
2015-07-24 01:26:05 +00:00
Vish Kannan
2a5a6b99cb Merge pull request #10635 from smarterclayton/cloud_provider_should_err
Cloud provider should return an error
2015-07-23 17:50:45 -07:00
Vish Kannan
6306ad1bce Merge pull request #11736 from thockin/cleanup-dns-legacy
Stop populating legacy DNS names
2015-07-23 17:30:00 -07:00
Vish Kannan
2a10eabfdf Merge pull request #11769 from aveshagarwal/kubernetes-ansible-fixes
Fixes ansible syntax errors
2015-07-23 17:04:48 -07:00
Tim Hockin
89e9851ac5 Update examples to not use old DNS names 2015-07-23 13:51:09 -07:00
Casey D
db3650fe58 Fix missing network plugin directory argument. 2015-07-23 13:05:59 -07:00
Avesh Agarwal
e507dbe7b8 Fixed ansible syntax error. 2015-07-23 15:26:11 -04:00
Todd Derr
98ed2e8606 Remove gem update for fluent-plugin-google-cloud
This was originally submitted to pick up v0.3.1 of the cloud logging
plugin which had a fix for the name 'metadata' failing to resolve.
Since new releases of google-fluentd have this fix, it is no longer
required.

I've done some additional testing of 'gem update' behavior in the interim
and I think it is ok to use in targeted situations, but we should not be
doing an unconstrained update in general. The issue is that updating a
gem may bring new dependencies, some of those dependencies may include
native code, so it may try to launch a compiler, which isn't desirable
and prone to failure.

If we do need to grab an updated gem in the future we should specify an
explicit version and the --minimal-deps flag.
2015-07-23 15:06:56 -04:00
Vish Kannan
dfe1eb9b96 Merge pull request #11721 from a-robinson/fluentd
Bring sidecar fluentd configs in line with the addon fluentd configs
2015-07-23 11:49:32 -07:00
Alex Robinson
797dc1778a Add resource constraints to the fluentd container in the sidecar examples 2015-07-23 16:31:08 +00:00
Alex Robinson
7ac3d36030 Bring the sidecar fluentd configs in sync with the cluster addon configs. 2015-07-23 16:31:03 +00:00
Jan Safranek
118004c166 Use a service between e2e volume tests clients and servers.
This helps with routing of TCP traffic between clients and servers in case
flannel or similar service is not installed and pods don't see each other.


- It needs 'insecure' in /etc/exports to allow NFS clients on ports > 1024,
  Kubernetes service will change client port to a random number.

- glusterfs no longer needs explicit endpoint definition, it uses the service
  instead.
2015-07-23 11:51:43 +02:00
Wojciech Tyczynski
ee92aa3897 Prepare for extracting EtcdHelper interface 2015-07-23 09:37:39 +02:00
Wojciech Tyczynski
5988d30da0 Merge pull request #10715 from justinsb/spelling_octects
Spelling fix (in code): octects -> octets
2015-07-23 09:00:39 +02:00
krousey
f9fa83fae3 Merge pull request #10613 from mesosphere/mesos-docs
Move k8s-mesos docs to the kubernetes repo
2015-07-20 09:23:20 -07:00
David Oppenheimer
dec9adfe2e Replace ``shell with ``sh 2015-07-19 21:38:53 -07:00
Dr. Stefan Schimanski
8fca9b6f09 Add original k8s-mesos docs to contrib/mesos 2015-07-19 10:13:25 +02:00
Satnam Singh
69668365ce Update sidecar logging console output in docs 2015-07-18 22:47:42 +01:00
Eric Tune
f5e6161e49 Merge pull request #11298 from mesosphere/fix-10776
Fix deadlocks and race conditions in mesos master election notifier
2015-07-15 13:55:17 -07:00
Dr. Stefan Schimanski
e98c8e7685 Fix deadlocks and race conditions in mesos master election notifier
- n.node used the n.lock as underlaying locker. The service loop initially
  locked it, the Notify function tried to lock it before calling n.node.Signal,
  leading to a dead-lock.
- the go routine calling ChangeMaster was not synchronized with the Notify
  method. The former was triggering change events that the later never saw
  when the former's startup was faster that of Notify. Hence, not even a single
  event was noticed and not even a single start/stop call of the slow service
  was triggered.

This patch replaces the n.node condition object with a simple channel n.changed.
The service loop watches it.

Updating the notified private variables is still protected with n.lock against
races, but independently of the n.changed channel. Hence, the deadlock is gone.

Moreover, the startup of the Notify loop is synchronized with the go routine which
changes the master. Hence, the Notify loop will see the master changes.

Fixes #10776
2015-07-15 21:45:53 +02:00
Eric Tune
3dad5a0652 Merge pull request #10835 from mesosphere/mesos-root-ca-file
Add --root-ca-key code to Mesos controller-manager fork
2015-07-14 12:16:49 -07:00
Eric Tune
ed26ffe95e Merge pull request #10685 from jeffbean/ansible_dev
Ansible enhancements for CentOS
2015-07-14 12:08:06 -07:00
Dr. Stefan Schimanski
95c7dc8cb3 Re-enable mesos scheduler TestPlugin_LifeCycle test 2015-07-13 22:43:16 +02:00
Dr. Stefan Schimanski
143cf4b08d Use correct offer's hostname of test pods in mesos scheduler plugin tests 2015-07-13 22:41:23 +02:00
Dr. Stefan Schimanski
dd7345b25f Fix offer+pod races in mesos scheduler plugin test
- Offers were reused and led to unexpected declining by the scheduler because
  the reused offer did not get a new expiration time.
- Pod scheduling and offer creation was not synchronized. When scheduling
  happened after aging of offers, the first issue was trigger. Because
  the mesos driver DeclineOffer was not mocked this lead to a test error.
2015-07-13 22:41:23 +02:00
Dr. Stefan Schimanski
bf44f5df28 Add DeclineOffer return value to mock driver in mesos scheduler test
Depending on timing the mesos scheduler might call DeclineOffer:

The default ttl of an offer in mesos scheduler is 5sec. If the tests run longer,
the old, unused offers are declined, leading to an mock error.

Probably fixes GoogleCloudPlatform/kubernetes#10795
2015-07-13 22:41:23 +02:00
David Oppenheimer
089a703194 Disable TestPlugin_LifeCycle due to flakiness. 2015-07-10 22:14:16 -07:00
Brendan Burns
86f54b4d05 Merge pull request #11035 from nikhiljindal/nettest
Updating nettest image to latest code
2015-07-09 22:08:01 -07:00
nikhiljindal
90d371c98f Updating nettest image to latest code 2015-07-09 18:07:18 -07:00
Victor Marmol
5540570e44 Merge pull request #10925 from bprashanth/sidecar_exec
Sidecar container capable of servicing exec style liveness probes over http
2015-07-09 17:46:11 -07:00
Prashanth Balasubramanian
3ec6703a5d Create a sidecar container for use as an http-exec bridge 2015-07-09 15:00:25 -07:00
Alex Mohr
7737d18882 Update release notes tool and documentation 2015-07-07 17:40:10 -07:00
Dr. Stefan Schimanski
39b3af0fdc Add --root-ca-key code to Mesos' controller-manager fork 2015-07-07 18:19:47 +02:00
Satnam Singh
96c4e587ad Change config files to kube-system which were missed in the original PR 2015-07-07 01:05:19 -07:00
Justin Santa Barbara
1ece037555 Spelling fix (in code): octects -> octets 2015-07-04 10:37:57 -04:00
Jeffrey Bean
f7b5d0db61 [Ansible] Adding new CentOS repo for newest Kubernetes packages.
This is the game we play until Kubernetes GA packages are out.
2015-07-02 15:06:27 -07:00
Zach Loafman
acf6fc6e24 Merge pull request #10627 from eparis/total-ansible
Ansible: Get DNS working - Add kubectl kubeconfig file
2015-07-01 16:07:53 -07:00