Documentation
¶
Index ¶
- func CMKStatusTypeChoices() []string
- func ProviderTypeChoices() []string
- type AwsOut
- type CMKAccessCheckTriggerOut
- type CMKAccessorsListOut
- type CMKCreateIn
- type CMKCreateOut
- type CMKDeleteOut
- type CMKGetOut
- type CMKHandler
- func (h *CMKHandler) CMKAccessCheckTrigger(ctx context.Context, project string, cmkid string) (*CMKAccessCheckTriggerOut, error)
- func (h *CMKHandler) CMKAccessorsList(ctx context.Context, project string) (*CMKAccessorsListOut, error)
- func (h *CMKHandler) CMKCreate(ctx context.Context, project string, in *CMKCreateIn) (*CMKCreateOut, error)
- func (h *CMKHandler) CMKDelete(ctx context.Context, project string, cmkid string) (*CMKDeleteOut, error)
- func (h *CMKHandler) CMKGet(ctx context.Context, project string, cmkid string) (*CMKGetOut, error)
- func (h *CMKHandler) CMKUpdate(ctx context.Context, project string, cmkid string, in *CMKUpdateIn) (*CMKUpdateOut, error)
- type CMKStatusType
- type CMKUpdateIn
- type CMKUpdateOut
- type GcpOut
- type Handler
- type OciOut
- type ProviderType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CMKStatusTypeChoices ¶
func CMKStatusTypeChoices() []string
func ProviderTypeChoices ¶
func ProviderTypeChoices() []string
Types ¶
type CMKAccessCheckTriggerOut ¶
type CMKAccessCheckTriggerOut struct {
CreatedAt time.Time `json:"created_at"` // Created At
DefaultCMK bool `json:"default_cmk"` // Default Cmk
Id string `json:"id"` // ID
Resource string `json:"resource"`
UpdatedAt time.Time `json:"updated_at"` // Updated At
}
CMKAccessCheckTriggerOut CMK
type CMKAccessorsListOut ¶
type CMKAccessorsListOut struct {
Aws *AwsOut `json:"aws,omitempty"` // CMKAccessorsAWS
Gcp GcpOut `json:"gcp"` // CMKAccessorsGCP
Oci OciOut `json:"oci"` // CMKAccessorsOCI
}
CMKAccessorsListOut CMKAccessors
type CMKCreateIn ¶
type CMKCreateIn struct {
DefaultCMK *bool `json:"default_cmk,omitempty"` // Mark the created CMK as default for all newly created services.
Provider ProviderType `json:"provider"` // CMK provider
Resource string `json:"resource"` // Resource name
}
CMKCreateIn CMKCreateRequestBody
type CMKCreateOut ¶
type CMKCreateOut struct {
CreatedAt time.Time `json:"created_at"` // Created at
DefaultCMK bool `json:"default_cmk"` // CMK is used as a default for all newly created services.
Id string `json:"id"` // Customer Managed Key identifier (CMK ID)
Provider ProviderType `json:"provider"` // CMK provider
Resource string `json:"resource"` // Resource name
Status CMKStatusType `json:"status"` // Status
UpdatedAt time.Time `json:"updated_at"` // Updated at
}
CMKCreateOut CMK
type CMKDeleteOut ¶
type CMKDeleteOut struct {
CreatedAt time.Time `json:"created_at"` // Created At
DefaultCMK bool `json:"default_cmk"` // Default Cmk
Id string `json:"id"` // ID
Resource string `json:"resource"`
UpdatedAt time.Time `json:"updated_at"` // Updated At
}
CMKDeleteOut CMK
type CMKGetOut ¶
type CMKGetOut struct {
CreatedAt time.Time `json:"created_at"` // Created At
DefaultCMK bool `json:"default_cmk"` // Default Cmk
Id string `json:"id"` // ID
Resource string `json:"resource"`
UpdatedAt time.Time `json:"updated_at"` // Updated At
}
CMKGetOut CMK
type CMKHandler ¶
type CMKHandler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler(doer doer) CMKHandler
func (*CMKHandler) CMKAccessCheckTrigger ¶
func (h *CMKHandler) CMKAccessCheckTrigger(ctx context.Context, project string, cmkid string) (*CMKAccessCheckTriggerOut, error)
func (*CMKHandler) CMKAccessorsList ¶
func (h *CMKHandler) CMKAccessorsList(ctx context.Context, project string) (*CMKAccessorsListOut, error)
func (*CMKHandler) CMKCreate ¶
func (h *CMKHandler) CMKCreate(ctx context.Context, project string, in *CMKCreateIn) (*CMKCreateOut, error)
func (*CMKHandler) CMKDelete ¶
func (h *CMKHandler) CMKDelete(ctx context.Context, project string, cmkid string) (*CMKDeleteOut, error)
func (*CMKHandler) CMKUpdate ¶
func (h *CMKHandler) CMKUpdate(ctx context.Context, project string, cmkid string, in *CMKUpdateIn) (*CMKUpdateOut, error)
type CMKStatusType ¶
type CMKStatusType string
const ( CMKStatusTypeCurrent CMKStatusType = "current" CMKStatusTypeDeleted CMKStatusType = "deleted" CMKStatusTypeOld CMKStatusType = "old" )
type CMKUpdateIn ¶
type CMKUpdateIn struct {
DefaultCMK *bool `json:"default_cmk,omitempty"` // Mark the created CMK as default for all newly created services.
}
CMKUpdateIn CMKUpdateRequestBody
type CMKUpdateOut ¶
type CMKUpdateOut struct {
CreatedAt time.Time `json:"created_at"` // Created At
DefaultCMK bool `json:"default_cmk"` // Default Cmk
Id string `json:"id"` // ID
Resource string `json:"resource"`
UpdatedAt time.Time `json:"updated_at"` // Updated At
}
CMKUpdateOut CMK
type GcpOut ¶
type GcpOut struct {
AccessGroup string `json:"access_group"` // Access Group
}
GcpOut CMKAccessorsGCP
type Handler ¶
type Handler interface {
// CMKAccessCheckTrigger trigger an access check on CMK
// POST /v1/project/{project}/secrets/cmks/{cmk_id}/access_check
// https://api.aiven.io/doc/#tag/Secrets/operation/CMKAccessCheckTrigger
CMKAccessCheckTrigger(ctx context.Context, project string, cmkid string) (*CMKAccessCheckTriggerOut, error)
// CMKAccessorsList list CMK accessors
// GET /v1/project/{project}/secrets/cmks/accessors
// https://api.aiven.io/doc/#tag/Secrets/operation/CMKAccessorsList
CMKAccessorsList(ctx context.Context, project string) (*CMKAccessorsListOut, error)
// CMKCreate create new CMK
// POST /v1/project/{project}/secrets/cmks
// https://api.aiven.io/doc/#tag/Secrets/operation/CMKCreate
CMKCreate(ctx context.Context, project string, in *CMKCreateIn) (*CMKCreateOut, error)
// CMKDelete delete CMK
// DELETE /v1/project/{project}/secrets/cmks/{cmk_id}
// https://api.aiven.io/doc/#tag/Secrets/operation/CMKDelete
CMKDelete(ctx context.Context, project string, cmkid string) (*CMKDeleteOut, error)
// CMKGet get CMK details
// GET /v1/project/{project}/secrets/cmks/{cmk_id}
// https://api.aiven.io/doc/#tag/Secrets/operation/CMKGet
CMKGet(ctx context.Context, project string, cmkid string) (*CMKGetOut, error)
// CMKUpdate update CMK
// POST /v1/project/{project}/secrets/cmks/{cmk_id}
// https://api.aiven.io/doc/#tag/Secrets/operation/CMKUpdate
CMKUpdate(ctx context.Context, project string, cmkid string, in *CMKUpdateIn) (*CMKUpdateOut, error)
}
type OciOut ¶
type OciOut struct {
AccessGroup string `json:"access_group"` // Access Group
}
OciOut CMKAccessorsOCI
type ProviderType ¶
type ProviderType string
const ( ProviderTypeAws ProviderType = "aws" ProviderTypeGcp ProviderType = "gcp" ProviderTypeOci ProviderType = "oci" )
Click to show internal directories.
Click to hide internal directories.