1 <%# Copyright (C) The Arvados Authors. All rights reserved.
3 SPDX-License-Identifier: AGPL-3.0 %>
6 <title><%= @object.hostname %> / <%= Rails.configuration.site_name %></title>
7 <link rel="stylesheet" href="<%= asset_path 'webshell/styles.css' %>" type="text/css">
8 <style type="text/css">
13 <script type="text/javascript"><!--
15 // We would like to hide overflowing lines as this can lead to
16 // visually jarring results if the browser substitutes oversized
17 // Unicode characters from different fonts. Unfortunately, a bug
18 // in Firefox prevents it from allowing multi-line text
19 // selections whenever we change the "overflow" style. So, only
20 // do so for non-Netscape browsers.
21 if (typeof navigator.appName == 'undefined' ||
22 navigator.appName != 'Netscape') {
23 document.write('<style type="text/css">' +
24 '#vt100 #console div, #vt100 #alt_console div {' +
25 ' overflow: hidden;' +
31 function login(username, token) {
32 var sh = new ShellInABox("<%= j @webshell_url %>");
33 setTimeout(function() {
34 sh.keysPressed("<%= j params[:login] %>\n");
35 setTimeout(function() {
36 sh.keysPressed("<%= j Thread.current[:arvados_api_token] %>\n");
37 sh.vt100('(sent authentication token)\n');
43 <link rel="icon" href="<%= asset_path 'favicon.ico' %>" type="image/x-icon">
44 <script type="text/javascript" src="<%= asset_path 'webshell/shell_in_a_box.js' %>"></script>
46 <!-- Load ShellInABox from a timer as Konqueror sometimes fails to
47 correctly deal with the enclosing frameset (if any), if we do not
50 <body onload="setTimeout(login, 1000)"
51 scroll="no"><noscript>JavaScript must be enabled for ShellInABox</noscript>