Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
f385dfcb
Commit
f385dfcb
authored
May 26, 2017
by
Michelle Au
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Address review comments
parent
5fcb82dd
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
local.go
pkg/volume/local/local.go
+2
-2
volume_util.go
test/e2e/framework/volume_util.go
+1
-1
persistent_volumes-local.go
test/e2e/storage/persistent_volumes-local.go
+2
-2
No files found.
pkg/volume/local/local.go
View file @
f385dfcb
...
@@ -216,6 +216,7 @@ func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) err
...
@@ -216,6 +216,7 @@ func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) err
glog
.
V
(
4
)
.
Infof
(
"attempting to mount %s"
,
dir
)
glog
.
V
(
4
)
.
Infof
(
"attempting to mount %s"
,
dir
)
err
=
m
.
mounter
.
Mount
(
m
.
globalPath
,
dir
,
""
,
options
)
err
=
m
.
mounter
.
Mount
(
m
.
globalPath
,
dir
,
""
,
options
)
if
err
!=
nil
{
if
err
!=
nil
{
glog
.
Errorf
(
"Mount of volume %s failed: %v"
,
dir
,
err
)
notMnt
,
mntErr
:=
m
.
mounter
.
IsLikelyNotMountPoint
(
dir
)
notMnt
,
mntErr
:=
m
.
mounter
.
IsLikelyNotMountPoint
(
dir
)
if
mntErr
!=
nil
{
if
mntErr
!=
nil
{
glog
.
Errorf
(
"IsLikelyNotMountPoint check failed: %v"
,
mntErr
)
glog
.
Errorf
(
"IsLikelyNotMountPoint check failed: %v"
,
mntErr
)
...
@@ -226,7 +227,7 @@ func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) err
...
@@ -226,7 +227,7 @@ func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) err
glog
.
Errorf
(
"Failed to unmount: %v"
,
mntErr
)
glog
.
Errorf
(
"Failed to unmount: %v"
,
mntErr
)
return
err
return
err
}
}
notMnt
,
mntErr
:
=
m
.
mounter
.
IsLikelyNotMountPoint
(
dir
)
notMnt
,
mntErr
=
m
.
mounter
.
IsLikelyNotMountPoint
(
dir
)
if
mntErr
!=
nil
{
if
mntErr
!=
nil
{
glog
.
Errorf
(
"IsLikelyNotMountPoint check failed: %v"
,
mntErr
)
glog
.
Errorf
(
"IsLikelyNotMountPoint check failed: %v"
,
mntErr
)
return
err
return
err
...
@@ -238,7 +239,6 @@ func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) err
...
@@ -238,7 +239,6 @@ func (m *localVolumeMounter) SetUpAt(dir string, fsGroup *types.UnixGroupID) err
}
}
}
}
os
.
Remove
(
dir
)
os
.
Remove
(
dir
)
glog
.
Errorf
(
"Mount of volume %s failed: %v"
,
dir
,
err
)
return
err
return
err
}
}
...
...
test/e2e/framework/volume_util.go
View file @
f385dfcb
...
@@ -76,7 +76,7 @@ type VolumeTestConfig struct {
...
@@ -76,7 +76,7 @@ type VolumeTestConfig struct {
ServerImage
string
ServerImage
string
// Ports to export from the server pod. TCP only.
// Ports to export from the server pod. TCP only.
ServerPorts
[]
int
ServerPorts
[]
int
// Commands to run in the co
m
tainer image.
// Commands to run in the co
n
tainer image.
ServerCmds
[]
string
ServerCmds
[]
string
// Arguments to pass to the container image.
// Arguments to pass to the container image.
ServerArgs
[]
string
ServerArgs
[]
string
...
...
test/e2e/storage/persistent_volumes-local.go
View file @
f385dfcb
...
@@ -165,8 +165,8 @@ func cleanupLocalVolume(config *localTestConfig, volume *localTestVolume) {
...
@@ -165,8 +165,8 @@ func cleanupLocalVolume(config *localTestConfig, volume *localTestVolume) {
}
}
By
(
"Removing the test directory"
)
By
(
"Removing the test directory"
)
writ
eCmd
:=
fmt
.
Sprintf
(
"rm -r %s"
,
volume
.
containerDir
)
remov
eCmd
:=
fmt
.
Sprintf
(
"rm -r %s"
,
volume
.
containerDir
)
runLocalUtil
(
config
,
volume
.
node
.
Name
,
writ
eCmd
)
runLocalUtil
(
config
,
volume
.
node
.
Name
,
remov
eCmd
)
}
}
func
runLocalUtil
(
config
*
localTestConfig
,
nodeName
,
cmd
string
)
{
func
runLocalUtil
(
config
*
localTestConfig
,
nodeName
,
cmd
string
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment