示例#1
0
文件: app.go 项目: tsuru/tsuru
func (app *App) Shell(opts provision.ShellOptions) error {
	opts.App = app
	prov, err := app.getProvisioner()
	if err != nil {
		return err
	}
	if shellProv, ok := prov.(provision.ShellProvisioner); ok {
		return shellProv.Shell(opts)
	} else {
		return provision.ProvisionerNotSupported{Prov: prov, Action: "running shell"}
	}
}
示例#2
0
文件: app.go 项目: Zapelini/tsuru
func (app *App) Shell(opts provision.ShellOptions) error {
	opts.App = app
	return Provisioner.Shell(opts)
}