Commit Graph

584 Commits (3971553298616fee6e477b84474d64b7360d7f3a)

Author SHA1 Message Date
Sami Wagiaalla e1e7da2712 Add GIDs specified in a PV's annotations to pod's supplemental groups 2016-04-29 16:44:56 -04:00
k8s-merge-robot 06160b6abe Merge pull request #22023 from mkulke/rackspace-improvements
Automatic merge from submit-queue

Rackspace improvements (OpenStack Cinder)

This adds PV support via Cinder on Rackspace clusters. Rackspace Cloud Block Storage is pretty much vanilla OpenStack Cinder, so there is no need for a separate Volume Plugin. Instead I refactored the Cinder/OpenStack interaction a bit (by introducing a CinderProvider Interface and moving the device path detection logic to the OpenStack part).

Right now this is limited to `AttachDisk` and `DetachDisk`. Creation and deletion of Block Storage is not in scope of this PR.

Also the `ExternalID` and `InstanceID` cloud provider methods have been implemented for Rackspace.
2016-04-21 16:38:13 -07:00
k8s-merge-robot e3dab39df0 Merge pull request #21304 from tobad357/iscsi-mpio-support
Automatic merge from submit-queue

Add mpio support for iscsi

This allows the iscsi volume to check if a iscsi device belongs to a mpio device
If it does belong to the device then we make sure we mount the mpio device instead of
the raw device. 
The code is based on the current FibreChannel volume support for mpio

example
/dev/disk/by-path/iqn-example.com.2999 -> /dev/sde
Then we check
/sys/block/[dm-X]/slaves/xx
until we find the [dm-X] containing /dev/sde and mount it

Additional work that can be done in future
1. Add multiple portal support to iscsi
2. Move the FibreChannel volume provider to use the code that has been extracted
2016-04-21 15:40:50 -07:00
kulke ba4d74f3c7 Added Block Storage support to Rackspace provider, improved Node discovery. 2016-04-21 10:31:37 +02:00
k8s-merge-robot 537a739b3b Merge pull request #22995 from swagiaal/fix-gitrepo-ownership
Automatic merge from submit-queue

Set ownership to fsGroup in gitrepo

Set ownership to fsGroup in the gitrepo volume plugin

@pmorie
2016-04-20 03:49:37 -07:00
tobad357 1811ded396 This is an update that allows the iscsi volume to check if a iscsi device belongs to a mpio device
If it does belong to the device then we make sure we mount the mpio device instead of
the raw device.

Heuristics
Login into /dev/disk/by-path/iqn-example.com.2999 -> /dev/sde
Check if sde existsin in /sys/block/[dm-X]/slaves/xx
If it does mount /dev/[dm-x] which will look like /dev/mapper/mpiodevicename in mount

examples/iscsi has more details
2016-04-20 09:42:11 +08:00
Chakravarthy Nelluri f53bc4ebe0 Flexvolume: Add support for multiple secrets 2016-04-15 02:40:38 -07:00
k8s-merge-robot acf9492cb1 Merge pull request #23660 from goltermann/vetclean
Automatic merge from submit-queue

Additional go vet fixes

Mostly:
- pass lock by value
- bad syntax for struct tag value
- example functions not formatted properly
2016-04-12 06:22:16 -07:00
Saad Ali d7b069fbcc Merge pull request #23793 from pmorie/configmap-nonroot
Make ConfigMap volume readable as non-root
2016-04-06 15:11:25 -07:00
goltermann 696423e044 Vet fixes, mostly pass lock by value errors. 2016-04-06 11:27:40 -07:00
Paul Morie e838ff2893 Make ConfigMap volume readable as non-root 2016-04-05 12:20:52 -04:00
saadali e7b14e721a Ensure volume GetCloudProvider code uses cloud config 2016-04-04 10:59:13 -07:00
k8s-merge-robot 2205a30348 Merge pull request #23368 from saad-ali/renameBuilderCleaner
Auto commit by PR queue bot
2016-03-26 13:01:25 -07:00
goltermann 32d569d6c7 Fixing all the "composite literal uses unkeyed fields" Vet errors. 2016-03-25 15:25:09 -07:00
saadali 79012f6d53 Rename volume.Builder to Mounter and volume.Cleaner to Unmounter 2016-03-25 11:29:58 -07:00
Vishnu kannan 9e5ddcb822 Do not track resource usage for host path volumes. They can contain loops.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-03-24 12:05:08 -07:00
k8s-merge-robot f3fbd64927 Merge pull request #23334 from thockin/volume-maintainers
Auto commit by PR queue bot
2016-03-24 00:17:19 -07:00
k8s-merge-robot 76369c42be Merge pull request #22939 from resouer/util-sub-dir
Auto commit by PR queue bot
2016-03-23 03:34:33 -07:00
Tim Hockin 23fe2a3584 add maintainers for each volume driver 2016-03-22 22:19:53 -07:00
Jan Safranek f270cb1b9b Allow 39 atached EBS devices.
AWS has soft support limit for 40 attached EBS devices. Assuming there is just
one root device, use the rest for persistent volumes.

The devices will have name /dev/xvdba - /dev/xvdcm, leaving /dev/sda - /dev/sdz
to the system.

