Commit Graph

311 Commits (56dc8f9a6ab09debeddf5349ee26730d3e9107f8)

Author SHA1 Message Date
Kubernetes Submit Queue b940d14261 Merge pull request #46210 from xiangpengzhao/print-volume-info
Automatic merge from submit-queue

Add AzureFile,FC,Flex,Flocker volume source to describe printer.

**What this PR does / why we need it**:
Display other volume sources in describe printer.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:
Also need CephFS. It will be added in #46124 

/cc @rootfs 

_ADD: all the volume source printers are sorted out of order. I'd like to sort them alphabetically in order to be more readable in another PR after this PR merged. WDYT?_ 

**Release note**:

```release-note
NONE
```
2017-07-21 16:45:37 -07:00
Solly Ross f78d61e7c2 [client-go] Add dynamic.Interface
This adds an interface form of dynamic.Client and
dynamic.ResourceClient, making those two follow the general client
conventions: `Interface` is an interface, and `Client` is the concrete
implementation.  `ClientPool` retains it's interface status.

This allows us to create a fake implemenation of dyanmic.Interface,
dynamic.ResourceInterface, and dynamic.ClientPool for testing.
2017-07-21 14:24:06 -04:00
zhangxiaoyu-zidif 74d2aa4dee add namespace for describe pdb 2017-07-21 16:47:37 +08:00
David Ashpole 7a23f8b018 remove deprecated flags LowDiskSpaceThresholdMB and OutOfDiskTransitionFrequency 2017-07-20 13:23:13 -07:00
Kubernetes Submit Queue 8d26afa8a6 Merge pull request #48377 from bsalamat/priority_class
Automatic merge from submit-queue

Add PriorityClass API object under new "scheduling" API group

**What this PR does / why we need it**: This PR is a part of a series of PRs to add pod priority to Kubernetes. This PR adds a new API group called "scheduling" with a new API object called "PriorityClass". PriorityClass maps the string value of priority to its integer value.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**: Given the size of this PR, I will add the admission controller for the PriorityClass in a separate PR.

**Release note**:

```release-note
Add PriorityClass API object under new "scheduling" API group
```

ref/ #47604
ref/ #48646
2017-07-19 19:04:29 -07:00
zhangxiaoyu-zidif 8e0cc7ede2 add test case for pdb printer 2017-07-19 22:22:01 +08:00
xiangpengzhao abc7c4cf10 Add AzureFile,Flex,Flocker volume source to describe printer. 2017-07-19 10:42:27 +08:00
Kubernetes Submit Queue fc1d2b3be7 Merge pull request #48256 from xiangpengzhao/move-pkg-util
Automatic merge from submit-queue (batch tested with PRs 48481, 48256)

Refactor: pkg/util into sub-pkgs

**What this PR does / why we need it**:
- move code in pkg/util into sub-pkgs
- delete some unused funcs

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #15634

**Special notes for your reviewer**:
This is the final work of #15634. It will close that issue.
/cc @thockin 

**Release note**:

```release-note
NONE
```
2017-07-18 18:19:19 -07:00
Bobby (Babak) Salamat e827e1ba87 autogenerated files 2017-07-18 17:47:57 -07:00
Bobby Salamat 33e6a476ba Add PriorityClass API
Add PriorityClass to pkg/registry

Add PriorityClass to pkg/master/master.go

Add PriorityClass to import_know_versions.go

Update linted packages

minor fix
2017-07-18 17:47:57 -07:00
Kubernetes Submit Queue 89a1ce2c1f Merge pull request #48807 from jsafrane/fc-describe
Automatic merge from submit-queue (batch tested with PRs 46094, 48544, 48807, 49102, 44174)

Implement kubectl describe <fibre-channel PV>

kubectl did not show any details about Fibre Channel volumes, someone just forgot to implement it.

Tested with:

```shell
$ kubectl create -f - <<EOF
apiVersion: v1
kind: PersistentVolume
metadata:
  name: myfc
spec:
  capacity:
    storage: 100Gi
  accessModes:
    - ReadWriteOnce
  persistentVolumeReclaimPolicy: Delete
  fc:
       targetWWNs: ['500a0982991b8dc5', '500a0982891b8dc5']
       lun: 2
       fsType: ext4
       readOnly: true
EOF

$ kubectl describe pv myfc
Name:		myfc
Labels:		<none>
Annotations:	<none>
StorageClass:	
Status:		Available
Claim:		
Reclaim Policy:	Delete
Access Modes:	RWO
Capacity:	100Gi
Message:	
Source:
    Type:	FC (a Fibre Channel disk)
    TargetWWNs:	500a0982991b8dc5, 500a0982891b8dc5
    LUN:	2
    FSType:	ext4
    ReadOnly:	true
Events:		<none>
```

```release-note
NONE
```
@kubernetes/sig-cli-pr-reviews
2017-07-18 11:20:54 -07:00
Dr. Stefan Schimanski 39d95b9b06 deepcopy: add interface deepcopy funcs
- add DeepCopyObject() to runtime.Object interface
- add DeepCopyObject() via deepcopy-gen
- add DeepCopyObject() manually
- add DeepCopySelector() to selector interfaces
- add custom DeepCopy func for TableRow.Cells
2017-07-18 09:28:47 +02:00
xiangpengzhao 01daf707c5 Refactor: pkg/util into sub-pkgs 2017-07-18 14:34:08 +08:00
Jacob Simpson 29c1b81d4c Scripted migration from clientset_generated to client-go. 2017-07-17 15:05:37 -07:00
allencloud 389cd57014 remove duplicated word file in error
Signed-off-by: allencloud <allen.sun@daocloud.io>
2017-07-14 18:01:51 +08:00
Jan Safranek 09e241294f Implement kubectl describe <fibre-channel PV> 2017-07-12 12:34:43 +02:00
Kubernetes Submit Queue a9aabd76e7 Merge pull request #46017 from xilabao/fix-print-of-generic-resources
Automatic merge from submit-queue (batch tested with PRs 44412, 44810, 47130, 46017, 47829)

fix self link error of generic resources in describe command

**What this PR does / why we need it**:
fix Self Link error
```
./cluster/kubectl.sh describe clusterrole system:controller:ttl-controller
Name:		system:controller:ttl-controller
Namespace:	
Labels:		kubernetes.io/bootstrapping=rbac-defaults
Annotations:	rbac.authorization.kubernetes.io/autoupdate=true
API Version:	rbac.authorization.k8s.io/v1alpha1
Kind:		ClusterRole
Metadata:
  Creation Timestamp:	2017-05-18T06:42:02Z
  Resource Version:	80
  Self Link:		/apis/rbac.authorization.k8s.io/v1alpha1/clusterroles/system%!A(MISSING)controller%!A(MISSING)ttl-controller
  UID:			19a705a4-3b95-11e7-9d55-7427ea6f0fe3
Rules:
  API Groups:
    
  Resources:
    nodes
  Verbs:
    list
    patch
    update
    watch
  API Groups:
    
  Resources:
    events
  Verbs:
    create
    patch
    update
Events:	<none>
```

