mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-05-03 14:54:53 -04:00
metadata: move subnetCIDR to InstanceMetadata
This commit is contained in:
parent
0cdc7886ee
commit
dd007f4772
9 changed files with 28 additions and 55 deletions
|
@ -23,8 +23,6 @@ type ProviderMetadata interface {
|
|||
List(ctx context.Context) ([]metadata.InstanceMetadata, error)
|
||||
// Self retrieves the current instance.
|
||||
Self(ctx context.Context) (metadata.InstanceMetadata, error)
|
||||
// GetSubnetworkCIDR retrieves the subnetwork CIDR for the current instance.
|
||||
GetSubnetworkCIDR(ctx context.Context) (string, error)
|
||||
// GetLoadBalancerEndpoint retrieves the load balancer endpoint.
|
||||
GetLoadBalancerEndpoint(ctx context.Context) (string, error)
|
||||
// GetInstance retrieves an instance using its providerID.
|
||||
|
@ -92,9 +90,6 @@ type stubProviderMetadata struct {
|
|||
GetLoadBalancerEndpointErr error
|
||||
GetLoadBalancerEndpointResp string
|
||||
|
||||
GetSubnetworkCIDRErr error
|
||||
GetSubnetworkCIDRResp string
|
||||
|
||||
ListErr error
|
||||
ListResp []metadata.InstanceMetadata
|
||||
|
||||
|
@ -115,10 +110,6 @@ func (m *stubProviderMetadata) GetLoadBalancerEndpoint(ctx context.Context) (str
|
|||
return m.GetLoadBalancerEndpointResp, m.GetLoadBalancerEndpointErr
|
||||
}
|
||||
|
||||
func (m *stubProviderMetadata) GetSubnetworkCIDR(ctx context.Context) (string, error) {
|
||||
return m.GetSubnetworkCIDRResp, m.GetSubnetworkCIDRErr
|
||||
}
|
||||
|
||||
func (m *stubProviderMetadata) List(ctx context.Context) ([]metadata.InstanceMetadata, error) {
|
||||
return m.ListResp, m.ListErr
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue