Documentation
¶
Index ¶
Constants ¶
const ( VERSION = "version" INIT = "init" INSTALL = "install" CONFIG = "config" DEPLOY = "deploy" D = "d" STAGE = "stage" ST = "st" // alias for "stage" FUNCTION = "function" FN = "fn" // alias for "function" RESOURCE = "resource" R = "r" // alias for "resource" STORAGE = "storage" S = "s" // alias for "storage" SCHEDULER = "scheduler" SC = "sc" // alias for schedule )
const ( DEPLOYFUNCTION = "function" DEPLOYFN = "fn" DEPLOYRESOURCE = "resource" DEPLOYR = "r" DEPLOYSTORAGE = "storage" DEPLOYSCHEDULE = "schedule" DEPLOYS = "s" DEPLOYALL = "all" DEPLOYHELP = "help" )
const ( FUNCTIONCREATE = "create" FUNCTIONDELETE = "delete" FUNCTIONINVOKE = "invoke" FUNCTIONDEPLOY = "deploy" FUNCTIONMOUNT = "mount" FUNCTIONUNMOUNT = "unmount" FUNCTIONLIST = "list" FUNCTIONHELP = "help" FUNCTIONLOG = "log" )
const ( RESOURCECREATE = "create" RESOURCEDELETE = "delete" RESOURCEINVOKE = "invoke" RESOURCEDEPLOY = "deploy" RESOURCELIST = "list" RESOURCEHELP = "help" )
const ( SCHEDULERCREATE = "create" SCHEDULERDELETE = "delete" SCHEDULERDEPLOY = "deploy" SCHEDULERLIST = "list" SCHEDULERATTACH = "attach" SCHEDULERDETACH = "detach" SCHEDULERHELP = "help" )
const ( STAGECREATE = "create" STAGEDELETE = "delete" STAGEDEPLOY = "deploy" STAGELIST = "list" STAGEHELP = "help" )
const ( STORAGEDEPLOY = "deploy" STORAGEMOUNT = "mount" STORAGEUNMOUNT = "unmount" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Command ¶
type Command interface { Run(ctx *args.Context) Help() string }
Command is the interface implemented by structs that can run the command and show help as usage.
type Config ¶
type Config struct { Command // contains filtered or unexported fields }
Config is a struct for update project configuration.
func (*Config) Run ¶
func (c *Config) Run(ctx *args.Context)
Run the config command.
>>> doc
## Update configuration
Update configurations by supplied command options.
``` $ ginger config [options] ```
| option | description | |:---------:|:-----------------------------------------------------------------------------| | --profile | Accout profile name. If empty, ginger uses `default` or environment variable | | --region | Region name to deploy | | --bucket | S3 bucket name | | --hook | Deploy hook command |
<<< doc
type Deploy ¶
type Deploy struct { Command // contains filtered or unexported fields }
Deploy is the struct that manages function and api deployment. deploy syncs between local and AWS.
func (*Deploy) Run ¶
func (d *Deploy) Run(ctx *args.Context)
Run the deploy command
>>> doc
## Deploy all
Deploy all functions, resources, storage items.
``` $ ginger deploy all [options] ```
| option | description | |:-------:|:--------------------------------------------------------------------| | --stage | Stage name. If this option is supplied, create deployment to stage. |
<<< doc
type Function ¶
type Function struct { Command // contains filtered or unexported fields }
Function is the struct of AWS Lambda function operation command. This struct will be dispatched on "ginger fn/funtion" subcommand. This command operates with above constant string.
func NewFunction ¶
func NewFunction() *Function
type Init ¶
type Init struct { Command // contains filtered or unexported fields }
Init is the struct for initalize ginger project. This command generates config file and some directory structure.
type Install ¶
type Install struct { Command // contains filtered or unexported fields }
Install is the struct for install ginger project dependencies. This command installs project dependencies.
func NewInstall ¶
func NewInstall() *Install
type Resource ¶
type Resource struct { Command // contains filtered or unexported fields }
Resource is the struct of AWS API Gateway resource management command. This struct will be dispatched on "ginger resource" subcommand. This command operates with above constant string.
func NewResource ¶
func NewResource() *Resource
type Scheduler ¶
type Scheduler struct { Command // contains filtered or unexported fields }
Schduler is the struct of AWS CloudWatchEvents management command. This struct will be dispatched on "ginger schedule" subcommand.
func NewScheduler ¶
func NewScheduler() *Scheduler
type Stage ¶
type Stage struct { Command // contains filtered or unexported fields }
Stage is the struct of AWS API Gateway stage operation command. This struct will be dispatched on "ginger stage" subcommand.
type Storage ¶
type Storage struct { Command // contains filtered or unexported fields }
func NewStorage ¶
func NewStorage() *Storage