**Which issue this PR fixes**: fixes #48743

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-07-11 20:00:23 -07:00
deads2k 0801ded425 remove dead code 2017-07-07 09:12:29 -04:00
Kubernetes Submit Queue 1108738200 Merge pull request #48033 from smarterclayton/generic_printer
Automatic merge from submit-queue (batch tested with PRs 45467, 48091, 48033, 48498)

Refactor and simplify generic printer for unknown objects

The first two commits are part of other PRs

@kubernetes/sig-cli-pr-reviews part of the general refactoring for server side print
2017-07-05 12:37:33 -07:00
Kubernetes Submit Queue e16b59aa0a Merge pull request #45467 from ddysher/kubectl-describe-controllerRef
Automatic merge from submit-queue

Fix kubectl describe for pods with controllerRef

**What this PR does / why we need it**:

kubectl describe doesn't take controllerRef into consideration, resulting confusing result. e.g. if we have two replicaset with the same selector, one with 1 replica and the other 2 replicase, then both replicaset will show 3 running pods.

```sh
$ kubectl describe rs replicaset-2
Name:           replicaset-2      
Namespace:      default
Selector:       environment=prod
Labels:         environment=prod
Annotations:    <none>
Replicas:       2 current / 2 desired
Pods Status:    3 Running / 0 Waiting / 0 Succeeded / 0 Failed
Pod Template:
  Labels:       environment=prod
  Containers:
   created-from-replicaset:
    Image:              nginx
    Port:               
    Environment:        <none>
    Mounts:             <none>
  Volumes:              <none>
Events:
  FirstSeen     LastSeen        Count   From                    SubObjectPath   Type            Reason                  Message
  ---------     --------        -----   ----                    -------------   --------        ------                  -------
  5m            5m              1       replicaset-controller                   Normal          SuccessfulCreate        Created pod: replicaset-2-39szb
  5m            5m              1       replicaset-controller                   Normal          SuccessfulCreate        Created pod: replicaset-2-470jr
```


**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

xref #24946

**Special notes for your reviewer**:

**Release note**:

```release-note
Fix kubectl describe for pods with controllerRef 
```
2017-07-05 12:25:49 -07:00
Kubernetes Submit Queue e5419a56db Merge pull request #47162 from FengyunPan/display-none
Automatic merge from submit-queue (batch tested with PRs 47162, 48444, 48445)

Fix output extra comma

/# kubectl get service
NAME                     CLUSTER-IP       EXTERNAL-IP               PORT(S)          AGE
nginx-service-test       10.200.6.109     _**,80.11.12.10**_              8000:31637/TCP   6s
**(output a extra comma)**
except: 
nginx-service-test       10.200.6.109     _**80.11.12.10**_              8000:31637/TCP   6s

/# cat lb.yaml 
apiVersion: v1 
kind: Service 
metadata: 
  name: nginx-service-lb3
spec: 
  ports: 
    - port: 8000
      targetPort: 80 
      protocol: TCP 
  type: LoadBalancer
  selector: 
    name: nginx
  externalIPs: 
    - 80.11.12.10
    - 1.2.3.6
/# kubectl create -f lb.yaml
2017-07-05 06:39:27 -07:00
Clayton Coleman 6bd0c38908
Add a new default printer handler for HumanReadable
Refactors and removes the need for the more complex old code,
temporarily limits what output is shown for truly unknown objects (a
follow up change will allow server side handling and generic fallback),
and removes all of the generic printers in favor of a single code path.
2017-07-05 00:31:41 -04:00
Deyuan Deng c73b535d16 Fix kubectl describe for controllerRef 2017-07-01 18:45:23 +08:00
Kubernetes Submit Queue 5eccc7ae80 Merge pull request #48056 from luxas/kubeadm_remove_old_label
Automatic merge from submit-queue

Remove old node role label that is not used by kubeadm

**What this PR does / why we need it**:
This label hasn't been used by kubeadm since v1.5.
v1.5 support was dropped when v1.6 arrived due to a potential security flaw and the earlier alpha status.
So this label hasn't been used for around three months.
It makes sense to remove it in time for v1.8, could already have been done for v1.7

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
@kubernetes/sig-cluster-lifecycle-pr-reviews
2017-06-30 22:06:23 -07:00
Clayton Coleman 2f211b8870
Move DaemonSet to table printer 2017-06-26 20:58:02 -04:00
Clayton Coleman bdd3116c09
Move more printers to TablePrinter 2017-06-26 11:38:36 -04:00
Lucas Käldström e25a5b1546
Remove old node role label that is not used by kubeadm 2017-06-26 14:46:15 +03:00
FengyunPan b9c1848fbd Fix output extra comma
When running 'kubectl get service', I get a extra comma in result:
'EXTERNAL-IP:,172.16.0.12', but except: 'EXTERNAL-IP:172.16.0.12'.
2017-06-24 00:10:33 +08:00
FengyunPan a97a9f9dd5 Display <none> for clusterIP and port when service is ExternalName 2017-06-23 23:55:08 +08:00
Kubernetes Submit Queue ae9ca46927 Merge pull request #47694 from FengyunPan/display-service-type
Automatic merge from submit-queue (batch tested with PRs 47694, 47772, 47783, 47803, 47673)

Output TYPE for getting service

**What this PR does / why we need it**:
Now service already supported 4 ServiceTypes, ServiceTypes is
friendly to distinguish services, so outputing service type better
when running 'kubectl get service'.

**Release note**:
```release-note
  NONE
```
2017-06-23 08:29:23 -07:00
Kubernetes Submit Queue 8679677e87 Merge pull request #47579 from wanghaoran1988/fix_43322
Automatic merge from submit-queue (batch tested with PRs 47958, 46261, 46667, 47709, 47579)

Clean up Deployment overlap annotation code

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #43322

**Special notes for your reviewer**:

**Release note**:

```
None
```
2017-06-23 07:21:36 -07:00
Kubernetes Submit Queue b1ac562918 Merge pull request #44086 from NickrenREN/sc-type
Automatic merge from submit-queue (batch tested with PRs 47915, 47856, 44086, 47575, 47475)

Change second StorageClass Column to provisioner

Some provisioners have key-value pairs in parameters map which key is type, here TYPE in StorageClass columns may be confused.
https://kubernetes.io/docs/concepts/storage/persistent-volumes/#storageclasses

**Release note**:

```release-note
NONE
```
2017-06-23 04:06:23 -07:00
Kubernetes Submit Queue 4a1d95ef57 Merge pull request #46646 from rickypai/rpai/add_container_runtime_version_to_node_wide_printer
Automatic merge from submit-queue (batch tested with PRs 47403, 46646, 46906, 46527, 46792)

