2016-03-30 15:54:16 -07:00
|
|
|
package dockerfile
|
|
|
|
|
2016-04-06 12:01:29 -07:00
|
|
|
import "fmt"
|
2016-03-30 15:54:16 -07:00
|
|
|
|
2016-04-06 12:01:29 -07:00
|
|
|
// platformSupports is gives users a quality error message if a Dockerfile uses
|
|
|
|
// a command not supported on the platform.
|
2016-03-30 15:54:16 -07:00
|
|
|
func platformSupports(command string) error {
|
|
|
|
switch command {
|
2016-05-04 11:06:54 -07:00
|
|
|
case "user", "stopsignal":
|
2016-03-30 15:54:16 -07:00
|
|
|
return fmt.Errorf("The daemon on this platform does not support the command '%s'", command)
|
|
|
|
}
|
|
|
|
return nil
|
|
|
|
}
|