Also, add better error handling and propagate error
"Too many EBS volumes attached to node XYZ" to a pod.
2016-03-15 17:28:59 +01:00
Sami Wagiaalla 33a416e98f Set ownership to fsGroup in gitrepo 2016-03-15 12:20:48 -04:00
k8s-merge-robot 45064e19d1 Merge pull request #22793 from justinsb/fix_22792
Auto commit by PR queue bot
2016-03-11 20:37:25 -08:00
harry 5b359213b1 Refactor env into sub pkg
Refactor env into sub pkg
2016-03-11 13:52:45 +08:00
k8s-merge-robot 65605023d5 Merge pull request #22602 from justinsb/multizone_label_dynamic_pvs
Auto commit by PR queue bot
2016-03-10 21:19:05 -08:00
Justin Santa Barbara 16730aba96 AWS: Tag created EBS volumes with our cluster tag
Fix #22792
2016-03-10 08:13:50 -05:00
Justin Santa Barbara c771bf43c4 Ubernetes Lite: apply auto-labels to dynamically provisioned volumes
Fix #22532
2016-03-09 15:17:45 -05:00
Yang Meng a5189d8bd1 update mountpath of volume after migration 2016-03-07 18:00:06 +08:00
k8s-merge-robot 791c694c21 Merge pull request #22132 from pmorie/remove-atomic-sentinel
Auto commit by PR queue bot
2016-03-05 12:06:16 -08:00
k8s-merge-robot 3c5b57b217 Merge pull request #21805 from childsb/CanSupport_fix
Auto commit by PR queue bot
2016-03-05 10:09:35 -08:00
k8s-merge-robot b198c820cd Merge pull request #22402 from erictune/psp-simplify
Auto commit by PR queue bot
2016-03-05 07:55:19 -08:00
Eric Tune 4d090bfb09 Rename PodSecurityPolicy fields
In podSecurityPolicy:
1. Rename .seLinuxContext to .seLinux
2. Rename .seLinux.type to .seLinux.rule
3. Rename .runAsUser.type to .runAsUser.rule
4. Rename .seLinux.SELinuxOptions

1,2,3 as suggested by thockin in #22159.
I added 3 for consistency with 2.
2016-03-03 11:49:48 -08:00
k8s-merge-robot ad69472a48 Merge pull request #21583 from sjenning/rm-unused-func
Auto commit by PR queue bot
2016-03-03 03:48:15 -08:00
k8s-merge-robot d81d823ca5 Merge pull request #22393 from eparis/blunderbuss
Auto commit by PR queue bot
2016-03-02 18:51:56 -08:00
Eric Paris 5e5a823294 Move blunderbuss assignees into tree 2016-03-02 20:46:32 -05:00
Tim St. Clair 246b389275 Move test-only volume files to test-only volume package 2016-02-29 14:44:28 -08:00
Paul Morie 26471d5723 Remove sentinel file from atomic writer 2016-02-27 16:09:06 -05:00
k8s-merge-robot 18130824b2 Merge pull request #21758 from childsb/1308588
Auto commit by PR queue bot
2016-02-26 22:33:20 -08:00
Fabio Yeon 658f7ef397 Merge pull request #21738 from jsafrane/devel/fix-admission
Hot-fix admission of volumes that are being provisioned.
2016-02-26 16:05:04 -08:00
childsb 8d4aa5d387 Run through gofmt -s 2016-02-25 13:00:12 -06:00
Dogan Narinc and Yoseph Samuel aa65fe8903 Fix EBS when hostname is not the node name
Similar to #11543, the local hostname is not guaranteed to be the node
name, as the AWS cloud provider looks up node name using
`private-dns-name`. This value can be different such as when using a
private hosted zone.

The previous code uses GetHostName(), which fails in this case. Instead,
pass in an empty string so the aws cloud provider will use the cached
self instance to find the instance id.

Authors: @balooo, @dogan-sky, @jsravn
2016-02-25 16:45:44 +00:00
childsb 7fed6f9f47 Remove host command sniffing from CanSupport(..) 2016-02-23 17:13:14 -06:00
childsb 61f6c3bc13 Remove the check for a gluster specific binary in 'canSupport'. Causes problems in containerized kube. 2016-02-23 09:40:35 -06:00
Jan Safranek a304e3478d Hot-fix admission of volumes that are being provisioned.
This is a first-aid bandage to let admission controller ignore persistent
volumes that are being provisioned right now and thus may not exist in
external cloud infrastructure yet.
2016-02-23 09:46:40 +01:00
k8s-merge-robot 11cdc919f5 Merge pull request #21364 from pwittrock/macdu
Auto commit by PR queue bot
2016-02-22 10:09:03 -08:00
Seth Jennings c3e707ea0f remove unused function 2016-02-19 15:19:15 -06:00
Paul Morie f8d58ac708 Make flake in configMap update e2e easier to debug 2016-02-19 15:01:20 -05:00
k8s-merge-robot eb45154996 Merge pull request #21348 from caesarxuchao/generate-fake-for-1-2
Auto commit by PR queue bot
2016-02-18 23:02:05 -08:00
Chao Xu ad46715f51 generate fake client for release_1_2 2016-02-17 16:10:02 -08:00
laushinka 7ef585be22 Spelling fixes inspired by github.com/client9/misspell 2016-02-18 06:58:05 +07:00
Phillip Wittrock 1e5175594d Fix volume secret_test.go on darwin by not checking volume usage metrics 2016-02-17 12:56:37 -08:00
Paul Morie d1dc259ef2 ConfigMap volume source 2016-02-14 16:19:17 -05:00
k8s-merge-robot 315a509340 Merge pull request #20900 from jsafrane/devel/volume-names
Auto commit by PR queue bot
2016-02-13 17:58:29 -08:00
k8s-merge-robot e3938ce15f Merge pull request #20495 from childsb/recycler_template_fix
Auto commit by PR queue bot
2016-02-13 11:30:14 -08:00
Jan Safranek 1d0b1c227b Add PV.Name into names of generated GCE/AWS/OSP volumes.
Volume names have now format <cluster-name>-dynamic-<pv-name>.

pv-name is guaranteed to be unique in Kubernetes cluster, adding
<cluster-name> ensures we don't conflict with any running cluster
in the cloud project (kube-controller-manager --cluster-name=XXX).