add ContainerRuntimeVersion to `kubectl get nodes -o=wide` output

**What this PR does / why we need it**: adds container runtime version to `kubectl get nodes -o=wide` output as a way to surface more node-level information

When upgrading to a new container runtime version (docker 1.11 -> docker 1.12) or when experimenting with a different container runtime version (experimenting with rkt in a docker cluster), it's useful for cluster operators to see which nodes are running which container runtime version. `kubectl get nodes -o=wide` already provides kernel and OS version, and I believe adding container runtime version would be good.

**Release note**:
```release-note
container runtime version has been added to the output of `kubectl get nodes -o=wide` as `CONTAINER-RUNTIME`
```
2017-06-23 02:59:25 -07:00
Kubernetes Submit Queue c76c145d37 Merge pull request #46280 from zjj2wry/print-rs
Automatic merge from submit-queue (batch tested with PRs 47227, 47119, 46280, 47414, 46696)

Improve code coverage for pkg/printer

**What this PR does / why we need it**:

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-06-22 23:59:21 -07:00
Chao Xu 60604f8818 run hack/update-all 2017-06-22 11:31:03 -07:00
Chao Xu cde4772928 run ./root-rewrite-all-other-apis.sh, then run make all, pkg/... compiles 2017-06-22 11:30:52 -07:00
Chao Xu f4989a45a5 run root-rewrite-v1-..., compile 2017-06-22 10:25:57 -07:00
Kubernetes Submit Queue a8968810fd Merge pull request #47380 from kevin-wangzefeng/pod-tolerations-with-no-value
Automatic merge from submit-queue

hide operator when describe pod with empty value tolerations

**What this PR does / why we need it**:
The tolerations printing in `kubectl descirbe pod` is not correct when toleration.value is empty, this PR is to fix it.

Before: 
```
Tolerations:	node.alpha.kubernetes.io/notReady=:Exists:NoExecute for 300s
		node.alpha.kubernetes.io/unreachable=:Exists:NoExecute for 300s
```
After:
```
Tolerations:	node.alpha.kubernetes.io/notReady:NoExecute for 300s
		node.alpha.kubernetes.io/unreachable:NoExecute for 300s
```

Also updated tests to cover all possible cases of describing pod with tolerations. See changes in of `TestDescribePodTolerations()` in `describe_test.go`

**Which issue this PR fixes**:

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-06-22 08:02:29 -07:00
FengyunPan f01f9a9035 Output TYPE for getting service
Now service already supported 4 ServiceTypes, ServiceTypes is
friendly to distinguish services, so outputing service type better
when running 'kubectl get service'.
2017-06-18 12:19:57 +08:00
Haoran Wang f732e4baae Clean up Deployment overlap annotation code 2017-06-16 14:20:44 +08:00
Klaus Ma d3efbfcd33 Fixed PVC's capacity in description. 2017-06-15 11:56:46 +08:00
Kevin c6c9e9b4e0 hide operator when describe pod with empty value tolerations 2017-06-12 16:17:31 -07:00
Kubernetes Submit Queue 9df40c3661 Merge pull request #42156 from croomes/storageos
Automatic merge from submit-queue

StorageOS Volume Plugin

**What this PR does / why we need it**:
This PR adds a new volume plugin for StorageOS volumes.  StorageOS runs as a container on Kubelet nodes, aggregating local or attached storage and making its capacity available to all nodes within the cluster. More information at http://storageos.com.

The StorageOS plugin supports:

1. Dynamic Provisioning using Storage Classes
2. Persistent Volumes and Persistent Volume Claims.

**Which issue this PR fixes**
A feature request has been created:
https://github.com/kubernetes/features/issues/190

This isn't on the schedule for 1.6 as I wasn't sure when it would be ready.  We intend to make the StorageOS container openly available within the 1.6 lifetime.

**Special notes for your reviewer**:

Separate commits for feature and godep changes.

**Release note**:
```release-note
StorageOS Volume Driver
[StorageOS](http://www.storageos.com) can be used as a storage provider for Kubernetes.  With StorageOS, capacity from local or attached storage is pooled across the cluster, providing converged infrastructure for cloud-native applications. 
```
2017-06-09 18:25:04 -07:00
Dr. Stefan Schimanski 30668b24fb client-go: GetOptions for dynamic client 2017-06-09 18:04:17 +02:00
Simon Croome 5e2503e71f Add StorageOS volume plugin 2017-06-09 13:19:27 +01:00
Kubernetes Submit Queue 41f6f9ddbb Merge pull request #45877 from zhangxiaoyu-zidif/add-ut-for-test-podlist
Automatic merge from submit-queue (batch tested with PRs 45877, 46846, 46630, 46087, 47003)

add Unit Test for PodList Printer

Signed-off-by: zhangxiaoyu-zidif <zhang.xiaoyu33@zte.com.cn>



**What this PR does / why we need it**:
add Unit Test for PodList Printer

**Release note**:

```release-note
NONE
```
2017-06-07 17:55:40 -07:00
Kubernetes Submit Queue 49866b864c Merge pull request #47013 from smarterclayton/fix_printer
Automatic merge from submit-queue (batch tested with PRs 47024, 47050, 47086, 47081, 47013)

Wrap HumanReadablePrinter in tab output unless explicitly asked not to

`kubectl get` was not properly aligning its output due to #40848 

Fixes an accidental regression. In general, we should not accept an incoming tabwriter and instead manage at a higher level. Fix the bug and add a comment re: future refactoring.
2017-06-07 16:53:47 -07:00
Sunil Arora f768a63fb0 Get cmd uses print-column extn from Openapi schema
Get command now uses metadata x-kubernetes-print-columns, if present, in Openapi schema
to format output for a resource. This functionality is guarded by a boolean
flag 'use-openapi-print-columns'.
2017-06-06 13:30:24 -07:00
Clayton Coleman b1abedbc64
Wrap HumanReadablePrinter in tab output unless explicitly asked not to
Fixes an accidental regression. In general, we should not accept an
incoming tabwriter and instead manage at a higher level. Fix the bug and
add a comment re: future refactoring.
2017-06-05 22:06:38 -04:00
Solly Ross 53dccdbb43 Update kubectl to display HPA status conditions
This commit updates `kubectl describe` to display the new HPA
status conditions.  This should make it easier for users to discern
the current state of the HPA.
2017-06-05 11:21:31 -04:00
zhangxiaoyu-zidif 3ef73bdb55 Add unittest for PodList 2017-06-05 17:56:53 +08:00
Kubernetes Submit Queue 348bf1e032 Merge pull request #46627 from deads2k/api-12-labels
Automatic merge from submit-queue (batch tested with PRs 46239, 46627, 46346, 46388, 46524)

move labels to components which own the APIs

During the apimachinery split in 1.6, we accidentally moved several label APIs into apimachinery.  They don't belong there, since the individual APIs are not general machinery concerns, but instead are the concern of particular components: most commonly the kubelet.  This pull moves the labels into their owning components and out of API machinery.

