Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddMigrationsAPI ¶
AddMigrationsAPI registers migrations endpoints on the given router.
func AddWorkspacesAPI ¶
AddWorkspacesAPI registers workspaces endpoints on the given router.
Types ¶
type Context ¶
type Context struct { RequestID string WorkspaceService *workspaces.Service MigrationsService *migrations.Service Logger log.FieldLogger }
Context provides the API with all necessary data and interfaces for responding to requests.
It is cloned before each request, allowing per-request changes such as logger annotations.
type ContextHandler ¶
type ContextHandler struct {
// contains filtered or unexported fields
}
ContextHandler for HTTP
func NewContextHandler ¶
func NewContextHandler(context *Context, handler ContextHandlerFunc) *ContextHandler
NewContextHandler to create a handler for context
func (ContextHandler) ServeHTTP ¶
func (h ContextHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)
ServeHTTP for server to run HTTP
type ContextHandlerFunc ¶
type ContextHandlerFunc func(c *Context, w http.ResponseWriter, r *http.Request)
ContextHandlerFunc to add context
type PonosClient ¶
type PonosClient struct {
// contains filtered or unexported fields
}
func NewPonosClient ¶
func NewPonosClient(token, url string) *PonosClient
NewPonosClient factory method to create a Ponos Client
func (*PonosClient) CreateMiration ¶
func (c *PonosClient) CreateMiration(data migrations.CustomerMigrationRequest) error
CreateMiration will create the necessary resources for migrating a customer in cloud with AWAT. Resources: - S3 Bucket - IAM resouces & policy
func (*PonosClient) DeleteMiration ¶
func (c *PonosClient) DeleteMiration(data migrations.CustomerMigrationRequest) error
DeleteMiration will delete the created resources for migrating a customer in cloud with AWAT. Resources: - S3 Bucket - IAM resouces & policy
func (*PonosClient) DeleteWorkspace ¶
func (c *PonosClient) DeleteWorkspace(data workspaces.DeleteWorkspaceRequest) error
DeleteWorkspace will make a request to delete a workspace