summaryrefslogtreecommitdiff
path: root/src/views/_ibs/Operations/Kvm/KvmConsole.vue
diff options
context:
space:
mode:
authorVitalii Lysak <v.lysak@dunice.net>2022-08-30 10:54:30 +0300
committerVitalii Lysak <v.lysak@dunice.net>2022-08-30 10:54:30 +0300
commita7830e9bfb3e0d3988765301f84945328dc51434 (patch)
treea6ef87a6f4b205e80384042d2cec80945a7ec6d4 /src/views/_ibs/Operations/Kvm/KvmConsole.vue
parent33481889c903582e45d9beabc66eac0fe021863b (diff)
parent53053c00715b33ba83b055cb7c0f6bec629d7689 (diff)
downloadwebui-vue-a7830e9bfb3e0d3988765301f84945328dc51434.tar.xz
Merge branch 'sila' of git.sila.ru:pub/openbmc/webui-vue into sila
Diffstat (limited to 'src/views/_ibs/Operations/Kvm/KvmConsole.vue')
-rw-r--r--src/views/_ibs/Operations/Kvm/KvmConsole.vue8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/views/_ibs/Operations/Kvm/KvmConsole.vue b/src/views/_ibs/Operations/Kvm/KvmConsole.vue
index c671a4b9..69fce099 100644
--- a/src/views/_ibs/Operations/Kvm/KvmConsole.vue
+++ b/src/views/_ibs/Operations/Kvm/KvmConsole.vue
@@ -105,12 +105,10 @@ export default {
this.rfb = null;
},
openTerminal() {
+ const url = new URL('/kvm/0', window.location.href);
+ url.protocol = url.protocol.replace('http', 'ws');
const token = this.$store.getters['authentication/token'];
- this.rfb = new RFB(
- this.$refs.panel,
- `wss://${window.location.host}/kvm/0`,
- { wsProtocols: [token] }
- );
+ this.rfb = new RFB(this.$refs.panel, url, { wsProtocols: [token] });
this.rfb.scaleViewport = true;
this.rfb.clipViewport = true;