@kubernetes/sig-api-machinery-misc @kubernetes/api-reviewers @kubernetes/api-approvers 
@derekwaynecarr  since most of these are related to the kubelet
2017-06-02 23:37:38 -07:00
Kubernetes Submit Queue 2629bf79f2 Merge pull request #46265 from waseem/printers-genericity
Automatic merge from submit-queue (batch tested with PRs 41563, 45251, 46265, 46462, 46721)

Denote if a printer is generic.

This fixes #38779.

This allows us to avoid case in which printers.GetStandardPrinter
returns nil for both printer and err removing any potential panics that
may arise throughout kubectl commands.

Please see #38779 and #38112 for complete context.
2017-06-02 19:53:40 -07:00
Kubernetes Submit Queue 97a5d37841 Merge pull request #40848 from smarterclayton/serverside_get
Automatic merge from submit-queue (batch tested with PRs 46432, 46701, 46326, 40848, 46396)

Add a server side Get operation

Implement proposal kubernetes/community#363

```release-note
The Kubernetes API supports retrieving tabular output for API resources via a new mime-type `application/json;as=Table;v=v1alpha1;g=meta.k8s.io`.  The returned object (if the server supports it) will be of type `meta.k8s.io/v1alpha1` with `Table`, and contain column and row information related to the resource.  Each row will contain information about the resource - by default it will be the object metadata, but callers can add the `?includeObject=Object` query parameter and receive the full object.  In the future kubectl will use this to retrieve the results of `kubectl get`.
```
2017-06-02 11:47:11 -07:00
Kubernetes Submit Queue f5bcd98d5e Merge pull request #46326 from xilabao/add-role-to-describe-command
Automatic merge from submit-queue (batch tested with PRs 46432, 46701, 46326, 40848, 46396)

add role/clusterrole to describe.go

**What this PR does / why we need it**:
```
# ./cluster/kubectl.sh describe clusterrole system:kube-scheduler 
Name:		system:kube-scheduler
Labels:		kubernetes.io/bootstrapping=rbac-defaults
Annotations:	rbac.authorization.kubernetes.io/autoupdate=true
PolicyRule:
  Resources			Non-Resource URLs	Resource Names		Verbs
  ---------			-----------------	--------------		-----
  bindings			[]			[]			[create]
  endpoints			[]			[]			[create]
  endpoints			[]			[kube-scheduler]	[delete]
  endpoints			[]			[kube-scheduler]	[get]
  endpoints			[]			[kube-scheduler]	[patch]
  endpoints			[]			[kube-scheduler]	[update]
  events			[]			[]			[create patch update]
  nodes				[]			[]			[get list watch]
  persistentvolumeclaims	[]			[]			[get list watch]
  persistentvolumes		[]			[]			[get list watch]
  pods				[]			[]			[get list watch]
  pods/binding			[]			[]			[create]
  pods/status			[]			[]			[update]
  replicasets.extensions	[]			[]			[get list watch]
  replicationcontrollers	[]			[]			[get list watch]
  services			[]			[]			[get list watch]
  statefulsets.apps		[]			[]			[get list watch]

```
**Which issue this PR fixes**: 

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-06-02 11:47:07 -07:00
zhengjiajin 41ccc15796 Improve code coverage for pkg/printer 2017-06-02 10:07:30 +08:00
Ricky Pai 8c0c7626eb add ContainerRuntimeVersion to `kubectl get nodes -o=wide` output 2017-06-01 16:52:04 -07:00
xilabao bfd184274b add role/clusterrole to describe.go 2017-06-01 14:14:10 +08:00
deads2k 954eb3ceb9 move labels to components which own the APIs 2017-05-31 10:32:06 -04:00
Waseem Ahmad 8442a118ea Denote if a printer is generic.
This fixes #38779.

This allows us to avoid case in which printers.GetStandardPrinter
returns nil for both printer and err removing any potential panics that
may arise throughout kubectl commands.

Please see #38779 and #38112 for complete context.

Add comment explaining adding handlers to printers.HumanReadablePrinter
also remove an unnecessary conversion of printers.HumanReadablePrinter
to printers.ResourcePrinter.
2017-05-31 13:02:23 +05:30
Janet Kuo 80af0012f5 Implement kubectl get controllerrevisions 2017-05-30 18:15:26 -07:00
Kubernetes Submit Queue 8caffc300e Merge pull request #45909 from zhangxiaoyu-zidif/add-unittest-for-configmap
Automatic merge from submit-queue (batch tested with PRs 45488, 45335, 45909, 46074, 46615)

Add Unit Test:describe configmap

**What this PR does / why we need it**:
Add Unit Test:describe configmap

**Release note**:

```release-note
NONE
```
2017-05-30 03:46:59 -07:00
Clayton Coleman 7ce63eb608
Refactor printers to support rendering as a Table
Return tables from the server.
2017-05-29 18:30:10 -04:00
Dan Winship 0923f860f1 Regenerate files 2017-05-28 10:11:02 -04:00
Dan Winship 0683e55fc1 Add networking.k8s.io v1 API, with NetworkPolicy 2017-05-28 10:11:01 -04:00
Kubernetes Submit Queue 25aa600360 Merge pull request #46178 from zjj2wry/des_rq
Automatic merge from submit-queue

add test in descibe resourcequota

**What this PR does / why we need it**:

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-05-26 07:05:54 -07:00
xilabao 9fe2ef54ba add policy_compact to rbac validation 2017-05-26 13:22:38 +08:00
Kubernetes Submit Queue b642ae2c18 Merge pull request #46124 from humblec/cephfs-vol-source
Automatic merge from submit-queue (batch tested with PRs 46124, 46434, 46089, 45589, 46045)

Add CephFS volume source to describe printer.
2017-05-25 21:39:56 -07:00
zhengjiajin fe44830a31 add test in descibe resourcequota 2017-05-24 10:12:37 +08:00
Humble Chirammal 8700776d26 Add CephFS volume source to describe printer.
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2017-05-23 20:27:00 +05:30
Anirudh 078f9566d9 PDB MaxUnavailable: kubectl changes 2017-05-23 07:18:44 -07:00
Kubernetes Submit Queue 455e9fff09 Merge pull request #46176 from vmware/vSphereStoragePolicySupport
Automatic merge from submit-queue

vSphere storage policy support for dynamic volume provisioning

Till now, vSphere cloud provider provides support to configure persistent volume with VSAN storage capabilities - kubernetes#42974. Right now this only works with VSAN.

Also there might be other use cases:

- The user might need a way to configure a policy on other datastores like VMFS, NFS etc.
- Use Storage IO control, VMCrypt policies for a persistent disk.

We can achieve about 2 use cases by using existing storage policies which are already created on vCenter using the Storage Policy Based Management service. The user will specify the SPBM policy ID as part of dynamic provisioning 

