Skip to content

Commit

Permalink
Clean up unix vs linux usage
Browse files Browse the repository at this point in the history
FreeBSD does not support cgroups or namespaces, which the code suggested, and is not supported
in runc anyway right now. So clean up the file naming to use `_linux` where appropriate.

Signed-off-by: Justin Cormack <[email protected]>
  • Loading branch information
justincormack committed May 12, 2017
1 parent 21ef2e3 commit 4c67360
Show file tree
Hide file tree
Showing 10 changed files with 2 additions and 18 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build linux freebsd

package configs

type FreezerState string
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build freebsd linux

package configs

import "fmt"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build linux freebsd

package configs

import (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build linux freebsd

package configs

import (
Expand Down
2 changes: 1 addition & 1 deletion libcontainer/configs/namespaces_unsupported.go
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// +build !linux,!freebsd
// +build !linux

package configs

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build linux freebsd

package libcontainer

// cgroup restoring strategy provided by criu
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build linux freebsd

package devices

import (
Expand Down
2 changes: 1 addition & 1 deletion libcontainer/devices/devices_unsupported.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
// +build windows
// +build !linux

package devices
2 changes: 0 additions & 2 deletions main_unix.go → main_linux.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build linux

package main

import (
Expand Down
2 changes: 0 additions & 2 deletions main_solaris.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
// +build solaris

package main

import "github.com/urfave/cli"
Expand Down

0 comments on commit 4c67360

Please sign in to comment.