'kubernetes' is the default cluster name.
2016-02-12 09:46:59 +01:00
Paul Morie cc967972a1 Run atomic_writer_test only on linux 2016-02-11 22:10:51 -05:00
childsb df68b6c38f Updated recycler template with exit code on failure. 2016-02-10 14:48:39 -06:00
childsb aa9bd70de9 Merge remote-tracking branch 'upstream/master' into recycler_template_fix 2016-02-10 14:47:55 -06:00
k8s-merge-robot 3b41600e5a Merge pull request #20929 from thockin/go-vet
Auto commit by PR queue bot
2016-02-10 12:13:55 -08:00
k8s-merge-robot 10b6074a2c Merge pull request #20397 from pmorie/atomic-projections
Auto commit by PR queue bot
2016-02-10 01:54:46 -08:00
Paul Morie b750ea678f Generalize atomically updating projections into volumes 2016-02-10 03:19:52 -05:00
k8s-merge-robot c6ed624bfb Merge pull request #19503 from markturansky/attacher_interface
Auto commit by PR queue bot
2016-02-09 20:50:41 -08:00
k8s-merge-robot 2ec49efd54 Merge pull request #19945 from Clarifai/fix-formatting
Auto commit by PR queue bot
2016-02-09 16:05:00 -08:00
Tim Hockin 7cab7bd472 fix a few go-vet errors 2016-02-09 13:20:31 -08:00
k8s-merge-robot beb5d01f9c Merge pull request #17221 from rootfs/azure
Auto commit by PR queue bot
2016-02-08 22:46:12 -08:00
k8s-merge-robot fec0d127b3 Merge pull request #15938 from justinsb/aws_ebs_cleanup
Auto commit by PR queue bot
2016-02-08 21:42:52 -08:00
Huamin Chen d7e4b826b9 support Azure File Service volume
Signed-off-by: Huamin Chen <hchen@redhat.com>
2016-02-09 01:07:12 +00:00
markturansky a242a3d5fe Added Attacher/Detacher interfaces and support to kubelet 2016-02-07 16:55:58 -05:00
k8s-merge-robot 1b52e0ec3a Merge pull request #20210 from jsafrane/devel/gce-tags
Auto commit by PR queue bot
2016-02-05 21:36:25 -08:00
k8s-merge-robot fcf9c4a1e4 Merge pull request #19741 from pwittrock/syncfsmetrics
Auto commit by PR queue bot
2016-02-05 17:54:22 -08:00
Phillip Wittrock 3de94cd23c Supply volume fs metrics to server/stats/handler.go
* Metrics will not be expose until they are hooked up to a handler
* Metrics are not cached and expose a dos vector, this must be fixed before release or the stats should not be exposed through an api endpoint
2016-02-05 16:00:24 -08:00
Chao Xu 184440f8ef rename release_1_2 to internalclientset 2016-02-05 14:02:28 -08:00
Chao Xu 1b047f8e67 rename legacy to core 2016-02-04 14:26:56 -08:00
Chao Xu f9f5736b01 grep sed 2016-02-03 13:06:07 -08:00
Justin Santa Barbara 12d407da19 AWS EBS: Remove copied-and-pasted udevadm code
This is in GCE to deal with a GCE specific issue; there's no reason to
believe we need the same logic on AWS.
2016-02-03 20:56:17 +00:00
Justin Santa Barbara d10e3debc7 AWS EBS: HandleCrash moved to util/runtime 2016-02-03 20:43:14 +00:00
Justin Santa Barbara 089951e7b4 Fix typo in comment: succefully -> successfully 2016-02-03 20:43:14 +00:00
Justin Santa Barbara 6c87a4be7c AWS: Handle deleting volume that no longer exists
The tests in particular double-delete volumes, so we need to handle this
graciously.
2016-02-03 20:43:14 +00:00
Justin Santa Barbara 1ae1db6027 AWS: Update copy-paste of GCE PD code to latest version
We are (sadly) using a copy-and-paste of the GCE PD code for AWS EBS.
This code hasn't been updated in a while, and it seems that the GCE code
has some code to make volume mounting more robust that we should copy.
2016-02-03 20:43:14 +00:00
Rudi Chiarito a0831a2378 Mass fix of Infof and co. missing the trailing "f", even when formatting placeholders are used 2016-02-03 11:34:59 -05:00
Paul Morie 180bed7b5c Fix a couple typos 2016-02-02 15:39:33 -05:00
childsb 08bd4e30f6 Fix for the recycler template. Use rm to scrub volume, include . prefixed items but explude "." and ".." 2016-02-02 11:02:09 -06:00
Jan Safranek 220163f67d Fixed races in Cinder volume attach/detach.
Add a mutex to guard SetUpAt() and TearDownAt() calls - they should not
run in parallel.  There is a race in these calls when there are two pods
using the same volume, one of them is dying and the other one starting.

TearDownAt() checks that a volume is not needed by any pods and detaches the
volume. It does so by counting how many times is the volume mounted
(GetMountRefs() call below).

When SetUpAt() of the starting pod already attached the volume and did not mount
it yet, TearDownAt() of the dying pod will detach it - GetMountRefs() does not
count with this volume.

These two threads run in parallel:

 dying pod.TearDownAt("myVolume")          starting pod.SetUpAt("myVolume")
   |                                       |
   |                                       AttachDisk("myVolume")
   refs, err := mount.GetMountRefs()       |
   Unmount("myDir")                        |
   if refs == 1 {                          |
   |  |                                    Mount("myVolume", "myDir")
   |  |                                    |
   |  DetachDisk("myVolume")               |
   |                                       start containers - OOPS! The volume is detached!
   |
   finish the pod cleanup


Also, add some logs to cinder plugin for easier debugging in the future, add
a test and update the fake mounter to know about bind mounts.
2016-02-02 14:38:49 +01:00
k8s-merge-robot 78eaa6635e Merge pull request #20080 from nagarjung/flocker_feature
Auto commit by PR queue bot
2016-02-02 02:45:14 -08:00
k8s-merge-robot 71727385e8 Merge pull request #20069 from BugRoger/cephfs_subtree_mount_master
Auto commit by PR queue bot
2016-02-02 02:15:35 -08:00
Michael Schmidt 1373e0139d CephFS: Add subdir Option for Changing Mounted Root Directory 2016-02-01 22:01:19 +01:00
harry 1032067ff9 Replace runtime reference by pkg 2016-02-01 21:06:44 +08:00
Chao Xu c72d234bbf replacing handwritten client in several controllers 2016-01-31 15:42:02 -08:00
Fabio Yeon 7205a160ac Remove all instances of "/tmp" from unit tests and replace with a common
tmp directory creator. Exception is documented.
2016-01-27 16:11:22 -08:00
Jan Safranek 23cd0913f7 Tag dynamically created GCE PD disks.
GCE disks don't have tags, we must encode the tags into Description field.
It's encoded as JSON, which is both human and machine readable:
description: '{"kubernetes.io/created-for/pv/name":"pv-gce-oxwts","kubernetes.io/created-for/pvc/name":"myclaim","kubernetes.io/created-for/pvc/namespace":"default"}'
2016-01-27 15:16:05 +01:00
k8s-merge-robot 3f5e417999 Merge pull request #19502 from swagiaal/internalize-ownership
Auto commit by PR queue bot
2016-01-26 23:06:39 -08:00
k8s-merge-robot 52cb4c1d9d Merge pull request #18445 from resouer/fix-emptydir
Auto commit by PR queue bot
2016-01-26 02:45:54 -08:00
k8s-merge-robot 2286bd3a38 Merge pull request #19961 from mamikonyana/newrepo
Auto commit by PR queue bot
2016-01-25 19:51:23 -08:00
Nagarjun 39b1874041 Add GetEnvOr() feature to utils Package 2016-01-25 16:08:35 +05:30
harry 0fa5b6c4f7 Add e2e test for wrapper volumes
Use git server in e2e and refactor wrapper builder

Update e2e test to use a fake git server
2016-01-24 16:57:44 +08:00
Clayton Coleman 33085c0cf2 Update tests to handle codec changes 2016-01-22 13:27:26 -05:00
Arsen Mamikonyan 8b5e9e2885 Change repository references to https://github.com/kubernetes/kubernetes 2016-01-22 10:23:14 -05:00
Alex Mohr eaa61a72b0 Merge pull request #17919 from justinsb/multizone_gce
Ubernetes Lite support for GCE
2016-01-21 10:22:34 -08:00
k8s-merge-robot 6cf3a4b5f0 Merge pull request #18957 from jsafrane/devel/pv-name-tag
Auto commit by PR queue bot
2016-01-21 05:55:12 -08:00
k8s-merge-robot 0f6f521beb Merge pull request #18959 from jsafrane/devel/cinder-tags
Auto commit by PR queue bot
2016-01-21 03:33:58 -08:00
Justin Santa Barbara 43cbfb74fe Ubernetes Lite GCE: Support multiple zones in GCE cloud provider
We adapt the existing code to work across all zones in a region.

We require a feature-flag to enable Ubernetes-Lite

Reasons:

* There are some behavioural changes if users create volumes with
the same name in two zones.
* We don't want to make one API call per zone if we're not running
Ubernetes-Lite.
* Ubernetes-Lite is still experimental.

There isn't a parallel flag implemented for AWS, because at the moment
there would be no behaviour changes from this.
2016-01-20 23:04:53 -05:00
Jan Safranek f912870784 openstack: Use common SafeFormatAndMount() for mounting.
There is no reason for OpenStack + Cinder to use it's own variant of format
& mount.
2016-01-19 09:36:38 +01:00
Mike Danese 33c72db59c Merge pull request #19528 from resouer/strings-util
Create strings pkg to fix util issue
2016-01-14 21:19:17 -08:00
harry 7405c7899b Add strings pkg to hold strings utils
Replace funtions with strings pkg

Fix all references and rename the pkg
2016-01-15 12:37:50 +08:00
Sami Wagiaalla 52c9a3abe2 RBD return output in error case 2016-01-14 11:33:33 -05:00
Sami Wagiaalla 7767698459 Remove SupportsOwnershipManagement volume attribute 2016-01-13 10:37:10 -05:00
Sami Wagiaalla 4ac151321a Call SetVolumeOwnership from volume plugins 2016-01-13 10:37:10 -05:00
Sami Wagiaalla f650648aae Add fsGroup to SetUp and SetUpAt 2016-01-13 10:37:10 -05:00
Sami Wagiaalla e33e4ae055 Move manageVolumeOwnership to pkg/volume/volume.go 2016-01-13 10:36:59 -05:00
k8s-merge-robot 6f50699b93 Merge pull request #17192 from SuhasAnand/SuhasAnand-rbd-attachdisk-fix_unnecessary_call
Auto commit by PR queue bot
2016-01-11 22:07:00 -08:00
harry c0d49450e4 Fix volume wrapper doesn't have name
Integration test
2016-01-11 15:08:26 +08:00
Jan Safranek 8c48250a55 Add an integration test for volume tags. 2016-01-08 19:09:29 +01:00
Chakravarthy Nelluri fa76de79e5 Add support for flex volume. Flex volume adds support for thirdparty(vendor)
volumes and custom mounts.
2015-12-23 14:11:38 -08:00
Jimmi Dyson 041ab17a67 Bump cadvisor to fix interface stats bugs & improve performance
Includes necessary godep upgrades for docker & systemd packages as well as
migrating from docker/libcontainer to opencontainers/runc/libcontainer.
2015-12-21 17:07:21 +00:00
Jan Safranek 815d1e0865 Tag OpenStack Cinder volumes created by Kubernetes.
This synchronizes Cinder with AWS EBS code, where we already tag volumes with
claim.Namespace and claim.Name (and pv.Name, as suggested in separate PR).
2015-12-21 11:36:42 +01:00
k8s-merge-robot a45c87864e Merge pull request #18621 from pmorie/devel/provisioner-gce
Auto commit by PR queue bot
2015-12-17 09:20:29 -08:00
Paul Morie 14368fd5e2 Skip volume metrics test on os x 2015-12-16 17:16:38 -05:00
Jan Safranek d4f6271b21 Implement Creater and Deleter interfaces for GCE PD. 2015-12-16 16:14:01 -05:00
Jan Safranek e8f08a969c Extract common function for OpenStack checking. 2015-12-16 14:23:16 -05:00
Jan Safranek 2f06ebf9b7 Implement Creater and Deleter interfaces for Cinder. 2015-12-16 14:23:14 -05:00
Saad Ali 3968a5e63c Merge pull request #18601 from pmorie/devel/provisioner-aws
Dynamic provisioner for AWS EBS
2015-12-16 10:51:35 -08:00
Jan Safranek 6ff5286df9 Implement Creater and Deleter interfaces for AWS EBS.
Also mark the created EBS volumes with tags, so the admin knows
who/what created the volumes.
2015-12-15 10:22:49 +01:00
Paul Morie eb89c2519a Fix assumptions about tmpfs in metrics du tests 2015-12-14 10:47:21 -05:00
Wojciech Tyczynski 960808bf08 Switch to versioned ListOptions in client. 2015-12-14 14:26:09 +01:00
markturansky 4fc1bf1f23 Added PersistentVolumeController 2015-12-11 10:33:30 -05:00
Phillip Wittrock c67ce887f2 Volume Metrics Interface and base implementation.
- Add volume.MetricsProvider function to Volume interface.
- Add volume.MetricsDu for providing metrics via executing "du".
- Add volulme.MetricsNil for unsupported Volumes.
2015-12-09 16:06:24 -08:00
k8s-merge-robot 5f7019ab9d Merge pull request #16877 from anish/iscsi_iface
Auto commit by PR queue bot
2015-12-09 11:52:37 -08:00
Anish Bhatt 6e46fa1fd4 Add support for open-iscsi transports.
This enables use of software or hardware transports viz. be2iscsi,
bnx2i, cxgb3i, cxgb4i, qla4xx, iser and ocs. The default transport
(tcp) happens to be called "default".

Use of non-default transports changes the disk path to the following format:
/dev/disk/by-path/pci-<pci_id>-ip-<portal>-iscsi-<iqn>-lun-<lun_id>
2015-12-08 17:28:06 -08:00
Wojciech Tyczynski b0fcb5adef Pass ListOptions to List in ListWatch. 2015-12-07 11:53:53 +01:00
k8s-merge-robot 13b0fd3cda Merge pull request #16942 from swagiaal/distinguish-format-and-mount
Auto commit by PR queue bot
2015-12-03 10:51:26 -08:00
Wojciech Tyczynski 6dcb689d4e Simplify List() signature in clients. 2015-12-03 09:54:07 +01:00
Sami Wagiaalla 66c905d63e Distinguish normal mount from format and mount in SafeFormatAndMount 2015-12-02 11:16:00 -05:00
k8s-merge-robot 8a8639d7af Merge pull request #17863 from wojtek-t/only_list_options_in_watch
Auto commit by PR queue bot
2015-12-02 06:28:28 -08:00
k8s-merge-robot ac68536d44 Merge pull request #17832 from wojtek-t/list_options_in_list
Auto commit by PR queue bot
2015-12-02 02:34:17 -08:00
Harry Zhang 70a9c0bf56 Add directory in GitRepo and updated tests.
Update validate and gitRepo

Update generated code
2015-12-02 00:20:38 +08:00
Wojciech Tyczynski 8343c8ce6c Pass ListOptions to List() methods. 2015-12-01 15:00:36 +01:00
Wojciech Tyczynski d2dfc912e6 Simplify Watch() signature in clients. 2015-12-01 14:19:26 +01:00
k8s-merge-robot d3d3f94e2f Merge pull request #17711 from anish/iqn_format
Auto commit by PR queue bot
2015-11-26 23:22:17 -08:00
Phillip Wittrock 6b358e43dd Merge pull request #17747 from saad-ali/fixErrorCreatingPDTry2
Refactor GCE wrapper library to allow execution from E2E test suite
2015-11-25 15:57:42 -08:00
saadali 42b200a0a0 Refactor GCE wrapper library to allow execution from E2E test suite
This reverts commit 147b6911f5, reversing
changes made to 6fd986065b.
2015-11-25 11:48:06 -08:00
Wojciech Tyczynski b6ef62af24 Use unversioned.ListOptions in clients. 2015-11-24 16:52:09 +01:00
Anish Bhatt 18c82f743c Support iqn as well as eui format for iSCSI entity names.
Supported formats are :
iqn.<date code>.<reversed domain>[:<optional suffix>]

eui.<eui-64 identifier>
2015-11-24 00:13:59 -08:00
Jerzy Szczepkowski 8a922e22be Revert "Refactor GCE wrapper library to allow execution from E2E test suite" 2015-11-23 09:24:32 +01:00
k8s-merge-robot 3fbf0cb810 Merge pull request #17276 from saad-ali/fixErrorCreatingPD
Auto commit by PR queue bot
2015-11-21 23:32:30 -08:00
saadali 882469dd7b Refactor GCE wrapper library to allow execution from E2E test suite 2015-11-20 11:41:10 -08:00
Paul Morie 911757486d Refactor volume.Builder.IsReadOnly() to volume.Builder.GetAttributes() 2015-11-13 23:34:48 -05:00
Suhas ab01a22fef rdb util: AttachDisk: Skip unnecessary call for waitforpath
Skip unnecessary call to waitforpath if found = true during the first call.
2015-11-12 16:32:10 -08:00
k8s-merge-robot 75ecc34417 Merge pull request #16723 from wulonghui/wulonghui-patch-4
Auto commit by PR queue bot
2015-11-04 04:59:16 -08:00
markturansky d3bb6575fb Revert "nfs: check if /sbin/mount.nfs* is present in CanSupport()"
This reverts commit 1b3a88dc87.
2015-11-03 16:09:57 -05:00
wulonghui 86abfb8d16 Delete all files and all hidden files without . & .. error for PV recycler 2015-11-03 17:34:25 +08:00
Sami Wagiaalla 1d352a16b8 Support volume relabling for pods which specify an SELinux label 2015-10-28 09:26:58 -04:00
Jerzy Szczepkowski 5ef087adab Merge pull request #16266 from wojtek-t/fix_handshake_reflector
Reuse TCP connections in Reflector between resync periods.
2015-10-27 10:36:18 +01:00
Daniel Smith b07dd73f26 Merge pull request #16053 from saad-ali/attachDetachMutextFix
Fix GCE Cloud/Attach/Detach stability issues
2015-10-26 13:05:27 -07:00
Wojciech Tyczynski d47e21f19f Reuse TCP connections in Reflector between resync periods. 2015-10-26 19:35:25 +01:00
Wojciech Tyczynski f4d75e0a0a Support timeout in watch requests 2015-10-24 13:12:49 +02:00
k8s-merge-robot e1559e9fb5 Merge pull request #15352 from pmorie/fsgroup
Auto commit by PR queue bot
2015-10-24 01:55:45 -07:00
saadali 19115b2a22 Fix GCE Cloudprovider waitForOp bug and make GCE attach/detach atomic operations. 2015-10-23 11:58:56 -07:00
k8s-merge-robot 8c9c69b73e Merge pull request #15236 from rootfs/gluster_cansupport
Auto commit by PR queue bot
2015-10-22 19:22:50 -07:00
Paul Morie 3cd12f5e05 FSGroup implementation 2015-10-22 16:40:59 -04:00
k8s-merge-robot 407ff583c4 Merge pull request #16032 from rootfs/nfs-support
Auto commit by PR queue bot
2015-10-22 09:08:27 -07:00
Huamin Chen 1b3a88dc87 nfs: check if /sbin/mount.nfs* is present in CanSupport()
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-21 13:47:41 -04:00
Huamin Chen 1665ba4d33 glusterfs: check if mount helper is present
Reported-By: Deepak C Shetty <deepakcs@redhat.com>
Signed-off-by: Huamin Chen <hchen@redhat.com>

glusterfs: return more verbose error message to help diagnose
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-20 14:27:37 -04:00
Steve Milner 8da2d4002f Fixes remaining imports per #15319 2015-10-20 07:13:13 -04:00
k8s-merge-robot c4779fbc4f Merge pull request #15475 from jijun2/fix-cni_test
Auto commit by PR queue bot
2015-10-20 01:30:24 -07:00
eulerzgy f8f9afb874 alias local packagename for pkg/util/errors 2015-10-18 09:37:46 +08:00
k8s-merge-robot a6634adc1c Merge pull request #15435 from zhengguoyong/adjust_package_name_pkgcloudprovider
Auto commit by PR queue bot
2015-10-16 08:30:32 -07:00
k8s-merge-robot 372fb373aa Merge pull request #15562 from rootfs/iscsi-umount
Auto commit by PR queue bot
2015-10-16 07:12:23 -07:00
jijun2 bf6e8cbff7 test: using ioutil.TempDir in unit tests per #15176
update

update mode

delete /tmp

update

use ioutil.TempDir instead of static tmp dir

use ioutil.TempDir instead of static tmp dir
2015-10-16 09:21:46 +08:00
k8s-merge-robot 407f9b9e42 Merge pull request #15555 from rootfs/iscsi-def-port
Auto commit by PR queue bot
2015-10-15 07:22:18 -07:00
k8s-merge-robot 130e6a7a4d Merge pull request #15468 from feiskyer/volume-typo-error
Auto commit by PR queue bot
2015-10-15 05:08:33 -07:00
Huamin Chen 76df88f68b iscsi: make portal builder testable
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-14 13:30:30 -04:00
Huamin Chen 69a1f33dd5 iscsi: format disk if no filesystem is found
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-14 10:30:04 -04:00
Huamin Chen 9ca96abd46 iscsi: use global path to retrieve iscsi portal and iqn
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-14 09:48:07 -04:00
Dawn Chen 0f22551e90 Merge pull request #15296 from anish/iscsi_fixes
Fix extraneous entries in iscsi path format, update README and sample json
2015-10-13 11:51:06 -07:00
Huamin Chen 340cfcc284 iscsi: if port is not provided, use default 3260 for target portal
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-13 13:31:59 -04:00
Anish Bhatt 6d9e9561e8 Fix extraneous entries in iscsi path format
Code comments currently claim the default iscsi mount path as

kubernetes.io/pod/iscsi/<portal>-iqn-<iqn>-lun-<id>, however actual
path being used is
kubernetes.io/iscsi/iscsi/<portal>-iqn-<iqn>-lun-<id>

This leads to ultimate path being similar to this :

kubernetes.io/iscsi/iscsi/...iqn-iqn...-lun-N

Both iscsi and iqn are repated twice for no reason, since "iqn" is
required by spec to be part of an iqn. This is also  wrong on
multiple leves as actual allowed naming formats are :

iqn.2001-04.com.example:storage:diskarrays-sn-a8675309
eui.02004567A425678D
(RFC 3720 3.2.6.3)

and in the second case "iqn-eui" in the path would be misleading.

Change this to a more reasonable path of
kubernetes.io/iscsi/<portal>-<iqn>-lun-<id>

which also aligns up with how the /dev/by-path and sysfs entries
are created for iscsi devices on linux

  * -- *

Update iSCSI README and sample json file

There seems to have been quite a skew in recent updates to these
files adding in wrong info or info that no longer lines up the
sample config with the README.

Fixed the following issues :
* Fix discrepancy in samples json using initiator iqn from previous
  linked example as target iqn (which was just wrong)
* Generate sample output and README from the same json config provided.
* Remove recommendation to edit initiator name, this is not required
  (open-iscsi warns against editing this manually and provides a utility
   for the same)
* Update docker inspect command to one that works.
* Use separate LUNs for separate mount points instead of re-using.
2015-10-13 10:08:52 -07:00
Dawn Chen de22206929 Merge pull request #15309 from rootfs/no_remount
rbd: no more remount.
2015-10-12 16:02:53 -07:00
feisky 8ad6b8f035 Fix typo error 2015-10-12 18:57:56 +08:00
eulerzgy 8b174f7f33 adjust package name for pkg/cloudprovider 2015-10-10 16:44:54 +08:00
James DeFelice a7c06e57ac flocker unit test should clean up after itself 2015-10-08 22:40:36 +00:00
Huamin Chen de41fd3960 rbd: no more remount.
remount was originally needed to ensure rw/ro is set correctly. There is no such need since mount is using exec interface

Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-10-08 13:50:41 -04:00
saadali 1bb4809841 Prevent GCE PD attach code from succeding if disk failed to attach. 2015-10-07 14:07:33 -07:00
Alex Robinson 608244fbb0 Merge pull request #14044 from rootfs/rbd_enhancement
Multiple rbd volume enhancements
2015-10-05 17:36:11 -07:00
Tim Hockin 6260759c51 Merge pull request #14328 from agonzalezro/flocker
Add flocker volume plugin
2015-10-02 16:02:18 -07:00
Álex González fa39c2b032 Add flocker volume plugin
Flocker [1] is an open-source container data volume manager for
Dockerized applications.

This PR adds a volume plugin for Flocker.
The plugin interfaces the Flocker Control Service REST API [2] to
attachment attach the volume to the pod.

Each kubelet host should run Flocker agents (Container Agent and Dataset
Agent).

The kubelet will also require environment variables that contain the
host and port of the Flocker Control Service. (see Flocker architecture
[3] for more).

- `FLOCKER_CONTROL_SERVICE_HOST`
- `FLOCKER_CONTROL_SERVICE_PORT`

The contribution introduces a new 'flocker' volume type to the API with
fields:

- `datasetName`: which indicates the name of the dataset in Flocker
  added to metadata;
- `size`: a human-readable number that indicates the maximum size of the
  requested dataset.

Full documentation can be found docs/user-guide/volumes.md and examples
can be found at the examples/ folder

[1] https://clusterhq.com/flocker/introduction/
[2] https://docs.clusterhq.com/en/1.3.1/reference/api.html
[3] https://docs.clusterhq.com/en/1.3.1/concepts/architecture.html
2015-10-01 01:10:00 +01:00
saadali 7771151767 GCE PD attach/detach operations should poll to verify successful completion 2015-09-29 14:32:06 -07:00
Huamin Chen 8dbbcefdec rbd: don't use /dev/rbd/pool/image; use sysfs to find rbd device instead
rbd: if rbd image is not formatted, format it to the designated filesystem type

rbd: update example README.md and include instructions to get base64 encoded Ceph secret

if rbd fails to lock image, unmap the image before exiting

Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-09-29 10:13:01 -04:00
Eric Tune f614e7df63 Merge pull request #14168 from tmrts/refactor/tests
Refactor downward API volume plugin test
2015-09-22 13:52:31 -07:00
k8s-merge-robot 6dad530a1f Merge pull request #12599 from rootfs/fc_volume
Auto commit by PR queue bot
2015-09-20 17:20:26 -07:00
k8s-merge-robot 568c0331b0 Merge pull request #13650 from markturansky/prov_creater
Auto commit by PR queue bot
2015-09-20 16:57:36 -07:00
Huamin Chen ed9a1bbd3a support fibre channel volume
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-09-18 19:15:31 -04:00
markturansky a1692e06e6 added pv attrs to volumeOptions, improved tests 2015-09-18 13:14:56 -04:00
markturansky 3bed0a2b5c Added volume.Creater interface and simple HostPath implementation 2015-09-18 13:14:56 -04:00
Tamer Tas 95ad0acf5e Refactor helper method in api/volume/downwardapi 2015-09-18 17:50:08 +03:00
Tamer Tas c01bac90eb Refactor downward API volume plugin test 2015-09-18 13:56:13 +03:00
Daniel Martí 586cb9126a Move pkg/util.Time to pkg/api/unversioned.Time
Along with our time.Duration wrapper, as suggested by @lavalamp.
2015-09-17 17:51:27 -07:00
k8s-merge-robot c1eb1a1b2f Merge pull request #13791 from fgrzadkowski/fix_secrets_in_docker
Auto commit by PR queue bot
2015-09-17 15:13:29 -07:00
k8s-merge-robot 055f5ff9b9 Merge pull request #13649 from markturansky/prov_deleter
Auto commit by PR queue bot
2015-09-17 12:59:45 -07:00
markturansky c2de9e9647 Added volume.Deleter interface and simple HostPath implementation 2015-09-17 12:08:58 -04:00
Filip Grzadkowski 7fe34f2050 Introduce nsenter writer for volume plugins 2015-09-17 16:40:29 +02:00
Kel Cecil 6687075300 Correct AWS EBS comment 2015-09-16 14:04:36 -04:00
markturansky 7bc55b5aea configurable pv recyclers 2015-09-15 12:48:25 -04:00
k8s-merge-robot dc1561fbca Merge pull request #13784 from BugRoger/aws_ebs_picks_up_kubelet_cloud_provider
Auto commit by PR queue bot
2015-09-14 22:25:16 -07:00
k8s-merge-robot 8189460809 Merge pull request #13844 from tummychow/label-deps-2
Auto commit by PR queue bot
2015-09-14 12:56:24 -07:00
Jeff Lowdermilk e25ae7fdb2 Merge pull request #13833 from caesarxuchao/central-latest
[WIP] Making a generic latest package
2015-09-14 09:26:58 -07:00
tummychow a21c52a766 Move util/validation files to their own package 2015-09-13 00:46:52 -07:00
k8s-merge-robot 69b283bd27 Merge pull request #13807 from bodgit/glusterfs
Auto commit by PR queue bot
2015-09-12 21:33:09 -07:00
Chao Xu 64bf839e9f refactor tests to use testapi rather than latest directly 2015-09-11 17:32:23 -07:00
Chao Xu dd6c121d7f massive changes 2015-09-11 17:31:47 -07:00
Matt Dainty 8bbc86d83c Override the GlusterFS log file location
GlusterFS by default uses a log file based on the mountpoint path munged into a
file, i.e. `/mnt/foo/bar` becomes `/var/log/glusterfs/mnt-foo-bar.log`.

On certain Kubernetes environments this can result in a log file that exceeds
the 255 character length most filesystems impose on filenames causing the mount
to fail. Instead, use the `log-file` mount option to place the log file under
the kubelet plugin directory with a filename of our choosing keeping it fairly
persistent in the case of troubleshooting.
2015-09-11 18:29:00 +01:00
Daniel Smith b225c1d47a Run gofmt (separate commit for easy rebases) 2015-09-10 17:17:59 -07:00
Daniel Smith 15b30b8b09 Move version agnostic parts of client
pkg/client/unversioned/cache -> pkg/client/cache
pkg/client/unversioned/record -> pkg/client/record
2015-09-10 17:17:59 -07:00
tummychow 78ce5da988 Move util.StringSet into its own package
A lot of packages use StringSet, but they don't use anything else from
the util package. Moving StringSet into another package will shrink
their dependency trees significantly.
2015-09-10 12:04:15 -07:00
Michael Schmidt fcda3556cd pass cloudProvider from Kubelet to volume plugins 2015-09-10 10:28:48 +02:00
markturansky a5feac5739 improved recycler unit test 2015-09-07 14:44:49 -04:00
Quinton Hoole e5e2bc9580 Merge pull request #10833 from markturansky/loosen_binding
Allow PV/Claim matching on inexact access modes
2015-09-04 09:06:31 -07:00
Sami Wagiaalla 9ca9ab1b66 iSCSI Plugin: Remove remounting of device in global path.
This code was originally added because the first mount call did not
respect the ro option. This no longer seems to be the cause so there
is no need to use remount.

Signed-off-by: Sami Wagiaalla <swagiaal@redhat.com>
2015-09-03 15:59:27 -04:00
markturansky 0e7f73ad67 expand volume.Spec to include full Volume and PV 2015-09-03 08:57:32 -04:00
k8s-merge-robot e8cda9dc92 Merge pull request #13310 from markturansky/volume_config
Auto commit by PR queue bot
2015-09-02 14:05:30 -07:00
Brendan Burns 2df5010834 Merge branch 'sdminonne-container_sidecar' 2015-09-02 10:42:08 -07:00
Brendan Burns 74ef517097 Merge pull request #6649 from rootfs/wip-cephfs
add Ceph FS volume plugin
2015-09-02 09:48:15 -07:00
k8s-merge-robot f5c2d90c3a Merge pull request #12293 from deads2k/testclient-specific-reaction
Auto commit by PR queue bot
2015-09-02 09:18:24 -07:00
Salvatore Dario Minonne f4dc0653aa adding downward api volume plugin 2015-09-01 22:23:03 +02:00
Huamin Chen fe559f2726 implement Ceph FS volume plugin and add to e2e volume test
Signed-off-by: Huamin Chen <hchen@redhat.com>
2015-09-01 14:05:17 -04:00
deads2k 7e180c258d update testclient for delegating reaction chain 2015-09-01 12:58:35 -04:00
markturansky 68358fd308 Added VolumeConfig to volumes 2015-09-01 12:04:26 -04:00
Sreekanth Pothanis f5da6b34ce Cinder Volume Plugin 2015-08-30 19:56:27 -07:00
Prashanth B 05b205bab6 Revert "Volume Plugin for Cinder; Openstack Block Storage" 2015-08-28 10:56:24 -07:00
Prashanth B 8d0d54ffed Merge pull request #6689 from spothanis/cinder-vol-plugin
Volume Plugin for Cinder; Openstack Block Storage
2015-08-28 10:47:31 -07:00
markturansky 0b6030f50c added better matching for PV access modes 2015-08-27 15:34:07 -04:00
Sami Wagiaalla ab0258f259 Support formatting and mounting GCE PD without 'safe_format_and_mount'
The GCE PD plugin uses safe_format_and_mount found on standard GCE images:

https://github.com/GoogleCloudPlatform/compute-image-packages/blob/master/google-startup-scripts/usr/share/google/safe_format_and_mount

On custom images where this is not available pods fail to format and
mount GCE PDs. This patch uses linux utilities in a similar way to the
safe_format_and_mount script to format and mount the GCE PD and AWS EBC
devices. That is first attempt a mount. If mount fails try to use file to
investigate the device. If 'file' fails to get any information about
the device and simply returns "data" then assume the device is not
formatted and format it and attempt to mount it again.

Signed-off-by: Sami Wagiaalla <swagiaal@redhat.com>
2015-08-26 11:53:40 -04:00
Sreekanth Pothanis c841a20361 Cinder Volume Plugin 2015-08-25 15:13:56 -07:00
Saad Ali b05cab0bc5 Merge pull request #6945 from eparis/IsMountPoint
Rename IsMountPoint to IsLikelyNotMountPoint
2015-08-19 12:47:51 -07:00
Kris Rousey ae6c64d9bb Moving everyone to unversioned client 2015-08-18 10:23:03 -07:00
Eric Paris f125ad88ce Rename IsMountPoint to IsLikelyNotMountPoint
IsLikelyNotMountPoint determines if a directory is not a mountpoint.
It is fast but not necessarily ALWAYS correct. If the path is in fact
a bind mount from one part of a mount to another it will not be detected.
mkdir /tmp/a /tmp/b; mount --bin /tmp/a /tmp/b; IsLikelyNotMountPoint("/tmp/b")
will return true. When in fact /tmp/b is a mount point. So this patch
renames the function and switches it from a positive to a negative (I
could think of a good positive name). This should make future users of
this function aware that it isn't quite perfect, but probably good
enough.
2015-08-14 18:45:43 -04:00
Bryan Stenson 9541414742 create cloudprovider "providers" package
move all providers into new package
    update all references to old package path
2015-08-11 22:36:51 -07:00
Kris Rousey 565189f5b8 Correcting all go vet errors 2015-08-11 13:55:37 -07:00
Rohith dc23ded091 - fixing the complaint on the gofmt 2015-08-10 23:57:05 +01:00
Rohith bb31cd29ea - fixed the defencing of the rbd lock 2015-08-10 23:33:25 +01:00
Veres Lajos 9f77e49109 typofix - https://github.com/vlajos/misspell_fixer 2015-08-08 22:31:48 +01:00
Mike Danese fe6b15ba2f rewrite all links to issues to k8s links 2015-08-05 21:11:11 -07:00
Mike Danese 17defc7383 run gofmt on everything we touched 2015-08-05 17:52:56 -07:00
Mike Danese 8e33cbfa28 rewrite go imports 2015-08-05 17:30:03 -07:00
Mike Danese e58ea24d0b Merge pull request #12001 from uluyol/os-exp-hack
Add (stopgap) support for an experimental API prefix.
2015-07-31 10:15:06 -07:00
Muhammed Uluyol 58a875ac2c Add (stopgap) support for an experimental API prefix. 2015-07-30 18:14:29 -07:00
jiangyaoguo 8eeda24652 new builder and cleaner type for aws-ebs 2015-07-30 10:23:38 +08:00
Paul Morie 5394aa979f Make emptyDir volumes work for non-root UIDs 2015-07-29 18:36:51 -04:00
Brendan Burns 63cf00d24f Merge pull request #10424 from markturansky/readonly_fix
Auto commit by PR queue bot
2015-07-29 14:25:44 -07:00
Mike Danese f40b970bd9 Merge pull request #11987 from markturansky/recyc_fix
Fixed newRecycler func for HostPath & NFS
2015-07-29 13:11:08 -07:00
markturansky e8289ceb9d rebased and updated 2015-07-29 14:48:06 -04:00
markturansky 8639f24374 rebased and updated 2015-07-29 14:38:40 -04:00