Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // ErrKeyNotExists is returned when the key is not present in the object storage. ErrKeyNotExists = errors.New("key is not present in bucket") )
Functions ¶
This section is empty.
Types ¶
type DynamoDBAdapter ¶
func CreateDynamoDBAdapter ¶
func CreateDynamoDBAdapter() *DynamoDBAdapter
CreateDynamoDBAdapter creates 2 separate dynamoDB clients - one for healthcheck and another for general usage. These 2 dynamoDB clients are then used to construct a DynamoDBAdapter instance. Returns the DynamoDBAdapter instance.
func (*DynamoDBAdapter) DeleteLockFile ¶
func (d *DynamoDBAdapter) DeleteLockFile(ctx context.Context, projectName, clusterId string, keyFormat string) error
DeleteLockFile deletes terraform state lock file (related to the given cluster), from DynamoDB.
func (*DynamoDBAdapter) Healthcheck ¶
func (d *DynamoDBAdapter) Healthcheck() error
Healthcheck function checks whether the DynamoDB table for Terraform state locking exists or not.
type MinIOAdapter ¶
type MinIOAdapter struct {
// contains filtered or unexported fields
}
func CreateMinIOAdapter ¶
func CreateMinIOAdapter() *MinIOAdapter
CreateMinIOAdapter creates 2 MinIO clients first - one for healthcheck and one for general purpose. A MinIOAdapter instance is then constructed using those 2 clients and returned.
func (*MinIOAdapter) DeleteStateFile ¶
func (m *MinIOAdapter) DeleteStateFile(ctx context.Context, projectName, clusterId string, keyFormat string) error
DeleteStateFile deletes terraform state file (related to the given cluster), from MinIO bucket.
func (*MinIOAdapter) Healthcheck ¶
func (m *MinIOAdapter) Healthcheck() error
Healthcheck checks whether the MinIO bucket exists or not.