Documentation ¶
Overview ¶
Package doctor provides tools to help validate environments and operational status.
Index ¶
- Variables
- func CanConnectToCluster() error
- func DoesSyncthingExist() error
- func HasClusterPermissions() error
- func HasClusterService() error
- func IsClusterConfigValid() error
- func IsClusterServiceHealthy() error
- func IsClusterVersionSupported() error
- func IsDockerGraphMatching() error
- func IsDockerStorageCompatible() error
- func IsDockerVersionCompatible() error
- func IsServiceCompatible() error
- func IsWatchRunning() error
- type Check
Constants ¶
This section is empty.
Variables ¶
var ( // KubernetesRange is the acceptible cluster versions KubernetesRange = ">=1.7.0" // DockerAPIRange is the acceptible range of API versions. DockerAPIRange = ">=1.25.0" // DockerRange is the user friendly version of DockerAPIRange. It is really // just for the error. DockerRange = ">=1.13.0" // DockerDriver is all the compatible storage drivers. DockerDriver = map[string]bool{ "overlay": true, "overlay2": true, } )
var CheckList = []Check{ Check{ Name: "Extra Binaries", Func: DoesSyncthingExist, }, Check{ Name: "Cluster Config", Func: IsClusterConfigValid, Type: "pre", }, Check{ Name: "Cluster Connection", Func: CanConnectToCluster, Type: "pre", }, Check{ Name: "Cluster Version", Func: IsClusterVersionSupported, Type: "pre", }, Check{ Name: "Cluster Permissions", Func: HasClusterPermissions, Type: "pre", }, Check{ Name: "Cluster Service", Func: HasClusterService, Type: "post", }, Check{ Name: "Service Health", Func: IsClusterServiceHealthy, Type: "post", }, Check{ Name: "Service Version", Func: IsServiceCompatible, Type: "post", }, Check{ Name: "Docker Version", Func: IsDockerVersionCompatible, Type: "post", }, Check{ Name: "Docker Storage Driver", Func: IsDockerStorageCompatible, Type: "post", }, Check{ Name: "Docker Storage Root", Func: IsDockerGraphMatching, Type: "post", }, Check{ Name: "Watch Running", Func: IsWatchRunning, }, }
CheckList is the full list of checks run by doctor.
Functions ¶
func CanConnectToCluster ¶
func CanConnectToCluster() error
CanConnectToCluster verifies, naively, that the cluster can be connected to and return a basic result.
func DoesSyncthingExist ¶
func DoesSyncthingExist() error
DoesSyncthingExist verifies that the local binary exists.
func HasClusterPermissions ¶
func HasClusterPermissions() error
HasClusterPermissions verifies that the current context/user is able to do everything required on the remote cluster.
func HasClusterService ¶
func HasClusterService() error
HasClusterService verifies that the cluster is running the service.
func IsClusterConfigValid ¶
func IsClusterConfigValid() error
IsClusterConfigValid verifies that the local configuration can be loaded and potentially used to connect to the cluster.
func IsClusterServiceHealthy ¶
func IsClusterServiceHealthy() error
IsClusterServiceHealthy verifies that the cluster service is healthy across all nodes.
func IsClusterVersionSupported ¶
func IsClusterVersionSupported() error
IsClusterVersionSupported verifies that the remote cluster's API version falls within the acceptable range.
func IsDockerGraphMatching ¶
func IsDockerGraphMatching() error
IsDockerGraphMatching checks to see if the configured graph directory (the location of the graph driver storage directories) matches what's configured in radar
func IsDockerStorageCompatible ¶
func IsDockerStorageCompatible() error
IsDockerStorageCompatible verifies that the remote cluster has been configured to use compatible docker storage drivers.
func IsDockerVersionCompatible ¶
func IsDockerVersionCompatible() error
IsDockerVersionCompatible verifies that the remote cluster is running a docker daemon with an API version that falls within the compatible range.
func IsServiceCompatible ¶
func IsServiceCompatible() error
IsServiceCompatible verifies that the remote service is compatible with the local client.
func IsWatchRunning ¶
func IsWatchRunning() error
IsWatchRunning verifies that watch is running and ready to go.