Clean up unused code
Signed-off-by: Akihiro Suda <suda.kyoto@gmail.com>
This commit is contained in:
parent
7268eb97bc
commit
d231260868
4 changed files with 1 additions and 62 deletions
|
@ -523,26 +523,6 @@ func (container *Container) ShouldRestart() bool {
|
|||
return shouldRestart
|
||||
}
|
||||
|
||||
// AddBindMountPoint adds a new bind mount point configuration to the container.
|
||||
func (container *Container) AddBindMountPoint(name, source, destination string, rw bool) {
|
||||
container.MountPoints[destination] = &volume.MountPoint{
|
||||
Name: name,
|
||||
Source: source,
|
||||
Destination: destination,
|
||||
RW: rw,
|
||||
}
|
||||
}
|
||||
|
||||
// AddLocalMountPoint adds a new local mount point configuration to the container.
|
||||
func (container *Container) AddLocalMountPoint(name, destination string, rw bool) {
|
||||
container.MountPoints[destination] = &volume.MountPoint{
|
||||
Name: name,
|
||||
Driver: volume.DefaultDriverName,
|
||||
Destination: destination,
|
||||
RW: rw,
|
||||
}
|
||||
}
|
||||
|
||||
// AddMountPointWithVolume adds a new mount point configured with a volume to the container.
|
||||
func (container *Container) AddMountPointWithVolume(destination string, vol volume.Volume, rw bool) {
|
||||
container.MountPoints[destination] = &volume.MountPoint{
|
||||
|
|
|
@ -1,13 +0,0 @@
|
|||
// +build !windows
|
||||
|
||||
package image
|
||||
|
||||
func getOSVersion() string {
|
||||
// For Linux, images do not specify a version.
|
||||
return ""
|
||||
}
|
||||
|
||||
func hasOSFeature(_ string) bool {
|
||||
// Linux currently has no OS features
|
||||
return false
|
||||
}
|
|
@ -1,27 +0,0 @@
|
|||
package image
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/docker/docker/pkg/system"
|
||||
)
|
||||
|
||||
// Windows OS features
|
||||
const (
|
||||
FeatureWin32k = "win32k" // The kernel windowing stack is required
|
||||
)
|
||||
|
||||
func getOSVersion() string {
|
||||
v := system.GetOSVersion()
|
||||
return fmt.Sprintf("%d.%d.%d", v.MajorVersion, v.MinorVersion, v.Build)
|
||||
}
|
||||
|
||||
func hasOSFeature(f string) bool {
|
||||
switch f {
|
||||
case FeatureWin32k:
|
||||
return system.HasWin32KSupport()
|
||||
default:
|
||||
// Unrecognized feature.
|
||||
return false
|
||||
}
|
||||
}
|
|
@ -258,8 +258,7 @@ func (r *Root) validateName(name string) error {
|
|||
// localVolume implements the Volume interface from the volume package and
|
||||
// represents the volumes created by Root.
|
||||
type localVolume struct {
|
||||
m sync.Mutex
|
||||
usedCount int
|
||||
m sync.Mutex
|
||||
// unique name of the volume
|
||||
name string
|
||||
// path is the path on the host where the data lives
|
||||
|
|
Loading…
Reference in a new issue