diff --git a/base/web/admin.go b/base/web/admin.go index 7e207b6f..c301fd3e 100644 --- a/base/web/admin.go +++ b/base/web/admin.go @@ -2,6 +2,7 @@ package web import ( "net/http" + "os" "path" ice "shylinux.com/x/icebergs" @@ -36,7 +37,12 @@ func init() { RenderMain(m) } else { kit.If(len(arg) == 0, func() { arg = append(arg, SPACE, DOMAIN) }) - m.Cmd(SPIDE, mdb.CREATE, ice.OPS, kit.Format("http://localhost:%s", kit.Select("9020", m.Cmdx(nfs.CAT, ice.VAR_LOG_ICE_PORT)))) + m.Cmd(SPIDE, mdb.CREATE, ice.OPS, kit.Format("http://localhost:%s", kit.GetValid( + func() string { return m.Cmdx(nfs.CAT, ice.VAR_LOG_ICE_PORT) }, + func() string { return m.Cmdx(nfs.CAT, kit.Path(os.Args[0], "../", ice.VAR_LOG_ICE_PORT)) }, + func() string { return m.Cmdx(nfs.CAT, kit.Path(os.Args[0], "../../", ice.VAR_LOG_ICE_PORT)) }, + func() string { return "9020" }, + ))) m.Cmdy(SPIDE, ice.OPS, SPIDE_RAW, http.MethodPost, C(path.Join(arg...)), "pwd", kit.Path("")) } }}, diff --git a/misc/ssh/relay/relay.go b/misc/ssh/relay/relay.go index a0316be2..e23ae44b 100644 --- a/misc/ssh/relay/relay.go +++ b/misc/ssh/relay/relay.go @@ -296,7 +296,7 @@ func (s relay) Upgrade(m *ice.Message, arg ...string) { if len(arg) == 0 && (m.Option(MACHINE) == "" || strings.Contains(m.Option(MACHINE), ",")) { s.foreach(m, func(msg *ice.Message, cmd []string) { ssh.PushShell(msg.Message, strings.Split(msg.Template(UPGRADE_SH), lex.NL), func(res string) { - web.PushNoticeGrow(m.Options(ctx.DISPLAY, web.PLUGIN_XTERM).Message, res) + web.PushNoticeGrow(m.Options(ice.MSG_COUNT, "0", ctx.DISPLAY, web.PLUGIN_XTERM).Message, res) }) }) } else {