(function(t){function e(e){for(var o,i,r=e[0],l=e[1],c=e[2],u=0,p=[];ut.tailed_path))];var s="";for(let n of this.log_path)if(s=e.filter(t=>t.tailed_path===n).length,o["default"].set(this.log_path_lenght,n,s),s>this.loglenghttotal)y.dispatch("pipelineLLO/taillog",{path:n})},async message(t){console.log(" socket message "+JSON.stringify(t))},async message_out(t){console.log(" socket out "+JSON.stringify(t)),this.$root.$emit("hybrid_log_in",t)},async message_err(t){console.log(" socket err "+JSON.stringify(t)),this.$root.$emit("hybrid_log_in",t)},async message_close(t){console.log(" socket close "+JSON.stringify(t)),this.$root.$emit("hybrid_log_in",t)}},actions:{}},F=N,A=(s("4cf0"),Object(x["a"])(F,l,c,!1,null,null,null)),P=A.exports,E=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",[t.showlloedit?s("b-row",{attrs:{"no-gutters":"","w-100":"","h-100":""}},[s("b-col",{attrs:{cols:"12",sm:"12",md:"12"}},[s("b-row",[s("b-col",{attrs:{cols:"4"}},[s("div",{staticClass:"input-group input-group-sm sm-3"})]),s("b-col",{attrs:{cols:"3"}},[s("div",{staticClass:"input-group input-group-sm sm-3"},[t.socketonline?s("button",{staticClass:"btn btn-outline-info btn-sm",attrs:{type:"button",round:""},on:{click:function(e){return t.hotreload()}}},[t._v(" Hot_Reload")]):t._e()])]),s("b-col",{attrs:{cols:"5"}},[s("div",{staticClass:"input-group input-group-sm d-flex justify-content-end"}),s("div",{staticClass:"input-group input-group-sm d-flex justify-content-end"},[s("div",{staticClass:"input-group-append"},[t.socketonline?s("button",{staticClass:"btn btn-outline-warning btn-sm",attrs:{type:"button",round:""},on:{click:function(e){return t.infoHotreload()}}},[t._v(" Hot_Reload_HowTo")]):t._e()]),s("div",{staticClass:"input-group-append"},[t.tryConsole?s("button",{staticClass:"btn btn-outline-warning btn-sm",attrs:{type:"button",round:""},on:{click:function(e){return t.clear()}}},[t._v(" Clear")]):t._e()]),s("div",{staticClass:"input-group-append"},["sublime"==t.cmOptions.keyMap?s("button",{staticClass:"btn btn-outline-info btn-sm",attrs:{type:"button",round:""},on:{click:t.infoFilter}},[t._v(" i")]):t._e()])])])],1),s("div",{staticClass:"codemirror"},[s("codemirror",{ref:"myCm",attrs:{value:t.code,options:t.cmOptions},on:{cursorActivity:t.onCmCursorActivity,ready:t.onCmReady,focus:t.onCmFocus,input:t.onCmCodeChange}})],1)],1)],1):t._e()],1)},j=[],T=s("8f94"),D=(s("c4e3"),s("21a6"),s("a7be"),s("bbca"),s("281e"),s("31c5"),s("9b74"),s("f6b6"),s("3c98"),s("9c7b"),s("715d"),s("b933"),s("23de"),s("02f0"),s("8c33"),s("7289"),s("2aed"),s("d72f"),s("0b6c"),s("9a48"),s("75f8"),s("697e"),s("aedd"),s("164b"),s("4895"),s("cbc8"),s("8d70"),s("9f09"),s("a2c1"),s("56b3"),s("d7d5"),{components:{codemirror:T["codemirror"]},data(){return{socketonline:!1,tryConsole:!1,ssl:{},getinfo:"",token:"",swarmlabname:"",code:"",editchoice:"",optionsedit:[{text:"code",value:"code"},{text:"text",value:"text"}],llodesc:[{llo_url:"",llo_name:"",llo_author:"",llo_intro:""}],llo:[{id:0,rm:!1,data_info:"Asciidoc \n",data_code:"#Your source code",data_service:"",code_datafile:"url",code_name:"",code_exec:"",code_options:"",code_mime:"",code_info:"",code_code:"",code_codeout:"",code_codeoutput:"console",points:"",challenge_question:"",code_challenge_question:"",challenge_answer:"",challenge_answer_hint:"",code_challenge_answer_hint:"",challenge_answer_source:"",challenge_answer_code_out:"",challenge_answer_code:"",code_challenge_answer_code:""}],searchLLO:[],searchLLOactive:!1,ADOC_html_code:"",challenge:[],action:"",tryLLO:[],service:"os2",active:0,activecount:0,remove:"",activeField:"",bootstrap:!1,firstbootstrap:0,htmlasciitmp:"",datafile:"https://git.swarmlab.io:3000/labs/examples-mpi2/raw/branch/master/0_netstat/data",datadir:"0_netstat/data",LearningObject:"",showllo:!0,showlloedit:!0,selected:"sublime",options:[{text:"vim",value:"vim"},{text:"sublime",value:"sublime"}],optionsmime:[{text:"sh",value:"bash"},{text:"javascript",value:"javascript"},{text:"python",value:"python"},{text:"php",value:"php"},{text:"sql",value:"sq;"},{text:"xml",value:"xml"},{text:"c",value:"c"}],pValidate:!1,cmOptions:{tabSize:2,styleActiveLine:!0,lineNumbers:!0,lineSeparator:"\n",line:!0,foldGutter:!0,gutters:["CodeMirror-linenumbers","CodeMirror-foldgutter"],highlightSelectionMatches:{showToken:/\w/,annotateScrollbar:!0},styleSelectedText:!0,mode:"shell",hintOptions:{completeSingle:!1},keyMap:"sublime",matchBrackets:!0,showCursorWhenSelecting:!0,indentUnit:this.ADOC_html_code,lineWrapping:!0,theme:"paraiso-light",refresh:!0,readOnly:!0,autofocus:!1,extraKeys:{Ctrl:"autocomplete"}},ADOC_html:[]}},methods:{socketconnect(){this.$root.$emit("SERVER_socket_connect")},clear(){this.tryConsole=!1,this.code=""},async getdata(){var t=this.getinfo;await y.dispatch("pipelineLLO/get_data",{code:t})},async showactive(t){this.topwindow(t)},onCmReady(t){t.on("change",(t,e)=>{}),t.on("keypress",()=>{t.showHint({completeSingle:!1})})},onCmCursorActivity(t,e,s){},onCmFocus(t){},onCmCodeChange(t){this.code=t},handleChange(){},setKeymap(){this.cmOptions.keyMap=this.selected},infoFilter(){var t="

