Merge pull request #19502 from swagiaal/internalize-ownership

Auto commit by PR queue bot
This commit is contained in:
k8s-merge-robot
2016-01-26 23:06:39 -08:00
43 changed files with 219 additions and 227 deletions

View File

@@ -120,20 +120,19 @@ var _ volume.Builder = &gitRepoVolumeBuilder{}
func (b *gitRepoVolumeBuilder) GetAttributes() volume.Attributes {
return volume.Attributes{
ReadOnly: false,
Managed: true,
SupportsOwnershipManagement: false,
SupportsSELinux: true, // xattr change should be okay, TODO: double check
ReadOnly: false,
Managed: true,
SupportsSELinux: true, // xattr change should be okay, TODO: double check
}
}
// SetUp creates new directory and clones a git repo.
func (b *gitRepoVolumeBuilder) SetUp() error {
return b.SetUpAt(b.GetPath())
func (b *gitRepoVolumeBuilder) SetUp(fsGroup *int64) error {
return b.SetUpAt(b.GetPath(), fsGroup)
}
// SetUpAt creates new directory and clones a git repo.
func (b *gitRepoVolumeBuilder) SetUpAt(dir string) error {
func (b *gitRepoVolumeBuilder) SetUpAt(dir string, fsGroup *int64) error {
if volumeutil.IsReady(b.getMetaDir()) {
return nil
}
@@ -143,7 +142,7 @@ func (b *gitRepoVolumeBuilder) SetUpAt(dir string) error {
if err != nil {
return err
}
if err := wrapped.SetUpAt(dir); err != nil {
if err := wrapped.SetUpAt(dir, fsGroup); err != nil {
return err
}