Documentation ¶
Index ¶
- type AADMock
- type ACIMock
- type ACIProvider
- func (p *ACIProvider) Capacity() v1.ResourceList
- func (p *ACIProvider) CreatePod(pod *v1.Pod) error
- func (p *ACIProvider) DeletePod(pod *v1.Pod) error
- func (p *ACIProvider) GetContainerLogs(namespace, podName, containerName string, tail int) (string, error)
- func (p *ACIProvider) GetPod(namespace, name string) (*v1.Pod, error)
- func (p *ACIProvider) GetPodStatus(namespace, name string) (*v1.PodStatus, error)
- func (p *ACIProvider) GetPods() ([]*v1.Pod, error)
- func (p *ACIProvider) NodeAddresses() []v1.NodeAddress
- func (p *ACIProvider) NodeConditions() []v1.NodeCondition
- func (p *ACIProvider) NodeDaemonEndpoints() *v1.NodeDaemonEndpoints
- func (p *ACIProvider) OperatingSystem() string
- func (p *ACIProvider) UpdatePod(pod *v1.Pod) error
- type AcsCredential
- type AuthConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AADMock ¶
type AADMock struct { OnAcquireToken func(http.ResponseWriter, *http.Request) // contains filtered or unexported fields }
AADMock implements a AAD mock server .
func (*AADMock) GetServerURL ¶
GetServerURL returns the mock server URL.
type ACIMock ¶
type ACIMock struct { OnCreate func(string, string, string, *aci.ContainerGroup) (int, interface{}) OnGetContainerGroups func(string, string) (int, interface{}) OnGetContainerGroup func(string, string, string) (int, interface{}) // contains filtered or unexported fields }
ACIMock implements a Azure Container Instance mock server.
func NewACIMock ¶
func NewACIMock() *ACIMock
NewACIMock creates a new Azure Container Instance mock server.
func (*ACIMock) Close ¶
func (mock *ACIMock) Close()
Close terminates the Azure Container Instance mock server.
func (*ACIMock) GetServerURL ¶
GetServerURL returns the mock server URL.
type ACIProvider ¶
type ACIProvider struct {
// contains filtered or unexported fields
}
ACIProvider implements the virtual-kubelet provider interface and communicates with Azure's ACI APIs.
func NewACIProvider ¶
func NewACIProvider(config string, rm *manager.ResourceManager, nodeName, operatingSystem string, internalIP string, daemonEndpointPort int32) (*ACIProvider, error)
NewACIProvider creates a new ACIProvider.
func (*ACIProvider) Capacity ¶
func (p *ACIProvider) Capacity() v1.ResourceList
Capacity returns a resource list containing the capacity limits set for ACI.
func (*ACIProvider) CreatePod ¶
func (p *ACIProvider) CreatePod(pod *v1.Pod) error
CreatePod accepts a Pod definition and creates an ACI deployment
func (*ACIProvider) DeletePod ¶
func (p *ACIProvider) DeletePod(pod *v1.Pod) error
DeletePod deletes the specified pod out of ACI.
func (*ACIProvider) GetContainerLogs ¶
func (p *ACIProvider) GetContainerLogs(namespace, podName, containerName string, tail int) (string, error)
GetContainerLogs returns the logs of a pod by name that is running inside ACI.
func (*ACIProvider) GetPod ¶
func (p *ACIProvider) GetPod(namespace, name string) (*v1.Pod, error)
GetPod returns a pod by name that is running inside ACI returns nil if a pod by that name is not found.
func (*ACIProvider) GetPodStatus ¶
func (p *ACIProvider) GetPodStatus(namespace, name string) (*v1.PodStatus, error)
GetPodStatus returns the status of a pod by name that is running inside ACI returns nil if a pod by that name is not found.
func (*ACIProvider) GetPods ¶
func (p *ACIProvider) GetPods() ([]*v1.Pod, error)
GetPods returns a list of all pods known to be running within ACI.
func (*ACIProvider) NodeAddresses ¶
func (p *ACIProvider) NodeAddresses() []v1.NodeAddress
NodeAddresses returns a list of addresses for the node status within Kubernetes.
func (*ACIProvider) NodeConditions ¶
func (p *ACIProvider) NodeConditions() []v1.NodeCondition
NodeConditions returns a list of conditions (Ready, OutOfDisk, etc), for updates to the node status within Kubernetes.
func (*ACIProvider) NodeDaemonEndpoints ¶
func (p *ACIProvider) NodeDaemonEndpoints() *v1.NodeDaemonEndpoints
NodeDaemonEndpoints returns NodeDaemonEndpoints for the node status within Kubernetes.
func (*ACIProvider) OperatingSystem ¶
func (p *ACIProvider) OperatingSystem() string
OperatingSystem returns the operating system that was provided by the config.
type AcsCredential ¶
type AcsCredential struct { Cloud string `json:"cloud"` TenantID string `json:"tenantId"` SubscriptionID string `json:"subscriptionId"` ClientID string `json:"aadClientId"` ClientSecret string `json:"aadClientSecret"` ResourceGroup string `json:"resourceGroup"` Region string `json:"location"` }
AcsCredential represents the credential file for ACS
func NewAcsCredential ¶
func NewAcsCredential(filepath string) (*AcsCredential, error)
NewAcsCredential returns an AcsCredential struct from file path
type AuthConfig ¶
type AuthConfig struct { Username string `json:"username,omitempty"` Password string `json:"password,omitempty"` Auth string `json:"auth,omitempty"` Email string `json:"email,omitempty"` ServerAddress string `json:"serveraddress,omitempty"` IdentityToken string `json:"identitytoken,omitempty"` RegistryToken string `json:"registrytoken,omitempty"` }
AuthConfig is the secret returned from an ImageRegistryCredential
Directories ¶
Path | Synopsis |
---|---|
Package azure and subpackages are used to perform operations using the Azure Resource Manager (ARM).
|
Package azure and subpackages are used to perform operations using the Azure Resource Manager (ARM). |
aci
Package aci provides tools for interacting with the Azure Container Instances API.
|
Package aci provides tools for interacting with the Azure Container Instances API. |
api
Package api contains the common code shared by all Azure API libraries.
|
Package api contains the common code shared by all Azure API libraries. |
resourcegroups
Package resourcegroups provides tools for interacting with the Azure Resource Manager resource groups API.
|
Package resourcegroups provides tools for interacting with the Azure Resource Manager resource groups API. |