mirror of
https://github.com/docker/compose.git
synced 2025-10-16 12:58:49 +02:00
Signed-off-by: aiordache <anca.iordache@docker.com> Signed-off-by: Nicolas De Loof <nicolas.deloof@gmail.com>
31 lines
882 B
Go
31 lines
882 B
Go
package amazon
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/docker/ecs-plugin/pkg/docker"
|
|
)
|
|
|
|
type secretsAPI interface {
|
|
CreateSecret(ctx context.Context, secret docker.Secret) (string, error)
|
|
InspectSecret(ctx context.Context, id string) (docker.Secret, error)
|
|
ListSecrets(ctx context.Context) ([]docker.Secret, error)
|
|
DeleteSecret(ctx context.Context, id string, recover bool) error
|
|
}
|
|
|
|
func (c client) CreateSecret(ctx context.Context, secret docker.Secret) (string, error) {
|
|
return c.api.CreateSecret(ctx, secret)
|
|
}
|
|
|
|
func (c client) InspectSecret(ctx context.Context, id string) (docker.Secret, error) {
|
|
return c.api.InspectSecret(ctx, id)
|
|
}
|
|
|
|
func (c client) ListSecrets(ctx context.Context) ([]docker.Secret, error) {
|
|
return c.api.ListSecrets(ctx)
|
|
}
|
|
|
|
func (c client) DeleteSecret(ctx context.Context, id string, recover bool) error {
|
|
return c.api.DeleteSecret(ctx, id, recover)
|
|
}
|