This commit is contained in:
2026-03-14 13:33:35 +01:00
parent 18bda1653c
commit ca8acb0c0c
39 changed files with 52 additions and 53 deletions
@@ -1 +1 @@
self.__BUILD_MANIFEST=function(s,e,a,c,t,i,d,n,u){return{__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},"/":[s,a,e,c,u,t,i,"static/chunks/pages/index-5ce092dbf4b7ea2c.js"],"/404":[s,e,"static/chunks/pages/404-8292e1046538596b.js"],"/_error":["static/chunks/pages/_error-10090a8ee211d5fd.js"],"/admin":[s,a,e,c,t,i,d,n,"static/chunks/pages/admin-914586c03dfda5c1.js"],"/admin/services":[s,a,e,c,t,i,d,n,"static/chunks/pages/admin/services-16971626ad193c95.js"],"/admin/services/[service_name]":[s,a,e,c,t,i,d,n,"static/chunks/pages/admin/services/[service_name]-e8b08e5c11b1b12c.js"],"/admin/settings":[s,a,e,c,t,i,d,"static/chunks/pages/admin/settings-f58d63b2752f72a6.js"],"/admin/shell":[s,a,e,c,t,d,"static/chunks/pages/admin/shell-ba3a42e18b796e90.js"],"/admin/users":[s,a,e,c,t,d,"static/chunks/pages/admin/users-73e9775838b56d95.js"],"/admin/users/add-user":[s,a,e,c,t,i,d,"static/chunks/pages/admin/users/add-user-1db7c9ee89830b5b.js"],"/admin/users/[deployment_user_id]":[s,a,"static/chunks/ff39441c-88f593a46cb65964.js","static/chunks/d848df63-a470d32e7be4bfe3.js",e,c,"static/chunks/281-dcee0c6401936d5e.js",t,i,d,"static/chunks/pages/admin/users/[deployment_user_id]-fb1c3c9148c518cd.js"],"/auth/login":[s,a,e,c,u,t,i,"static/chunks/pages/auth/login-3f936f997e58438c.js"],"/auth/logout":[s,e,"static/chunks/pages/auth/logout-c8b207f96be4f684.js"],"/auth/signup":[s,a,e,c,t,i,"static/chunks/pages/auth/signup-5c0f6835749e755e.js"],sortedPages:["/","/404","/_app","/_error","/admin","/admin/services","/admin/services/[service_name]","/admin/settings","/admin/shell","/admin/users","/admin/users/add-user","/admin/users/[deployment_user_id]","/auth/login","/auth/logout","/auth/signup"]}}("static/chunks/29107295-2819ba6e51dbf961.js","static/chunks/664-e347d64e56042a02.js","static/chunks/e5d67320-ccbab4288ca637ad.js","static/chunks/433-ace0b205fb566ad3.js","static/chunks/7-f0121001f735b8fe.js","static/chunks/827-7975edcf8481ec69.js","static/chunks/910-7de3855073c34589.js","static/chunks/926-4d441e5630ef32a9.js","static/chunks/225-f257bb5bd6014d68.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB();
self.__BUILD_MANIFEST=function(s,e,a,c,t,i,n,d,u){return{__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},"/":[s,a,e,c,u,t,i,"static/chunks/pages/index-13e31ea96205b999.js"],"/404":[s,e,"static/chunks/pages/404-8292e1046538596b.js"],"/_error":["static/chunks/pages/_error-10090a8ee211d5fd.js"],"/admin":[s,a,e,c,t,i,n,d,"static/chunks/pages/admin-914586c03dfda5c1.js"],"/admin/services":[s,a,e,c,t,i,n,d,"static/chunks/pages/admin/services-16971626ad193c95.js"],"/admin/services/[service_name]":[s,a,e,c,t,i,n,d,"static/chunks/pages/admin/services/[service_name]-e8b08e5c11b1b12c.js"],"/admin/settings":[s,a,e,c,t,i,n,"static/chunks/pages/admin/settings-f58d63b2752f72a6.js"],"/admin/shell":[s,a,e,c,t,n,"static/chunks/pages/admin/shell-a1da21d85fd3c30b.js"],"/admin/users":[s,a,e,c,t,n,"static/chunks/pages/admin/users-73e9775838b56d95.js"],"/admin/users/add-user":[s,a,e,c,t,i,n,"static/chunks/pages/admin/users/add-user-1db7c9ee89830b5b.js"],"/admin/users/[deployment_user_id]":[s,a,"static/chunks/ff39441c-88f593a46cb65964.js","static/chunks/d848df63-a470d32e7be4bfe3.js",e,c,"static/chunks/281-dcee0c6401936d5e.js",t,i,n,"static/chunks/pages/admin/users/[deployment_user_id]-fb1c3c9148c518cd.js"],"/auth/login":[s,a,e,c,u,t,i,"static/chunks/pages/auth/login-3f936f997e58438c.js"],"/auth/logout":[s,e,"static/chunks/pages/auth/logout-c8b207f96be4f684.js"],"/auth/signup":[s,a,e,c,t,i,"static/chunks/pages/auth/signup-5c0f6835749e755e.js"],sortedPages:["/","/404","/_app","/_error","/admin","/admin/services","/admin/services/[service_name]","/admin/settings","/admin/shell","/admin/users","/admin/users/add-user","/admin/users/[deployment_user_id]","/auth/login","/auth/logout","/auth/signup"]}}("static/chunks/29107295-2819ba6e51dbf961.js","static/chunks/664-e347d64e56042a02.js","static/chunks/e5d67320-bf1772fa71739690.js","static/chunks/433-bb8bdacebff9ab53.js","static/chunks/7-f0121001f735b8fe.js","static/chunks/827-7975edcf8481ec69.js","static/chunks/910-7de3855073c34589.js","static/chunks/926-c50746382fde484e.js","static/chunks/225-f257bb5bd6014d68.js"),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB();
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[890],{25292:function(e,l,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/shell",function(){return s(30904)}])},40806:function(e,l,s){"use strict";s.d(l,{Z:function(){return h}});var n=s(85893),r=s(93452),t=s(76242),i=s(36969),a=s(25808),c=s(94495),u=s(57493),o=s(94655),d=s(3668),f=s(60),p=s(67294),m=s(98388);function h(e){let{url:l,wrapperProps:s,title:h,...x}=e,{loading:j,setLoading:g}=(0,a.Z)();return(0,n.jsx)(r.Z,{...s,className:(0,m.m6)("p-0",null==s?void 0:s.className),children:(0,n.jsxs)(f.Z,{className:"gap-0",children:[(0,n.jsxs)(o.Z,{className:"p-4 w-full justify-between",children:[(0,n.jsx)(o.Z,{children:h?(0,n.jsx)(p.Fragment,{children:(0,n.jsx)(d.Z,{size:"small",variant:"faded",children:h})}):null}),(0,n.jsxs)(o.Z,{children:[(0,n.jsx)(c.Z,{title:"Open Full Screen",variant:"ghost",className:"p-1!",href:l,target:"_blank",children:(0,n.jsx)(i.Z,{name:"ArrowUpRight",size:20})}),(0,n.jsx)(c.Z,{title:"Refresh Iframe",variant:"ghost",className:"p-1!",loading:j,onClick:()=>{g(!0),setTimeout(()=>{g(!1)},2e3)},loadingProps:{size:"smaller"},children:(0,n.jsx)(i.Z,{name:"RotateCcw",size:18})})]})]}),(0,n.jsx)("hr",{}),j?(0,n.jsx)(u.Z,{className:"w-full p-10 h-[400px]",children:(0,n.jsx)(t.Z,{})}):(0,n.jsx)("iframe",{...x,src:l,className:(0,m.m6)("w-full h-[400px]",x.className)})]})})}},30904:function(e,l,s){"use strict";s.r(l),s.d(l,{__N_SSP:function(){return g},default:function(){return v}});var n=s(85893),r=s(67294),t=s(5606),i=s(60705),a=s(33028),c=s(60),u=s(71077),o=s(76242),d=s(57493),f=s(40806),p=s(25808);function m(e){let{paradigm:l}=e,{pageProps:s,ws:i}=(0,r.useContext)(t.AppContext),{user:a}=s,m=a.super_admin?"root":a.username,h="pm2-logs"==l?"pm2 logs":a.super_admin?"bash":m?"su - ".concat(m,' -c "bash"'):void 0,{data:x}=(0,u.Z)(),[j,g]=(0,r.useState)(),{refresh:v,setRefresh:Z}=(0,p.Z)(),N=(0,r.useRef)(!1);function w(){(null==j?void 0:j.port)&&i.sendData({event:"client:kill-port",port:j.port})}return(0,r.useEffect)(()=>{if((null==i?void 0:i.socket)&&!N.current)return i.sendData({event:"pm2-logs"==l?"client:relay-pm2-logs":"client:relay-shell",cmd:h}),N.current=!0,function(){w()}},[i,v]),(0,r.useEffect)(()=>{N.current&&(w(),g(void 0),N.current=!1,Z(e=>e+1))},[]),(0,r.useEffect)(()=>{!j&&("shell"==l&&(null==x?void 0:x.event)=="server:relay-shell"&&(null==x?void 0:x.ttyd)||"pm2-logs"==l&&(null==x?void 0:x.event)=="server:relay-pm2-logs"&&(null==x?void 0:x.ttyd))&&setTimeout(()=>{g(x.ttyd?{...x.ttyd,href:"".concat(window.location.origin).concat(x.ttyd.url)}:void 0)},2e3)},[x]),(0,n.jsxs)(c.Z,{className:"gap-0 w-full",children:[(null==j?void 0:j.url)&&j.port?(0,n.jsx)(c.Z,{className:"gap-0",children:(0,n.jsx)(f.Z,{url:null==j?void 0:j.url,title:"pm2-logs"==l?"Admin Logs":"Relay Shell",wrapperProps:{className:"border-none"}})}):(0,n.jsx)(d.Z,{className:"p-10 h-[460px]",children:(0,n.jsx)(o.Z,{})}),(0,n.jsx)("hr",{})]})}function h(){let{pageProps:e}=(0,r.useContext)(t.AppContext),{user:l}=e;return(0,n.jsxs)(c.Z,{className:"w-full nested-grid-frame xl:grid-cols-2",children:[(0,n.jsx)(c.Z,{className:"grid-cell w-full",children:(0,n.jsx)(m,{paradigm:"shell"})}),l.super_admin?(0,n.jsx)(c.Z,{className:"grid-cell w-full",children:(0,n.jsx)(m,{paradigm:"pm2-logs"})}):null]})}function x(){let{pageProps:e}=(0,r.useContext)(t.AppContext);return(0,n.jsxs)(r.Fragment,{children:[(0,n.jsx)(a.Z,{title:"Shell",description:(0,n.jsx)(n.Fragment,{children:"Access the relay server shell"})}),(0,n.jsx)(i.Z,{}),(0,n.jsx)(h,{})]})}var j=s(89350),g=!0;function v(){return(0,n.jsx)(j.Z,{children:(0,n.jsx)(x,{})})}},93452:function(e,l,s){"use strict";s.d(l,{Z:function(){return t}});var n=s(85893),r=s(98388);function t(e){let{spacing:l,componentRef:s,...t}=e;return(0,n.jsx)("div",{...t,className:(0,r.m6)("relative flex items-center gap-2 border border-solid rounded-default","border-slate-200 dark:border-white/10",l?"normal"==l?"px-3 py-2":"tight"==l?"px-2 py-1":"":"px-3 py-2","twui-border",t.className),ref:s,children:t.children})}},57493:function(e,l,s){"use strict";s.d(l,{Z:function(){return t}});var n=s(85893),r=s(98388);function t(e){let{...l}=e;return(0,n.jsx)("div",{...l,className:(0,r.m6)("flex flex-col items-center justify-center gap-4 p-2 w-full","h-full twui-center",l.className),children:l.children})}},9008:function(e,l,s){e.exports=s(23867)}},function(e){e.O(0,[662,75,664,433,7,910,888,774,179],function(){return e(e.s=25292)}),_N_E=e.O()}]);
@@ -1 +0,0 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[890],{25292:function(e,l,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/admin/shell",function(){return n(30904)}])},40806:function(e,l,n){"use strict";n.d(l,{Z:function(){return x}});var s=n(85893),r=n(93452),t=n(76242),i=n(36969),c=n(25808),a=n(94495),u=n(57493),o=n(94655),d=n(3668),p=n(60),f=n(67294),m=n(98388);function x(e){let{url:l,wrapperProps:n,title:x,...h}=e,{loading:j,setLoading:g}=(0,c.Z)();return(0,s.jsx)(r.Z,{...n,className:(0,m.m6)("p-0",null==n?void 0:n.className),children:(0,s.jsxs)(p.Z,{className:"gap-0",children:[(0,s.jsxs)(o.Z,{className:"p-4 w-full justify-between",children:[(0,s.jsx)(o.Z,{children:x?(0,s.jsx)(f.Fragment,{children:(0,s.jsx)(d.Z,{size:"small",variant:"faded",children:x})}):null}),(0,s.jsxs)(o.Z,{children:[(0,s.jsx)(a.Z,{title:"Open Full Screen",variant:"ghost",className:"p-1!",onClick:()=>{window.open(l,"__blank")},children:(0,s.jsx)(i.Z,{name:"ArrowUpRight",size:20})}),(0,s.jsx)(a.Z,{title:"Refresh Iframe",variant:"ghost",className:"p-1!",loading:j,onClick:()=>{g(!0),setTimeout(()=>{g(!1)},2e3)},loadingProps:{size:"smaller"},children:(0,s.jsx)(i.Z,{name:"RotateCcw",size:18})})]})]}),(0,s.jsx)("hr",{}),j?(0,s.jsx)(u.Z,{className:"w-full p-10 h-[400px]",children:(0,s.jsx)(t.Z,{})}):(0,s.jsx)("iframe",{...h,src:l,className:(0,m.m6)("w-full h-[400px]",h.className)})]})})}},30904:function(e,l,n){"use strict";n.r(l),n.d(l,{__N_SSP:function(){return g},default:function(){return v}});var s=n(85893),r=n(67294),t=n(5606),i=n(60705),c=n(33028),a=n(60),u=n(71077),o=n(76242),d=n(57493),p=n(40806),f=n(25808);function m(e){let{paradigm:l}=e,{pageProps:n,ws:i}=(0,r.useContext)(t.AppContext),{user:c}=n,m=c.super_admin?"root":c.username,x="pm2-logs"==l?"pm2 logs":c.super_admin?"bash":m?"su - ".concat(m,' -c "bash"'):void 0,{data:h}=(0,u.Z)(),[j,g]=(0,r.useState)(),{refresh:v,setRefresh:Z}=(0,f.Z)(),N=(0,r.useRef)(!1);function w(){(null==j?void 0:j.port)&&i.sendData({event:"client:kill-port",port:j.port})}return(0,r.useEffect)(()=>{if((null==i?void 0:i.socket)&&!N.current)return i.sendData({event:"pm2-logs"==l?"client:relay-pm2-logs":"client:relay-shell",cmd:x}),N.current=!0,function(){w()}},[i,v]),(0,r.useEffect)(()=>{N.current&&(w(),g(void 0),N.current=!1,Z(e=>e+1))},[]),(0,r.useEffect)(()=>{!j&&("shell"==l&&(null==h?void 0:h.event)=="server:relay-shell"&&(null==h?void 0:h.ttyd)||"pm2-logs"==l&&(null==h?void 0:h.event)=="server:relay-pm2-logs"&&(null==h?void 0:h.ttyd))&&setTimeout(()=>{g(h.ttyd?{...h.ttyd,href:"".concat(window.location.origin).concat(h.ttyd.url)}:void 0)},2e3)},[h]),(0,s.jsxs)(a.Z,{className:"gap-0 w-full",children:[(null==j?void 0:j.url)&&j.port?(0,s.jsx)(a.Z,{className:"gap-0",children:(0,s.jsx)(p.Z,{url:null==j?void 0:j.url,title:"pm2-logs"==l?"Admin Logs":"Relay Shell",wrapperProps:{className:"border-none"}})}):(0,s.jsx)(d.Z,{className:"p-10 h-[460px]",children:(0,s.jsx)(o.Z,{})}),(0,s.jsx)("hr",{})]})}function x(){let{pageProps:e}=(0,r.useContext)(t.AppContext),{user:l}=e;return(0,s.jsxs)(a.Z,{className:"w-full nested-grid-frame xl:grid-cols-2",children:[(0,s.jsx)(a.Z,{className:"grid-cell w-full",children:(0,s.jsx)(m,{paradigm:"shell"})}),l.super_admin?(0,s.jsx)(a.Z,{className:"grid-cell w-full",children:(0,s.jsx)(m,{paradigm:"pm2-logs"})}):null]})}function h(){let{pageProps:e}=(0,r.useContext)(t.AppContext);return(0,s.jsxs)(r.Fragment,{children:[(0,s.jsx)(c.Z,{title:"Shell",description:(0,s.jsx)(s.Fragment,{children:"Access the relay server shell"})}),(0,s.jsx)(i.Z,{}),(0,s.jsx)(x,{})]})}var j=n(89350),g=!0;function v(){return(0,s.jsx)(j.Z,{children:(0,s.jsx)(h,{})})}},93452:function(e,l,n){"use strict";n.d(l,{Z:function(){return t}});var s=n(85893),r=n(98388);function t(e){let{spacing:l,componentRef:n,...t}=e;return(0,s.jsx)("div",{...t,className:(0,r.m6)("relative flex items-center gap-2 border border-solid rounded-default","border-slate-200 dark:border-white/10",l?"normal"==l?"px-3 py-2":"tight"==l?"px-2 py-1":"":"px-3 py-2","twui-border",t.className),ref:n,children:t.children})}},57493:function(e,l,n){"use strict";n.d(l,{Z:function(){return t}});var s=n(85893),r=n(98388);function t(e){let{...l}=e;return(0,s.jsx)("div",{...l,className:(0,r.m6)("flex flex-col items-center justify-center gap-4 p-2 w-full","h-full twui-center",l.className),children:l.children})}},9008:function(e,l,n){e.exports=n(23867)}},function(e){e.O(0,[662,75,664,433,7,910,888,774,179],function(){return e(e.s=25292)}),_N_E=e.O()}]);
File diff suppressed because one or more lines are too long