Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
goshimmer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
iota-imt
goshimmer
Commits
ebd91cff
Unverified
Commit
ebd91cff
authored
5 years ago
by
Hans Moog
Committed by
GitHub
5 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #83 from Evanfeenstra/ui
fix ws/wss for https://
parents
e7069df3
01db9334
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
plugins/ui/files.go
+5
-1
5 additions, 1 deletion
plugins/ui/files.go
plugins/ui/src/js/main.js
+5
-1
5 additions, 1 deletion
plugins/ui/src/js/main.js
plugins/ui/ui.go
+0
-6
0 additions, 6 deletions
plugins/ui/ui.go
with
10 additions
and
8 deletions
plugins/ui/files.go
+
5
−
1
View file @
ebd91cff
...
...
@@ -494,8 +494,12 @@ Vue.component('empty-icon', {
this.show()
this.loggedIn = true
this.selectedTab = 'Logs'
let wsProtocol = 'wss:'
if (location.protocol != 'https:') {
wsProtocol = 'ws:'
}
this.ws = new WebSocket(
api.addToken(
'
ws
:
//'+window.location.host+'/ws')
api.addToken(ws
Protocol+'
//'+window.location.host+'/ws')
)
this.ws.onopen = (e) => { this.connected=true }
this.ws.onclose = (e) => { this.connected=false }
...
...
This diff is collapsed.
Click to expand it.
plugins/ui/src/js/main.js
+
5
−
1
View file @
ebd91cff
...
...
@@ -34,8 +34,12 @@ new Vue({
this
.
show
()
this
.
loggedIn
=
true
this
.
selectedTab
=
'
Logs
'
let
wsProtocol
=
'
wss:
'
if
(
location
.
protocol
!=
'
https:
'
)
{
wsProtocol
=
'
ws:
'
}
this
.
ws
=
new
WebSocket
(
api
.
addToken
(
'
ws
:
//
'
+
window
.
location
.
host
+
'
/ws
'
)
api
.
addToken
(
ws
Protocol
+
'
//
'
+
window
.
location
.
host
+
'
/ws
'
)
)
this
.
ws
.
onopen
=
(
e
)
=>
{
this
.
connected
=
true
}
this
.
ws
.
onclose
=
(
e
)
=>
{
this
.
connected
=
false
}
...
...
This diff is collapsed.
Click to expand it.
plugins/ui/ui.go
+
0
−
6
View file @
ebd91cff
...
...
@@ -46,14 +46,8 @@ func configure(plugin *node.Plugin) {
}()
}))
node
.
DEFAULT_LOGGER
.
SetEnabled
(
false
)
uiLogger
.
SetEnabled
(
true
)
plugin
.
Node
.
AddLogger
(
uiLogger
)
daemon
.
Events
.
Shutdown
.
Attach
(
events
.
NewClosure
(
func
()
{
node
.
DEFAULT_LOGGER
.
SetEnabled
(
true
)
}))
}
func
staticFileServer
(
c
echo
.
Context
)
error
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment