mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-04 04:08:16 +00:00 
			
		
		
		
	Adding ListMinions() API to pkg/client.
This commit is contained in:
		@@ -40,6 +40,7 @@ type Interface interface {
 | 
			
		||||
	ReplicationControllerInterface
 | 
			
		||||
	ServiceInterface
 | 
			
		||||
	VersionInterface
 | 
			
		||||
	MinionInterface
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// PodInterface has methods to work with Pod resources
 | 
			
		||||
@@ -74,6 +75,10 @@ type VersionInterface interface {
 | 
			
		||||
	ServerVersion() (*version.Info, error)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type MinionInterface interface {
 | 
			
		||||
	ListMinions() (api.MinionList, error)
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
// Client is the actual implementation of a Kubernetes client.
 | 
			
		||||
type Client struct {
 | 
			
		||||
	*RESTClient
 | 
			
		||||
@@ -322,3 +327,8 @@ func (c *Client) ServerVersion() (*version.Info, error) {
 | 
			
		||||
	}
 | 
			
		||||
	return &info, nil
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func (c *Client) ListMinions() (minionList api.MinionList, err error) {
 | 
			
		||||
	err = c.Get().Path("minions").Do().Into(&minionList)
 | 
			
		||||
	return
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user