2021-09-15 17:06:09 -07:00
|
|
|
package plugin
|
|
|
|
|
|
|
|
|
|
import (
|
2023-06-02 08:55:14 -07:00
|
|
|
"github.com/hashicorp/boundary-plugin-aws/plugin/service/host"
|
|
|
|
|
"github.com/hashicorp/boundary-plugin-aws/plugin/service/storage"
|
2021-09-15 17:06:09 -07:00
|
|
|
pb "github.com/hashicorp/boundary/sdk/pbs/plugin"
|
2023-04-17 11:00:12 +01:00
|
|
|
)
|
2021-09-22 17:00:37 -07:00
|
|
|
|
2023-03-20 11:02:17 -07:00
|
|
|
// Ensure that AWSPlugin implementings the following services:
|
|
|
|
|
//
|
|
|
|
|
// HostPluginServiceServer
|
2023-05-25 22:19:43 -07:00
|
|
|
// StoragePluginServiceServer
|
2021-09-15 17:06:09 -07:00
|
|
|
var (
|
2023-05-25 22:19:43 -07:00
|
|
|
_ pb.HostPluginServiceServer = (*host.HostPlugin)(nil)
|
|
|
|
|
_ pb.StoragePluginServiceServer = (*storage.StoragePlugin)(nil)
|
2021-09-15 17:06:09 -07:00
|
|
|
)
|
|
|
|
|
|
2023-03-20 11:02:17 -07:00
|
|
|
// AwsPlugin contains a collection of all aws plugin services.
|
|
|
|
|
type AwsPlugin struct {
|
|
|
|
|
// HostPlugin implements the HostPluginServiceServer interface for
|
|
|
|
|
// supporting dynamically sourcing hosts from Amazon EC2
|
|
|
|
|
*host.HostPlugin
|
2023-05-25 22:19:43 -07:00
|
|
|
|
|
|
|
|
// StoragePlugin implements the StoragePluginServiceServer interface for
|
|
|
|
|
// supporting storing and retrieving BSR files from Amazon S3
|
|
|
|
|
*storage.StoragePlugin
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
func NewAwsPlugin() *AwsPlugin {
|
|
|
|
|
return &AwsPlugin{
|
|
|
|
|
HostPlugin: &host.HostPlugin{},
|
|
|
|
|
StoragePlugin: &storage.StoragePlugin{},
|
|
|
|
|
}
|
2021-12-06 11:40:44 -08:00
|
|
|
}
|