- resultant persistent volume will have the policy configured with it. 
- The persistent volume will be created on the compatible datastore that satisfies the storage policy requirements. 
- If there are multiple compatible datastores, the datastore with the max free space would be chosen by default.
- If the user specifies the datastore along with the storage policy ID, the volume will created on this datastore if its compatible. In case if the user specified datastore is incompatible, it would error out the reasons for incompatibility to the user.
- Also, the user will be able to see the associations of persistent volume object with the policy on the vCenter once the volume is attached to the node.

For instance in the below example, the volume will created on a compatible datastore with max free space that satisfies the "Gold" storage policy requirements.

```
kind: StorageClass
apiVersion: storage.k8s.io/v1beta1
metadata:
       name: fast
provisioner: kubernetes.io/vsphere-volume
parameters:
      diskformat: zeroedthick
      storagepolicyName: Gold
```

For instance in the below example, the vSphere CP checks if "VSANDatastore" is compatible with "Gold" storage policy requirements. If yes, volume will be provisioned on "VSANDatastore" else it will error that "VSANDatastore" is not compatible with the exact reason for failure.

```
kind: StorageClass
apiVersion: storage.k8s.io/v1beta1
metadata:
       name: fast
provisioner: kubernetes.io/vsphere-volume
parameters:
      diskformat: zeroedthick
      storagepolicyName: Gold
      datastore: VSANDatastore
```

As a part of this change, 4 commits have been added to this PR.

1. Vendor changes for vmware/govmomi
2. Changes to the VsphereVirtualDiskVolumeSource in the Kubernetes API. Added 2 additional fields StoragePolicyName, StoragePolicyID
3. Swagger and Open spec API changes.
4. vSphere Cloud Provider changes to implement the storage policy support.

**Release note**:


```release-note
vSphere cloud provider: vSphere Storage policy Support for dynamic volume provisioning
```
2017-05-22 23:41:10 -07:00
Kubernetes Submit Queue e823e60bbf Merge pull request #46022 from xilabao/add-rolebinding-to-describe-command
Automatic merge from submit-queue

add rolebinding/clusterrolebinding to describe.go

**What this PR does / why we need it**:

```
./cluster/kubectl.sh describe clusterrolebinding system:kube-dns
Name:		system:kube-dns
Labels:		kubernetes.io/bootstrapping=rbac-defaults
Annotations:	rbac.authorization.kubernetes.io/autoupdate=true
Role:
  Kind:	ClusterRole
  Name:	system:kube-dns
Subjects:
  Kind			Name		Namespace
  ----			----		---------
  ServiceAccount	kube-dns	kube-system
```

**Which issue this PR fixes**: 

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-05-22 19:59:20 -07:00
System Administrator 83520a7470 Kubernetes core API changes for vSphere 2017-05-22 19:43:29 -07:00
Kubernetes Submit Queue f6b3d083b7 Merge pull request #44640 from msau42/local-pv-api
Automatic merge from submit-queue

LocalStorage api

