CloudProvider is an abstraction for providing cloud-specific information.
| 30 | |
| 31 | // CloudProvider is an abstraction for providing cloud-specific information. |
| 32 | type CloudProvider interface { |
| 33 | // IsActiveProvider determines whether this is the cloud provider operating |
| 34 | // this instance. |
| 35 | IsActiveProvider() bool |
| 36 | // GetInstanceType gets the type of instance this process is running on. |
| 37 | // The behavior is undefined if this is not the active provider. |
| 38 | GetInstanceType() info.InstanceType |
| 39 | // GetInstanceType gets the ID of the instance this process is running on. |
| 40 | // The behavior is undefined if this is not the active provider. |
| 41 | GetInstanceID() info.InstanceID |
| 42 | } |
| 43 | |
| 44 | var providers = map[info.CloudProvider]CloudProvider{} |
| 45 |
no outgoing calls
no test coverage detected
searching dependent graphs…