Documentation
¶
Index ¶
- func AddCommandsTo(rootCmd *cobra.Command)
- func AddMCRIPSecAddOn(cmd *cobra.Command, args []string, noColor bool) error
- func BuyMCR(cmd *cobra.Command, args []string, noColor bool) error
- func CreateMCRPrefixFilterList(cmd *cobra.Command, args []string, noColor bool) error
- func DeleteMCR(cmd *cobra.Command, args []string, noColor bool) error
- func DeleteMCRPrefixFilterList(cmd *cobra.Command, args []string, noColor bool) error
- func GetMCR(cmd *cobra.Command, args []string, noColor bool, outputFormat string) error
- func GetMCRPrefixFilterList(cmd *cobra.Command, args []string, noColor bool, outputFormat string) error
- func GetMCRStatus(cmd *cobra.Command, args []string, noColor bool, outputFormat string) error
- func ListMCRPrefixFilterLists(cmd *cobra.Command, args []string, noColor bool, outputFormat string) error
- func ListMCRResourceTags(cmd *cobra.Command, args []string, noColor bool, outputFormat string) error
- func ListMCRs(cmd *cobra.Command, args []string, noColor bool, outputFormat string) error
- func LockMCR(cmd *cobra.Command, args []string, noColor bool) error
- func RestoreMCR(cmd *cobra.Command, args []string, noColor bool) error
- func UnlockMCR(cmd *cobra.Command, args []string, noColor bool) error
- func UpdateMCR(cmd *cobra.Command, args []string, noColor bool) error
- func UpdateMCRIPSecAddOn(cmd *cobra.Command, args []string, noColor bool) error
- func UpdateMCRPrefixFilterList(cmd *cobra.Command, args []string, noColor bool) error
- func UpdateMCRResourceTags(cmd *cobra.Command, args []string, noColor bool) error
- func ValidateMCR(cmd *cobra.Command, args []string, noColor bool) error
- type MCRStatus
- type MockMCRService
- func (m *MockMCRService) BuyMCR(ctx context.Context, req *megaport.BuyMCRRequest) (*megaport.BuyMCRResponse, error)
- func (m *MockMCRService) CreatePrefixFilterList(ctx context.Context, req *megaport.CreateMCRPrefixFilterListRequest) (*megaport.CreateMCRPrefixFilterListResponse, error)
- func (m *MockMCRService) DeleteMCR(ctx context.Context, req *megaport.DeleteMCRRequest) (*megaport.DeleteMCRResponse, error)
- func (m *MockMCRService) DeleteMCRPrefixFilterList(ctx context.Context, mcrID string, prefixFilterListID int) (*megaport.DeleteMCRPrefixFilterListResponse, error)
- func (m *MockMCRService) GetMCR(ctx context.Context, mcrUID string) (*megaport.MCR, error)
- func (m *MockMCRService) GetMCRPrefixFilterList(ctx context.Context, mcrID string, prefixFilterListID int) (*megaport.MCRPrefixFilterList, error)
- func (m *MockMCRService) GetMCRPrefixFilterLists(ctx context.Context, mcrID string) ([]*megaport.PrefixFilterList, error)
- func (m *MockMCRService) ListMCRPrefixFilterLists(ctx context.Context, mcrID string) ([]*megaport.PrefixFilterList, error)
- func (m *MockMCRService) ListMCRResourceTags(ctx context.Context, mcrID string) (map[string]string, error)
- func (m *MockMCRService) ListMCRs(ctx context.Context, req *megaport.ListMCRsRequest) ([]*megaport.MCR, error)
- func (m *MockMCRService) ModifyMCR(ctx context.Context, req *megaport.ModifyMCRRequest) (*megaport.ModifyMCRResponse, error)
- func (m *MockMCRService) ModifyMCRPrefixFilterList(ctx context.Context, mcrID string, prefixFilterListID int, ...) (*megaport.ModifyMCRPrefixFilterListResponse, error)
- func (m *MockMCRService) Reset()
- func (m *MockMCRService) RestoreMCR(ctx context.Context, mcrUID string) (*megaport.RestoreMCRResponse, error)
- func (m *MockMCRService) UpdateMCRIPsecAddOn(ctx context.Context, mcrID string, addOnUID string, tunnelCount int) error
- func (m *MockMCRService) UpdateMCRResourceTags(ctx context.Context, mcrID string, tags map[string]string) error
- func (m *MockMCRService) UpdateMCRWithAddOn(ctx context.Context, mcrID string, req megaport.MCRAddOnRequest) error
- func (m *MockMCRService) ValidateMCROrder(ctx context.Context, req *megaport.BuyMCRRequest) error
- func (m *MockMCRService) WaitForMCRReady(ctx context.Context, mcrID string, timeout time.Duration) error
- type Module
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddCommandsTo ¶
AddCommandsTo builds the mcr commands and adds them to the root command
func AddMCRIPSecAddOn ¶ added in v0.7.1
AddMCRIPSecAddOn adds an IPSec add-on to an existing MCR.
func GetMCRPrefixFilterList ¶
func GetMCRStatus ¶ added in v0.4.4
func ListMCRResourceTags ¶ added in v0.4.3
func UpdateMCRIPSecAddOn ¶ added in v0.7.1
UpdateMCRIPSecAddOn updates an existing IPSec add-on on an MCR. Setting tunnel-count to 0 disables IPSec.
func UpdateMCRResourceTags ¶ added in v0.4.3
Types ¶
type MockMCRService ¶
type MockMCRService struct {
BuyMCRResult *megaport.BuyMCRResponse
BuyMCRErr error
CapturedBuyMCRRequest *megaport.BuyMCRRequest
ValidateMCROrderErr error
GetMCRResult *megaport.MCR
GetMCRErr error
ListMCRsResult []*megaport.MCR
ListMCRsErr error
CapturedListMCRsRequest *megaport.ListMCRsRequest
DeleteMCRResult *megaport.DeleteMCRResponse
DeleteMCRErr error
CapturedDeleteMCRUID string
CapturedDeleteMCRRequest *megaport.DeleteMCRRequest
RestoreMCRResult *megaport.RestoreMCRResponse
RestoreMCRErr error
CapturedRestoreMCRUID string
CreateMCRPrefixFilterListResult *megaport.CreateMCRPrefixFilterListResponse
CreateMCRPrefixFilterListErr error
CapturedCreatePrefixFilterListRequest *megaport.CreateMCRPrefixFilterListRequest
ListMCRPrefixFilterListsResult []*megaport.PrefixFilterList
ListMCRPrefixFilterListsErr error
GetMCRPrefixFilterListResult *megaport.MCRPrefixFilterList
GetMCRPrefixFilterListErr error
ModifyMCRPrefixFilterListResult *megaport.ModifyMCRPrefixFilterListResponse
ModifyMCRPrefixFilterListErr error
CapturedModifyMCRPrefixFilterListRequest *megaport.MCRPrefixFilterList
DeleteMCRPrefixFilterListResult *megaport.DeleteMCRPrefixFilterListResponse
DeleteMCRPrefixFilterListErr error
ModifyMCRResult *megaport.ModifyMCRResponse
ModifyMCRErr error
CapturedModifyMCRRequest *megaport.ModifyMCRRequest
ListMCRResourceTagsResult map[string]string
ListMCRResourceTagsErr error
UpdateMCRResourceTagsErr error
CapturedUpdateMCRResourceTagsRequest map[string]string
GetMCRPrefixFilterListsResult []*megaport.PrefixFilterList
GetMCRPrefixFilterListsErr error
CapturedModifyPrefixFilterListMCRID string
CapturedModifyPrefixFilterListID int
CapturedModifyPrefixFilterList *megaport.MCRPrefixFilterList
ForceNilGetMCR bool
UpdateMCRWithAddOnErr error
CapturedUpdateMCRWithAddOnMCRID string
CapturedUpdateMCRWithAddOnReq megaport.MCRAddOnRequest
UpdateMCRIPsecAddOnErr error
CapturedUpdateMCRIPsecAddOnMCRID string
CapturedUpdateMCRIPsecAddOnUID string
CapturedUpdateMCRIPsecTunnelCount int
WaitForMCRReadyErr error
CapturedWaitForMCRReadyMCRID string
CapturedWaitForMCRReadyTimeout time.Duration
}
func (*MockMCRService) BuyMCR ¶
func (m *MockMCRService) BuyMCR(ctx context.Context, req *megaport.BuyMCRRequest) (*megaport.BuyMCRResponse, error)
func (*MockMCRService) CreatePrefixFilterList ¶
func (m *MockMCRService) CreatePrefixFilterList(ctx context.Context, req *megaport.CreateMCRPrefixFilterListRequest) (*megaport.CreateMCRPrefixFilterListResponse, error)
func (*MockMCRService) DeleteMCR ¶
func (m *MockMCRService) DeleteMCR(ctx context.Context, req *megaport.DeleteMCRRequest) (*megaport.DeleteMCRResponse, error)
func (*MockMCRService) DeleteMCRPrefixFilterList ¶
func (m *MockMCRService) DeleteMCRPrefixFilterList(ctx context.Context, mcrID string, prefixFilterListID int) (*megaport.DeleteMCRPrefixFilterListResponse, error)
func (*MockMCRService) GetMCRPrefixFilterList ¶
func (m *MockMCRService) GetMCRPrefixFilterList(ctx context.Context, mcrID string, prefixFilterListID int) (*megaport.MCRPrefixFilterList, error)
func (*MockMCRService) GetMCRPrefixFilterLists ¶
func (m *MockMCRService) GetMCRPrefixFilterLists(ctx context.Context, mcrID string) ([]*megaport.PrefixFilterList, error)
func (*MockMCRService) ListMCRPrefixFilterLists ¶
func (m *MockMCRService) ListMCRPrefixFilterLists(ctx context.Context, mcrID string) ([]*megaport.PrefixFilterList, error)
func (*MockMCRService) ListMCRResourceTags ¶
func (*MockMCRService) ListMCRs ¶ added in v0.3.8
func (m *MockMCRService) ListMCRs(ctx context.Context, req *megaport.ListMCRsRequest) ([]*megaport.MCR, error)
func (*MockMCRService) ModifyMCR ¶
func (m *MockMCRService) ModifyMCR(ctx context.Context, req *megaport.ModifyMCRRequest) (*megaport.ModifyMCRResponse, error)
func (*MockMCRService) ModifyMCRPrefixFilterList ¶
func (m *MockMCRService) ModifyMCRPrefixFilterList(ctx context.Context, mcrID string, prefixFilterListID int, prefixFilterList *megaport.MCRPrefixFilterList) (*megaport.ModifyMCRPrefixFilterListResponse, error)
func (*MockMCRService) Reset ¶ added in v0.4.4
func (m *MockMCRService) Reset()
func (*MockMCRService) RestoreMCR ¶
func (m *MockMCRService) RestoreMCR(ctx context.Context, mcrUID string) (*megaport.RestoreMCRResponse, error)
func (*MockMCRService) UpdateMCRIPsecAddOn ¶ added in v0.7.1
func (*MockMCRService) UpdateMCRResourceTags ¶
func (*MockMCRService) UpdateMCRWithAddOn ¶ added in v0.7.1
func (m *MockMCRService) UpdateMCRWithAddOn(ctx context.Context, mcrID string, req megaport.MCRAddOnRequest) error
func (*MockMCRService) ValidateMCROrder ¶
func (m *MockMCRService) ValidateMCROrder(ctx context.Context, req *megaport.BuyMCRRequest) error
func (*MockMCRService) WaitForMCRReady ¶ added in v0.9.2
Click to show internal directories.
Click to hide internal directories.