**What this PR does / why we need it**:
API changes to support persistent local volumes, as described [here](https://github.com/kubernetes/community/pull/306)

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #
Part of #43640

**Special notes for your reviewer**:
There were a few items I was concerned about.  Will add review comments in those places.

**Release note**:

NONE

Note will be added in subsequent PR with the volume plugin changes
2017-05-22 14:39:05 -07:00
Michelle Au d848be195f API changes for persistent local volumes.
Includes:
- A new volume type, LocalVolumeSource.  This only supports
file-based local volumes for now.
- New alpha annotation in PV: NodeAffinity
- Validation + tests for specifying LocalVolumeSource and PV
NodeAffinity
- Alpha feature gate
2017-05-21 11:48:56 -07:00
Klaus Ma 83b7f77ee2 Moved qos to api.helpers. 2017-05-20 07:17:57 -04:00
Kubernetes Submit Queue 113cf85612 Merge pull request #45903 from brendandburns/azure-disk-api
Automatic merge from submit-queue (batch tested with PRs 45346, 45903, 45958, 46042, 45975)

Azure disk api

This is to update the AzureDiskApi and split it from the implementation which is caught in rebase hell...

Once this is merged, we'll get the implementation in.

@smarterclayton suggested this as a way to break the rebase hell logjam. request for a quick review.

Thanks!
2017-05-19 22:29:30 -07:00
Brendan Burns 4177b28e5a Add new AzureDisk API, but not implementation. 2017-05-18 11:36:42 -07:00
Humble Chirammal 11f1152e77 Add missing parameters of iscsi volume source to describe printer.
Signed-off-by: Humble Chirammal <hchiramm@redhat.com>
2017-05-18 17:08:13 +05:30
xilabao 516a245ac7 add rolebinding/clusterrolebinding to describe.go 2017-05-18 16:56:14 +08:00
xilabao fa563dce15 fix self link error of generic resources in describe command 2017-05-18 14:46:45 +08:00
zhangxiaoyu-zidif 7c79b3e62f unit test:describe configmap
Signed-off-by: zhangxiaoyu-zidif <zhang.xiaoyu33@zte.com.cn>
2017-05-17 22:16:56 +08:00
Zihong Zheng 5992425588 Autogenerated files 2017-05-16 21:55:51 -07:00
Zihong Zheng c0920f75cf Move API annotations into annotation_key_constants and remove api/annotations package 2017-05-16 21:55:23 -07:00
Kubernetes Submit Queue a4aaaf69e8 Merge pull request #45769 from zhangxiaoyu-zidif/add-describe-pod-node
Automatic merge from submit-queue

describe pod: add unit test for Node

**What this PR does / why we need it**:

Add unit test for "describe pod" in order to get node info.

**Release note**:

```release-note
NONE
```
2017-05-16 08:17:17 -07:00
Kubernetes Submit Queue 1e48f5b40b Merge pull request #45788 from zhangxiaoyu-zidif/describe-pod-node-nil
Automatic merge from submit-queue (batch tested with PRs 45171, 43947, 45788, 45822, 45808)

Display <none> for kubectl describe pod when node is empty.

**What this PR does / why we need it**:
Display <none> for kubectl describe pod when node is empty.

**Special notes for your reviewer**:
refer to #45572

**Release note**:

```release-note
NONE
```
2017-05-15 14:24:47 -07:00
Kubernetes Submit Queue 5b417e4458 Merge pull request #43947 from xiangpengzhao/describe-cleanup
Automatic merge from submit-queue (batch tested with PRs 45171, 43947, 45788, 45822, 45808)

Cleanup kubectl describe code

**What this PR does**:
- move all `tabbedString` into separate functions to keep same style
- delete unused functions
2017-05-15 14:24:44 -07:00
zhangxiaoyu-zidif de64f52634 Display <none> for kubectl describe pod when node is empty. 2017-05-14 22:15:23 +08:00
zhangxiaoyu-zidif 260e2aa82d describe pod: add unit test for Node 2017-05-13 21:59:04 +08:00
xiangpengzhao 6ec162d816 Cleanup kubectl describe code 2017-05-13 10:24:30 +08:00
Kubernetes Submit Queue debced7449 Merge pull request #45572 from xiangpengzhao/fix-node-none
Automatic merge from submit-queue (batch tested with PRs 45685, 45572, 45624, 45723, 45733)

Display <none> for "kubectl get pods -o wide" when node is empty.

**What this PR does / why we need it**:
If pods are pending due to no matched node to be scheduled, `Spec.NodeName` would be empty. In this case, "kubectl get pods -o wide" displays `<none>` instead of empty.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-05-12 14:00:54 -07:00
zhangxiaoyu-zidif d1ba51f1ec get pod -o wide: add unittest for nodeName 2017-05-12 20:43:44 +08:00
Kubernetes Submit Queue 9a0f5ccb33 Merge pull request #45480 from xiangpengzhao/scheduledjob-cronjob
Automatic merge from submit-queue (batch tested with PRs 45634, 45480)

Rename vars scheduledJob to cronJob in describe.go

**What this PR does / why we need it**:
Rename vars scheduledJob to cronJob in describe.go

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:
There might still be some leftovers in other places.
@soltysh 

**Release note**:

```release-note
NONE
```
2017-05-11 00:12:40 -07:00
Kubernetes Submit Queue b040513aab Merge pull request #43067 from xilabao/dedup-in-printer
Automatic merge from submit-queue

De-duplication in printer
2017-05-10 19:08:59 -07:00
xiangpengzhao a9a36fcf4b
Display <none> for "kubectl get pods -o wide" when node is empty. 2017-05-10 12:53:14 +08:00
Kubernetes Submit Queue 148b5da60b Merge pull request #44746 from xiangpengzhao/fix-podpreset
Automatic merge from submit-queue

Add support for PodPreset in `kubectl get` command

**What this PR does / why we need it**:
PR title

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #44736

**Special notes for your reviewer**:

**Release note**:

```release-note
NONE
```
2017-05-09 21:16:17 -07:00
xiangpengzhao baafbf406e Add support for PodPreset in kubectl get command 2017-05-10 08:59:22 +08:00
xilabao 697efd1baf De-duplication in printer 2017-05-10 08:45:20 +08:00
xiangpengzhao b981909206
Rename vars scheduledJob to cronJob in describe.go 2017-05-08 17:30:10 +08:00
xiangpengzhao 3e389566bf
Display <none> when port is empty. 2017-05-08 16:08:49 +08:00
Kubernetes Submit Queue 17d33ea82e Merge pull request #44830 from NickrenREN/remove-NodeLegacyHostIP
Automatic merge from submit-queue

Remove deprecated NodeLegacyHostIP

**Release note**:
```release-note
Remove deprecated node address type `NodeLegacyHostIP`.
```

ref #44807
2017-05-05 15:38:58 -07:00
Fabiano Franz 1aa84d101a Fixes get -oname for unstructured objects 2017-04-28 14:12:36 -03:00
Kubernetes Submit Queue 22957509e7 Merge pull request #44600 from xingzhou/kube-44599
Automatic merge from submit-queue

Fixed a tiny issue for ShortHumanDuration printer.

Fixed a tiny issue for ShortHumanDuration printer
to avoid "0y" message.

Fixed #44599
2017-04-25 08:59:07 -07:00
NickrenREN 7d00e5cfb6 remove deprecated NodeLegacyHostIP 2017-04-24 11:01:25 +08:00
Kubernetes Submit Queue 8e3d32b141 Merge pull request #44710 from xiangpengzhao/describe-print-rc-rs-conditions
Automatic merge from submit-queue

Print conditions of RC/RS in 'kubectl describe' command

**What this PR does / why we need it**:
If conditions of RC/RS exist, print them in 'kubectl describe' command.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:


**Release note**:

```release-note
Print conditions of RC/RS in 'kubectl describe' command.
```
2017-04-21 07:47:29 -07:00
xiangpengzhao b577754726 Print conditions of RC/RS in 'kubectl describe' command 2017-04-21 10:54:17 +08:00
Kubernetes Submit Queue 870585e8e1 Merge pull request #44651 from knightXun/string
Automatic merge from submit-queue (batch tested with PRs 44594, 44651)

remove strings.compare(), use string native operation

I notice we use strings.Compare() in some code, we can remove it and use native operation.
2017-04-20 14:08:59 -07:00
Kubernetes Submit Queue 6bf7914a71 Merge pull request #44594 from xiangpengzhao/describe-node-depre-phase
Automatic merge from submit-queue

Delete deprecated node phase in kubect describe node.

**What this PR does / why we need it**:
Since NodePhase is no longer used, delete it in `kubect describe node` result. 

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:
ref: https://github.com/kubernetes/kubernetes/pull/44388

**Release note**:

```release-note
NONE
```
2017-04-20 13:48:52 -07:00
xu fei b0a3f492af remove strings.compare(), use string native operation 2017-04-19 09:32:29 +08:00
Xing Zhou 35c900aa70 Fixed a tiny issue for ShortHumanDuration printer.
Fixed a tiny issue for ShortHumanDuration printer
to avoid "0y" message.
2017-04-18 16:11:41 +08:00
Fabiano Franz b276f17b6d Smarter get printer for generic resources 2017-04-17 15:42:47 -03:00
Fabiano Franz 151770c8fd Smarter describer for generic resources 2017-04-17 15:42:47 -03:00
Mike Danese a05c3c0efd autogenerated 2017-04-14 10:40:57 -07:00
Kubernetes Submit Queue 15a24eb056 Merge pull request #44316 from xiangpengzhao/print-node-addr
Automatic merge from submit-queue (batch tested with PRs 44440, 44038, 44302, 44316, 43876)

Show node address type in kubectl describe node command

**What this PR does / why we need it**:
To make node addresses more clear when describing node.

Before:
```
Addresses:		192.168.1.220,192.168.1.220,192.168.1.220
```

After:
```
Addresses:
 LegacyHostIP:	192.168.1.220
 InternalIP:	192.168.1.220
 Hostname:	192.168.1.220
```

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #

**Special notes for your reviewer**:

**Release note**:

```release-note
None
```
2017-04-13 23:18:05 -07:00
Chao Xu 9837a98564 move resource_helpers.go to a subpackage 2017-04-13 12:03:42 -07:00
Chao Xu d9920c53a5 move ref.go to its own subpackage 2017-04-13 10:02:43 -07:00
xiangpengzhao e1e1834e8b Show node address type in kubectl describe node command 2017-04-13 09:22:39 +08:00
Kubernetes Submit Queue c9014b1029 Merge pull request #42849 from janetkuo/kubectl-describe-controllerRef
Automatic merge from submit-queue

In 'kubectl describe', find controllers with ControllerRef, instead of showing the original creator

@enisoc @kargakis @kubernetes/sig-apps-pr-reviews @kubernetes/sig-cli-pr-reviews 

```release-note
In 'kubectl describe', find controllers with ControllerRef, instead of showing the original creator.
```
2017-04-12 09:05:41 -07:00
Chao Xu 08aa712a6c move helpers.go to helper 2017-04-11 15:49:11 -07:00
Janet Kuo b29135ea8f In 'kubectl describe', find controllers with ControllerRef, instead of showing the original creator 2017-04-11 15:41:57 -07:00
xiangpengzhao 10d60f615b
Delete deprecated node phase in kubect describe node. 2017-04-11 16:40:27 +08:00
Kubernetes Submit Queue c8f90171e4 Merge pull request #39678 from resouer/extract-resource
Automatic merge from submit-queue (batch tested with PRs 41775, 39678, 42629, 42524, 43028)

Extract resources functions belongs to api/util

Address: extract kubelet resources functions belongs to `pkg/api/v1/resource_helpers.go`
2017-04-07 17:44:14 -07:00
NickrenREN 6327724b51 Change second StorageClass Column to provisioner
Some provisioners have key-value pairs in parameters map which key is type, here TYPE in StorageClass columns may be confused
2017-04-05 16:22:31 +08:00
Maciej Pytel 8551049ba9 Include events when describing configmap 2017-04-03 15:03:12 +02:00
Harry Zhang efb10b1821 Move extract resources to its pkg
Move ExtractContainerResourceValue
2017-04-03 13:06:48 +08:00
Kubernetes Submit Queue 74c23bdf68 Merge pull request #41805 from aanm/adding-ipv6-brackets-in-kubectl-endpoint
Automatic merge from submit-queue

kubectl: Adding IPv6 brackets for IPv6 endpoints

This fixes the lack of IPv6 when printing the IP:Port tuple with kubectl
describe command.

Signed-off-by: André Martins <aanm90@gmail.com>

**What this PR does / why we need it**: This adds IPv6 brackets on IPv6 endpoints when using `kubectl describe service`

**Special notes for your reviewer**: Since the IP is a string I think the fastest way to detect if it's an IPv6 was to check for the presence of : in it. Let me know what you think.
2017-04-02 07:57:08 -07:00
Kubernetes Submit Queue 9c62733b1f Merge pull request #43044 from ncdc/NewPrefixWriter
Automatic merge from submit-queue (batch tested with PRs 42900, 43044, 42896, 43308, 43621)

Convert PrefixWriter to an interface

Convert PrefixWriter to an interface to allow other packages to create instances. This is needed for downstream projects such as OpenShift.

cc @sttts @smarterclayton @oulinbao @deads2k @liggitt @kargakis @soltysh @kubernetes/sig-cli-pr-reviews
2017-03-27 08:32:25 -07:00
Kubernetes Submit Queue f9e87e1dc2 Merge pull request #42902 from louyihua/allow-tcp-probe-host
Automatic merge from submit-queue (batch tested with PRs 42998, 42902, 42959, 43020, 42948)

Add Host field to TCPSocketAction

Currently, TCPSocketAction always uses Pod's IP in connection. But when a pod uses the host network, sometimes firewall rules may prevent kubelet from connecting through the Pod's IP.

This PR introduces the 'Host' field for TCPSocketAction, and if it is set to non-empty string, the probe will be performed on the configured host rather than the Pod's IP. This gives users an opportunity to explicitly specify 'localhost' as the target for the above situations.

```release-note
Add Host field to TCPSocketAction
```
2017-03-25 17:17:23 -07:00
Kubernetes Submit Queue f37cffcf4e Merge pull request #43239 from enisoc/kubectl-controller-ref
Automatic merge from submit-queue

kubectl: Use v1.5-compatible ownership logic when listing dependents.

**What this PR does / why we need it**:

This restores compatibility between kubectl 1.6 and clusters running Kubernetes 1.5.x. It introduces transitional ownership logic in which the client considers ControllerRef when it exists, but does not require it to exist.

If we were to ignore ControllerRef altogether (pre-1.6 client behavior), we would introduce a new failure mode in v1.6 because controllers that used to get stuck due to selector overlap will now make progress. For example, that means when reaping ReplicaSets of an overlapping Deployment, we would risk deleting ReplicaSets belonging to a different Deployment that we aren't about to delete.

This transitional logic avoids such surprises in 1.6 clusters, and does no worse than kubectl 1.5 did in 1.5 clusters. To prevent this when kubectl 1.5 is used against 1.6 clusters, we can cherrypick this change.

**Which issue this PR fixes**:

Fixes #43159

**Special notes for your reviewer**:

**Release note**:
```release-note
```
2017-03-17 14:25:38 -07:00
André Martins cecc03ca8f kubectl: Adding IPv6 brackets for IPv6 endpoints
This fixes the lack of IPv6 when printing the IP:Port tuple with kubectl
describe command.

Signed-off-by: André Martins <aanm90@gmail.com>
2017-03-17 15:14:51 +00:00
Anthony Yeh 725ec0cc5e kubectl: Check for Deployment overlap annotation in reaper.
This effectively reverts the client-side changes in
cec3899b96.
We have to maintain the old behavior on the client side to support
version skew when talking to old servers that set the annotation.

However, the new server-side behavior is still to NOT set the
annotation.
2017-03-16 12:28:28 -07:00
Seth Jennings 753484d073 kubectl: fall back to computing QoS class if server does not populate 2017-03-16 12:24:59 -05:00
Lou Yihua 63f1b077dc Add Host field to TCPSocketAction
Currently, TCPSocketAction always uses Pod's IP in connection. But when a
pod uses the host network, sometimes firewall rules may prevent kubelet
from connecting through the Pod's IP. This PR introduces the 'Host' field
for TCPSocketAction, and if it is set to non-empty string, the probe will
be performed on the configured host rather than the Pod's IP. This gives
users an opportunity to explicitly specify 'localhost' as the target for
the above situations.
2017-03-14 23:48:28 +08:00
Andy Goldstein 433fc606c6 Convert PrefixWriter to an interface
Convert PrefixWriter to an interface to allow other packages to create
instances. This is needed for downstream projects such as OpenShift.
2017-03-14 10:31:13 -04:00
Kubernetes Submit Queue 65ddace3ed Merge pull request #42702 from smarterclayton/printer_owners
Automatic merge from submit-queue

Add pkg/printers OWNERS

Should also include more sig-api-machinery as this will be moving to server side
2017-03-12 21:04:57 -07:00
Janet Kuo 39857f4865 Add new DaemonSetStatus to kubectl printer and describer 2017-03-09 15:45:17 -08:00
Clayton Coleman 1118e6be35
Add pkg/printers OWNERS 2017-03-07 22:28:27 -05:00
Anthony Yeh cec3899b96 Deployment: Remove Overlap and SelectorUpdate annotations.
These are not used anymore since ControllerRef now protects against
fighting between controllers with overlapping selectors.
2017-03-06 15:12:08 -08:00
Kubernetes Submit Queue f81a0107f0 Merge pull request #38924 from vladimirvivien/scaleio-k8s
Automatic merge from submit-queue (batch tested with PRs 42443, 38924, 42367, 42391, 42310)

Dell EMC ScaleIO Volume Plugin

**What this PR does / why we need it**
This PR implements the Kubernetes volume plugin to allow pods to seamlessly access and use data stored on ScaleIO volumes.  [ScaleIO](https://www.emc.com/storage/scaleio/index.htm) is a software-based storage platform that creates a pool of distributed block storage using locally attached disks on every server.  The code for this PR supports persistent volumes using PVs, PVCs, and dynamic provisioning.

You can find examples of how to use and configure the ScaleIO Kubernetes volume plugin in [examples/volumes/scaleio/README.md](examples/volumes/scaleio/README.md).

**Special notes for your reviewer**:
To facilitate code review, commits for source code implementation are separated from other artifacts such as generated, docs, and vendored sources.

```release-note
ScaleIO Kubernetes Volume Plugin added enabling pods to seamlessly access and use data stored on ScaleIO volumes.
```
2017-03-03 18:08:40 -08:00
Kubernetes Submit Queue f7c07a121d Merge pull request #42285 from liggitt/get-watch
Automatic merge from submit-queue (batch tested with PRs 41919, 41149, 42350, 42351, 42285)

Fix error printing objects from kubectl get -w

Fixes #42276
2017-03-03 16:44:45 -08:00
Vladimir Vivien 915a54180d Addition of ScaleIO Kubernetes Volume Plugin
This commits implements the Kubernetes volume plugin allowing pods to seamlessly access and use data stored on ScaleIO volumes.
2017-03-03 15:47:19 -05:00
Kubernetes Submit Queue 819364004f Merge pull request #42283 from smarterclayton/deployment_describe
Automatic merge from submit-queue

Describers with pod templates should have consistent output

Added a test to verify it.

Fixes #38698
2017-03-02 11:43:04 -08:00
Kubernetes Submit Queue 8cc7475ce1 Merge pull request #42218 from smarterclayton/incorrect_storageclass_printer
Automatic merge from submit-queue

StorageClass should not print the namespace column

Fixes #40091
2017-03-02 09:24:30 -08:00
Clayton Coleman b3485e7c6a
Remove images field in describer and use pod template consistently
Images field didn't include init containers. Use pod template output
consistently and ensure labels and annotations are in the right spot
2017-03-02 08:28:50 -05:00
Clayton Coleman d8ee5e003c
Improve statefulset describer to include volume templates 2017-03-02 08:10:32 -05:00
Clayton Coleman 39a32a627f
Clean up top level labels in describer 2017-03-02 08:10:31 -05:00
Clayton Coleman a5bf3d5424
Deployment describer should include containers
Added a test to verify it.
2017-03-02 08:10:27 -05:00
Jan Safranek 7ae4152712 Move PV/PVC annotations to PV/PVC types.
They aren't part of storage.k8s.io/v1 or v1beta1 API.
Also move associated *GetClass functions.
2017-03-02 10:23:55 +01:00
Maciej Szulik c272630b1b Deployments under apps/v1beta1 with new defaults 2017-03-01 15:14:41 +01:00
Kubernetes Submit Queue c179f38fc2 Merge pull request #42162 from kevin-wangzefeng/kubectl-tolerationseconds
Automatic merge from submit-queue

fix kubectl describe pod, show tolerationSeconds

**What this PR does / why we need it**:
tolerationSeconds is now not shown in kubectl describe resutl, this PR is to fix it.

With this fix, pod toleration with tolerationSeconds would like below:
```yaml
Name:           bar
Namespace:      foo
Node:           /
Labels:         <none>
Status:
IP:
Controllers:    <none>
Containers:     <none>
No volumes.
QoS Class:
Node-Selectors: <none>
Tolerations:    key1=value1
				key2=value2:NoSchedule
				key3=value3:NoExecute for 300s
```


**Which issue this PR fixes** : 
Related issue: #1574
Related PR: #39469

**Special notes for your reviewer**:

**Release note**:

```release-note
make kubectl describe pod show tolerationSeconds
```
2017-02-28 22:00:55 -08:00
Jordan Liggitt 31b3e01f1e
Fix error printing objects from kubectl get -w 2017-02-28 22:36:26 -05:00
Aditya Dani 28df55fc31 Portworx Volume Driver in Kubernetes
- Add a new type PortworxVolumeSource
- Implement the kubernetes volume plugin for Portworx Volumes under pkg/volume/portworx
- The Portworx Volume Driver uses the libopenstorage/openstorage specifications and apis for volume operations.

Changes for k8s configuration and examples for portworx volumes.

- Add PortworxVolume hooks in kubectl, kube-controller-manager and validation.
- Add a README for PortworxVolume usage as PVs, PVCs and StorageClass.
- Add example spec files

Handle code review comments.

- Modified READMEs to incorporate to suggestions.
- Add a test for ReadWriteMany access mode.
- Use util.UnmountPath in TearDown.
- Add ReadOnly flag to PortworxVolumeSource
- Use hostname:port instead of unix sockets
- Delete the mount dir in TearDown.
- Fix link issue in persistentvolumes README
- In unit test check for mountpath after Setup is done.
- Add PVC Claim Name as a Portworx Volume Label

Generated code and documentation.
- Updated swagger spec
- Updated api-reference docs
- Updated generated code under pkg/api/v1

Godeps update for Portworx Volume Driver
- Adds github.com/libopenstorage/openstorage
- Adds go.pedge.io/pb/go/google/protobuf
- Updates Godep Licenses
2017-02-28 23:24:56 +00:00
Chun Chen b605da2522 kubectl describe: show annotations 2017-02-28 13:20:23 +08:00
Clayton Coleman fdbdbfe0cf
StorageClass should not print the namespace column 2017-02-27 22:31:40 -05:00
Kevin 49072c810a fix kubectl describe pod, show tolerationSeconds 2017-02-27 13:44:36 +00:00
Clayton Coleman 651188d687
generated: bazel 2017-02-23 00:28:32 -05:00
Clayton Coleman 7cdb0eb89f
NamePrinter should not hardcode scheme 2017-02-23 00:28:31 -05:00
Clayton Coleman 90fdd067e9
Restrict imports for printers 2017-02-23 00:28:31 -05:00
Clayton Coleman 3704ceffd2
Refactor printers to separate typed printers from generic code 2017-02-23 00:28:30 -05:00
Clayton Coleman 6d1c7308a5
Move, but do not refactor, printers to their own package 2017-02-23 00:28:30 -05:00