Playbook Images

",e='
Shift-Tab indentLess
Alt-Q wrapLines
Ctrl-Up scrollLineUp
Ctrl-Down scrollLineDown
Ctrl-L selectLine
Esc singleSelectionTop
Ctrl-Enter insertLineAfter
Ctrl-D selectNextOccurrence
Shift-Ctrl-Space selectScope
Shift-Ctrl-M selectBetweenBrackets
Ctrl-M goToBracket
Ctrl-K Ctrl-Y sublimeYank
Ctrl-K Ctrl-C showInCenter
Ctrl-K Ctrl-G clearBookmarks
Ctrl-K Ctrl-Backspace delLineLeft
Ctrl-K Ctrl-0 unfoldAll
Ctrl-K Ctrl-J unfoldAll
Ctrl-Alt-Up addCursorToPrevLine
Ctrl-Alt-Down addCursorToNextLine
Ctrl-F3 findUnder
Shift-Ctrl-F3 findUnderPrevious
Shift-Ctrl-[ fold
Shift-Ctrl-] unfold
Ctrl-F find
',s=(t="","");this.$swal({title:"Key bindings",type:"info",html:e+t+s,showCloseButton:!0,showLoaderOnConfirm:!1,allowOutsideClick:!1})},async hotreload(){this.getinfo,await y.dispatch("pipelineLLO/hotreload",{token:this.token,swarmlabname:this.swarmlabname})},infoHotreload(){var t=`
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n
Downloadhttps://git.swarmlab.io:3000/labs/swarmlab-playground-client/raw/branch/master/hot_reload.sh
and add the proper values
token${this.token}
swarmlabname${this.swarmlabname}
OR set the variables before exec
export SWARMLAB_token=${this.token}
export SWARMLAB_name=${this.swarmlabname}
Ready! \n
Execute script every time you run git push
`;this.$swal({title:"HowTo",type:"info",html:t,showCloseButton:!0,showLoaderOnConfirm:!1,allowOutsideClick:!1})}},computed:{codemirror(){return this.$refs.myCm.codemirror}},mounted(){this.$root.$on("SERVER_socket_status",t=>{this.$nextTick((function(){"off"==t?this.socketonline=!1:"on"==t&&(this.socketonline=!0)}))}),this.$root.$on("hybrid_log_in",t=>{this.code+=t.data,this.code+="\n",this.$refs.myCm.codemirror.setCursor(this.$refs.myCm.codemirror.lineCount(),0),this.tryConsole=!0})},beforeDestroy(){this.$root.$off("SERVER_socket_status"),this.$root.$off("hybrid_log_in")},created(){this.token=new URL(location.href).searchParams.get("token"),this.swarmlabname=new URL(location.href).searchParams.get("pipelinename")}}),B=D,J=(s("0b43"),Object(x["a"])(B,E,j,!1,null,null,null)),I=J.exports,M=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"card",staticStyle:{"max-height":"100%"}},[o("v-wait",{attrs:{for:"myRunInstancetutor"}},[o("template",{slot:"waiting"},[o("div",[o("img",{attrs:{src:s("cf1c")}}),t._v(" Enter Lab_room... ")])])],2),o("div",{staticClass:"input-group input-group-sm sm-3"},[o("input",{directives:[{name:"model",rawName:"v-model",value:t.searchFor,expression:"searchFor"}],staticClass:"form-control",attrs:{type:"text","aria-label":"Small","aria-describedby":"inputGroup-sizing-sm",placeholder:"Search"},domProps:{value:t.searchFor},on:{keyup:function(e){return!e.type.indexOf("key")&&t._k(e.keyCode,"enter",13,e.key,"Enter")?null:t.setFilter(e)},input:function(e){e.target.composing||(t.searchFor=e.target.value)}}}),o("div",{staticClass:"input-group-append"},[o("button",{staticClass:"btn btn-outline-primary",attrs:{round:"",type:"button"},on:{click:t.setFilter}},[t._v(" Go")])]),o("div",{staticClass:"input-group-append"},[o("button",{staticClass:"btn btn-outline-secondary",attrs:{round:"",type:"button"},on:{click:t.resetFilter}},[t._v(" Reset")])])]),o("vuetable",{key:t.vuetablekey,ref:"vuetable",attrs:{"api-url":t.apiurl,"api-mode":!0,"http-options":t.httpOptions,fields:t.fields,"item-actions":t.itemActions,"sort-order":t.sortOrder,"show-sort-icons":!0,"multi-sort":t.multiSort,"per-page":t.perpage,"pagination-path":"links.pagination","pagination-component":t.paginationComponent,"append-params":t.moreParams,"wrapper-class":"vuetable-wrapper","loading-class":"loading","detail-row-id":"id",css:t.css.table},on:{"vuetable:pagination-data":t.onPaginationData,"vuetable:load-success":t.loadsuccess},scopedSlots:t._u([{key:"action-slot",fn:function(e){return o("div",{},[o("button",{staticClass:"ti-thought btn btn-outline-secondary btn-sm",attrs:{round:""},on:{click:function(s){return t.onAction("run-item",e.rowData,e.rowIndex)}}})])}}])}),o("div",{staticClass:"vuetable-pagination ui basic segment grid"},[o("vuetable-pagination-info",{ref:"paginationInfo",attrs:{css:t.css.paginationInfo}}),o("vuetable-pagination",{ref:"pagination",attrs:{css:t.css.pagination},on:{"vuetable-pagination:change-page":t.onChangePage}})],1)],1)},V=[],z=s("af52"),K=s("127e"),U=s("3568"),q=s("b3c5"),G={components:{Vuetable:z["Vuetable"],VuetablePagination:U["a"],VuetablePaginationInfo:K["a"],VuetablePaginationDropdown:z["VuetablePaginationDropdown"]},props:{},data(){return{playbookInfo:{},token:"",playbook:{title:"",name:"",description:""},container:{name:"",view:0},pipeline:{},selected:"",options:[{text:"Packages",value:"packages"},{text:"Images",value:"images"},{text:"Scripts",value:"scripts"}],showModal:!1,visibility:[],active:!1,vuetablekey:0,fielddata:{},fields:[{name:"Names",title:'Name',sortField:"Names",visible:!0,dataClass:"left aligned col-3",width:"20%"},{name:"Image",title:'Image',sortField:"Image",visible:!0,dataClass:"left aligned col-3",width:"10%",formatter(t){const e=/^ondemand_playground/.test(t);if(e){var s='

Playground

';return s}s='

Lab

';return s}},{name:"_id",title:'mongo',visible:!1},{name:"ID",sortField:"ID",titleClass:"center aligned",dataClass:"left aligned w-25",visible:!0,width:"10%"},{name:"gitrepoFullName",sortField:"gitrepoFullName",titleClass:"center aligned",dataClass:"left aligned w-25",visible:!1,width:"15%"},{name:"action-slot",title:"Actions",titleClass:"center aligned",dataClass:"center aligned",width:"20%"}],apiurl:$.url_80+"/dockerservices",css:q["a"],perpage:5,searchFor:"",sortOrder:[{field:"pipelinename",direction:"asc"}],multiSort:!0,paginationComponent:"vuetable-pagination",itemActions:[{name:"view-item",label:"",icon:"glyphicon glyphicon-zoom-in",class:"btn btn-info",extra:{title:"View","data-toggle":"tooltip","data-placement":"left"}},{name:"edit-item",label:"",icon:"glyphicon glyphicon-pencil",class:"btn btn-warning",extra:{title:"Edit","data-toggle":"tooltip","data-placement":"top"}},{name:"delete-item",label:"",icon:"glyphicon glyphicon-remove",class:"btn btn-danger",extra:{title:"Delete","data-toggle":"tooltip","data-placement":"right"}}],moreParams:{filter:"",type:"scripts",tutor:"yes"}}},mounted(){},created(){var t=window.location.href,e=new URL(t);this.token=e.searchParams.get("token"),console.log("token "+this.token)},beforeDestroy(){},computed:{httpOptions(){var t=this.token;return{headers:{Authorization:"Bearer "+t}}}},methods:{onError(t,e){var s=e,o="
Bootstrap "+t+"
";this.$swal({type:t,html:o+s,showCloseButton:!0,showLoaderOnConfirm:!1,allowOutsideClick:!1,cancelButtonText:"No, cancel!",showCancelButton:!1,showLoaderOnConfirm:!1,reverseButtons:!0,focusCancel:!0,confirmButtonText:"Ok!"})},setFilter(){this.moreParams={filter:this.searchFor,type:this.selected},o["default"].nextTick(()=>this.$refs.vuetable.refresh())},resetFilter(){this.moreParams={},this.searchFor="",o["default"].nextTick(()=>this.$refs.vuetable.refresh())},onPaginationData(t){this.$refs.pagination.setPaginationData(t),this.$refs.paginationInfo.setPaginationData(t)},onChangePage(t){this.$refs.vuetable.changePage(t)},editRow(t){alert("You clicked edit on"+JSON.stringify(t))},async onAction(t,e,s){"view-item"==t||"delete-item"==t&&this.$swal({type:"info",html:info+winfo,showCloseButton:!0,showLoaderOnConfirm:!1,allowOutsideClick:!1,cancelButtonText:"No, cancel!",showCancelButton:!0,showLoaderOnConfirm:!1,reverseButtons:!0,focusCancel:!0,confirmButtonText:"Yes, Delete it!"})},refreshVuetable(){this.$nextTick(()=>{this.vuetablekey+=1})},playbookinfoShow(t){return this.visibility[t]=!0},playbookinfo(t){return this.playbookInfo=t},rowClicked(t,e){return{html:!0,title:()=>"Hello Popover: "+ ++this.counter,content:()=>"The date is:
"+new Date+""}},loadsuccess(t){var e=t.data.data;this.fielddata=e;e.length}},actions:{}},H=G,Y=(s("0390"),Object(x["a"])(H,M,V,!1,null,null,null)),W=Y.exports,Q={components:{ViewNetwork:P,AdhocView:I,DockerServices:W},data(){return{loading:!1,consoleView:"off",productIndex:1}},mounted(){},beforeDestroy(){},created(){}},X=Q,Z=Object(x["a"])(X,i,r,!1,null,null,null),tt=Z.exports,et={name:"app",components:{NetworkTable:tt},data(){return{show:!0,token:"",SwarmabAsciiLabTemplate:""}},mounted(){},created(){},methods:{hybrid(t){console.log(t)}}},st=et,ot=(s("034f"),Object(x["a"])(st,n,a,!1,null,null,null)),nt=ot.exports,at=s("5886"),it=s("f2d6"),rt=s.n(it),lt=(s("c059"),s("f87c")),ct=s("8e27");o["default"].use(at["default"]),o["default"].use(rt.a);const dt=Object(ct["io"])("https://localhost:3000",{autoConnect:!1,reconnection:!0,reconnectionDelay:500,maxReconnectionAttempts:1/0,pingInterval:25e3,pingTimeout:6e4,transports:["websocket","polling"],secure:!0});o["default"].use(lt["a"],dt),o["default"].use(u["b"]);o["default"].component("ValidationProvider",L["a"]),o["default"].config.productionTip=!1,new o["default"]({el:"#app",store:y,wait:new rt.a,render:t=>t(nt)})},"5dec":function(t,e,s){},"778e":function(t,e,s){},"85ec":function(t,e,s){},b721:function(t,e,s){},c059:function(t,e,s){},cf1c:function(t,e,s){t.exports=s.p+"img/loading.f4404720.gif"},e454:function(t,e,s){}}); //# sourceMappingURL=app.a72e0553.js.map