Documentation ¶
Index ¶
- Variables
- type AppCreateCommand
- type AppDestroyCommand
- type AppInfoCommand
- type AppListCommand
- type AppLogCommand
- type AppOpenCommand
- type AppRebuildCommand
- type AppRollbackCommand
- type Command
- type EVarCreateCommand
- type EVarDestroyCommand
- type EVarListCommand
- type HelpCommand
- type Log
- type Logs
- type Logvac
- type ServiceInfoCommand
- type ServiceListCommand
- type ServiceRebootCommand
- type ServiceRepairCommand
- type ServiceRestartCommand
- type ServiceRunCommand
- type ServiceSSHCommand
- type ServiceTunnelCommand
- type Stormpack
- type UpdateCommand
- type UserInfoCommand
- type UserSwitchCommand
Constants ¶
This section is empty.
Variables ¶
var Commands map[string]Command
Commands represents a map of all the available commands that the Pagoda Box CLI can run
Functions ¶
This section is empty.
Types ¶
type AppCreateCommand ¶
type AppCreateCommand struct{}
AppCreateCommand satisfies the Command interface for creating an app
func (*AppCreateCommand) Help ¶
func (c *AppCreateCommand) Help()
Help prints detailed help text for the app create command
func (*AppCreateCommand) Run ¶
func (c *AppCreateCommand) Run(fApp string, opts []string)
Run attempts to create a new app on Pagoda Box. It can take an app-name flag for naming the app, and a tinker flag for designating the type of app to create. If successful, it attempts to add a new remote, then prints instructions on pushing code to pagodabox
type AppDestroyCommand ¶
type AppDestroyCommand struct{}
AppDestroyCommand satisfies the Command interface for destroying an app
func (*AppDestroyCommand) Help ¶
func (c *AppDestroyCommand) Help()
Help prints detailed help text for the app destroy command
func (*AppDestroyCommand) Run ¶
func (c *AppDestroyCommand) Run(fApp string, opts []string)
Run attempts to destroy an app on Pagoda Box. It can take a force flag that will skip the confirmation process, other wise will ask for confirmation by retyping the name of the app to be destroyed
type AppInfoCommand ¶
type AppInfoCommand struct{}
AppInfoCommand satisfies the Command interface for obtaining app info
func (*AppInfoCommand) Help ¶
func (c *AppInfoCommand) Help()
Help prints detailed help text for the app info command
func (*AppInfoCommand) Run ¶
func (c *AppInfoCommand) Run(fApp string, opts []string)
Run prints out select information for the designated app
type AppListCommand ¶
type AppListCommand struct{}
AppListCommand satisfies the Command interface for listing a user's apps
func (*AppListCommand) Help ¶
func (c *AppListCommand) Help()
Help prints detailed help text for the app list command
func (*AppListCommand) Run ¶
func (c *AppListCommand) Run(fApp string, opts []string)
Run displays select information about all of a user's apps
type AppLogCommand ¶
type AppLogCommand struct{}
AppLogCommand satisfies the Command interface for obtaining an app's historical and streaming logs
func (*AppLogCommand) Help ¶
func (c *AppLogCommand) Help()
Help prints detailed help text for the app log command
func (*AppLogCommand) Run ¶
func (c *AppLogCommand) Run(fApp string, opts []string)
Run attempts to display an app's logs. It takes count flag to designate how many logs to print, and a stream flag to indicate the live stream rather than historical. Logs are prased, colorized and printed to the terminal
type AppOpenCommand ¶
type AppOpenCommand struct{}
AppOpenCommand satisfies the Command interface for opening a user's app
func (*AppOpenCommand) Help ¶
func (c *AppOpenCommand) Help()
Help prints detailed help text for the app open command
func (*AppOpenCommand) Run ¶
func (c *AppOpenCommand) Run(fApp string, opts []string)
Run opens an app in the users default browser
type AppRebuildCommand ¶
type AppRebuildCommand struct{}
AppRebuildCommand satisfies the Command interface for rebuilding an app
func (*AppRebuildCommand) Help ¶
func (c *AppRebuildCommand) Help()
Help prints detailed help text for the app rebuild command
func (*AppRebuildCommand) Run ¶
func (c *AppRebuildCommand) Run(fApp string, opts []string)
Run attempts to rebuild an app
type AppRollbackCommand ¶
type AppRollbackCommand struct{}
AppRollbackCommand satisfies the Command interface for rolling back an app
func (*AppRollbackCommand) Help ¶
func (c *AppRollbackCommand) Help()
Help prints detailed help text for the app rollback command
func (*AppRollbackCommand) Run ¶
func (c *AppRollbackCommand) Run(fApp string, opts []string)
Run attempts to roll an app back one (1) deploy
type Command ¶
type Command interface { Help() // Prints the help text associated with this command Run(fApp string, opts []string) // Houses the logic that will be run upon calling this command }
Command represents a Pagoda Box CLI command. Every command must have a Help() and Run() function
type EVarCreateCommand ¶
type EVarCreateCommand struct{}
EVarCreateCommand satisfies the Command interface for creating an environment variable
func (*EVarCreateCommand) Help ¶
func (c *EVarCreateCommand) Help()
Help prints detailed help text for the evar create command
func (*EVarCreateCommand) Run ¶
func (c *EVarCreateCommand) Run(fApp string, opts []string)
Run attempts to create a new app on Pagoda Box. It can take an app-name flag for naming the app, and a tinker flag for designating the type of app to create. If successful, it attempts to add a new remote, then prints instructions on pushing code to pagodabox
type EVarDestroyCommand ¶
type EVarDestroyCommand struct{}
EVarDestroyCommand satisfies the Command interface for destroying an app's environemtn variable
func (*EVarDestroyCommand) Help ¶
func (c *EVarDestroyCommand) Help()
Help prints detailed help text for the evar destroy command
func (*EVarDestroyCommand) Run ¶
func (c *EVarDestroyCommand) Run(fApp string, opts []string)
Run attempts to destroy an app on Pagoda Box. It can take a force flag that will skip the confirmation process, other wise will ask for confirmation by retyping the name of the app to be destroyed
type EVarListCommand ¶
type EVarListCommand struct{}
EVarListCommand satisfies the Command interface for listing an app's environment variables
func (*EVarListCommand) Help ¶
func (c *EVarListCommand) Help()
Help prints detailed help text for the evar list command
func (*EVarListCommand) Run ¶
func (c *EVarListCommand) Run(fApp string, opts []string)
Run disaplys select information about all of an app's environment variables
type HelpCommand ¶
type HelpCommand struct{}
HelpCommand satisfies the Command interface for obtaining user info
func (*HelpCommand) Help ¶
func (c *HelpCommand) Help()
Help prints detailed help text for the user command
func (*HelpCommand) Run ¶
func (c *HelpCommand) Run(app string, opts []string)
Run prints out the help text for the entire CLI
type ServiceInfoCommand ¶
type ServiceInfoCommand struct{}
ServiceInfoCommand satisfies the Command interface for obtaining service info
func (*ServiceInfoCommand) Help ¶
func (c *ServiceInfoCommand) Help()
Help prints detailed help text for the service info command
func (*ServiceInfoCommand) Run ¶
func (c *ServiceInfoCommand) Run(fApp string, opts []string)
Run attempts to print select information about an app's service. If no service is provided the command will prompt for one
type ServiceListCommand ¶
type ServiceListCommand struct{}
ServiceListCommand satisfies the Command interface for listing an app's services
func (*ServiceListCommand) Help ¶
func (c *ServiceListCommand) Help()
Help prints detailed help text for the service list command
func (*ServiceListCommand) Run ¶
func (c *ServiceListCommand) Run(fApp string, opts []string)
Run disaplys select information about all of an app's services
type ServiceRebootCommand ¶
type ServiceRebootCommand struct{}
ServiceRebootCommand satisfies the Command interface for rebooting an app service
func (*ServiceRebootCommand) Help ¶
func (c *ServiceRebootCommand) Help()
Help prints detailed help text for the service reboot command
func (*ServiceRebootCommand) Run ¶
func (c *ServiceRebootCommand) Run(fApp string, opts []string)
Run attempts to reboot an app's service
type ServiceRepairCommand ¶
type ServiceRepairCommand struct{}
ServiceRepairCommand satisfies the Command interface for repairing an app service
func (*ServiceRepairCommand) Help ¶
func (c *ServiceRepairCommand) Help()
Help prints detailed help text for the service repair command
func (*ServiceRepairCommand) Run ¶
func (c *ServiceRepairCommand) Run(fApp string, opts []string)
Run attempts to repair an apps service
type ServiceRestartCommand ¶
type ServiceRestartCommand struct{}
ServiceRestartCommand satisfies the Command interface for restarting an app service
func (*ServiceRestartCommand) Help ¶
func (c *ServiceRestartCommand) Help()
Help prints detailed help text for the service restart command
func (*ServiceRestartCommand) Run ¶
func (c *ServiceRestartCommand) Run(fApp string, opts []string)
Run attemtps to restart an apps service
type ServiceRunCommand ¶
type ServiceRunCommand struct{}
ServiceRunCommand satisfies the Command interface for running commands on an app's service
func (*ServiceRunCommand) Help ¶
func (c *ServiceRunCommand) Help()
Help prints detailed help text for the service run command
func (*ServiceRunCommand) Run ¶
func (c *ServiceRunCommand) Run(fApp string, opts []string)
Run attempts to run a specified command an a designated app service. Takes a command flag, which is the command to be run. Takes a service flag to designate which serivce to run the command on. If no service is provided, it will select the first 'codeable' service it finds and run the command there. Also takes an identity file flag to all a user to specify the location of their public SSH key if necessary
type ServiceSSHCommand ¶
type ServiceSSHCommand struct{}
ServiceSSHCommand satisfies the Command interface for SSHing into an app's service
func (*ServiceSSHCommand) Help ¶
func (c *ServiceSSHCommand) Help()
Help prints detailed help text for the service ssh command
func (*ServiceSSHCommand) Run ¶
func (c *ServiceSSHCommand) Run(fApp string, opts []string)
Run attempts to SSH into an app service and provide a pseudo terminal to use on the server. Also takes an identity file flag allowing a user to specify the location of their public SSH key if necessary
type ServiceTunnelCommand ¶
type ServiceTunnelCommand struct{}
ServiceTunnelCommand satisfies the Command interface for opening a port forward 'tunnel' to an app's service
func (*ServiceTunnelCommand) Help ¶
func (c *ServiceTunnelCommand) Help()
Help prints detailed help text for the service tunnel command
func (*ServiceTunnelCommand) Run ¶
func (c *ServiceTunnelCommand) Run(fApp string, opts []string)
Run attempts to open a port forward 'tunnel' to an app service. Takes a port flag to designate which port the user wants to use as their local port forward port. Also takes an identity file flag allowing a user to specify the location of their public SSH key if necessary. If the tunnel is able to establish correctly it will stay open until closed (ctrl + c)
type Stormpack ¶
type Stormpack struct { Command string `json:"command"` Data string `json:"data"` Error string `json:"error"` Filters []string `json:"filters"` Keys []string `json:"keys"` Success bool `json:"success"` Token string `json:"stormpack_token"` }
Stormpack represents the system used for obtianing an app's streaming logs
type UpdateCommand ¶
type UpdateCommand struct{}
UpdateCommand satisfies the Command interface for obtaining user info
func (*UpdateCommand) Help ¶
func (c *UpdateCommand) Help()
Help prints detailed help text for the user command
func (*UpdateCommand) Run ¶
func (c *UpdateCommand) Run(app string, opts []string)
Run gets the current user and prints out select information to the terminal
type UserInfoCommand ¶
type UserInfoCommand struct{}
UserInfoCommand satisfies the Command interface for obtaining user info
func (*UserInfoCommand) Help ¶
func (c *UserInfoCommand) Help()
Help prints detailed help text for the user command
func (*UserInfoCommand) Run ¶
func (c *UserInfoCommand) Run(app string, opts []string)
Run gets the current user and prints out select information to the terminal
type UserSwitchCommand ¶
type UserSwitchCommand struct{}
UserSwitchCommand satisfies the Command interface for switching between user accounts
func (*UserSwitchCommand) Help ¶
func (c *UserSwitchCommand) Help()
Help prints detailed help text for the user switch
func (*UserSwitchCommand) Run ¶
func (c *UserSwitchCommand) Run(app string, opts []string)
Run 'logs out' the current user and attempts to 'log in' a new user. It can take user and password flags, or will prompt for both not provided, then calls helpers.Authenticate()
Source Files ¶
- app_create.go
- app_destroy.go
- app_info.go
- app_list.go
- app_log.go
- app_open.go
- app_rebuild.go
- app_rollback.go
- commands.go
- evar_create.go
- evar_destroy.go
- evar_list.go
- help.go
- service_info.go
- service_list.go
- service_reboot.go
- service_repair.go
- service_restart.go
- service_run.go
- service_ssh.go
- service_tunnel.go
- update.go
- user_info.go
- user_switch.go