-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Web Usage #338
Comments
You mean with a web interface? I'm running it in a cloud box right now (using SSH). |
Hello Mike! I mean if I want to run the "web" component of this app locally? I saw there's a web/server.js in the directory. |
unfortunately it was never fully implemented, see #156. It's very easy to add, but could you let me know:
|
For now I just want to move the logs from the console on markets/trading advice to a simple browser log. If it is easy, maybe you can guide us through it? I think no docs written for this? |
So if you very simply just want the same logs in your browser the easiest way would be something like this (works great on linux and os x, not 100% sure about windows): In one terminal start gekko and pipe output to file
In another terminal / command prompt:
Finally, in your browser go to: The other way would be something that I tried in #156. It would be a simple plugin that starts a server and pushes new logdata over a websocket (not implemented but very simple). |
Hello Mike, Got the simple web logger to work. Refreshing it every time is a bit of a hassle. I've read the discussions on #156 but I don't see any walkthrough? Can you take me through on setting up this plugin? Much appreciated! |
Hello Mike, Got your web plugin to work but I've commented out some items. Can you please take a look at this, and check if the lines that I commented out are okay? My next step would be to simulate a simple logger in the web browser in real-time. Hope you can guide me through this. For starters, how do I handle the Much appreciated! |
Made another commit, I think I mixed up I'm testing this out if it will show up the broadcasted advice in the html. Comments are highly appreciated. Thanks! |
Hey John,
Yes, the http server only serves the files for the frontend: event handling logic, the charting libraries and some html. While the ws context is used to broadcast all events (trade advice and market data) in semi realtime to the browser. So I played around with the idea a few years ago, but never actually finished the plugin (it was working but functionality was very limited). A few things to note:
After these changes you should have a server that is able to send data to the browser. However if you look at the index.html, you see that everything is commented out. Probably better to use this version. Note that the data format Gekko uses most likely changed.. |
If you can't get it working I will try to hook it up ASAP. Unfortunately currently do not have the time to commit this. |
yes, sort of. Ws is short for the websocket server. See here |
Hey Mike, It seems that the css url in the |
It was 3 years ago.. You can try this one. |
@jhnferraris You can use my version, it is on the https://github.com/askmike/gekko/tree/webserver After you enable the plugin browse to http://localhost:8080. The result should look like this: It updates in realtime when new advice and/or trade data comes in. If you have any experience in webdevelopment, feel free to take it over from here and replace the raw logging with charts and/or an nice looking interface. |
Hey Mike! Thanks a lot! Saw some stuff that I've missed when I tried experimenting on my end (ie. Sending the Can you send me a PR so I can merge your webserver branch to my repo? |
Done, I am closing this for now. For future readers: the webserver branch has been merged into develop (and will soon be merged into stable). @jhnferraris if you have more questions or issues, feel free to keep commenting here. |
Hello Mike, I've been trying to deploy gekko in Heroku. However, I keep getting a crash state when running in production. Local deployment in heroku works fine though.
My Procfile config is here:
Am I missing something here? Are there any standing issues on deploying gekko in production? Thanks! |
I did missed something. Solution when deploying to Heroku: Remove |
I got the following with a similar procfile as @jhnferraris.
|
@jhnferraris @tidelake The current stable Gekko requires node 6 or higher! |
@askmike My node version is 6.6 iirc. |
I changed to my desired config file and pushed to heroku. The bot only runs for a minute before I get that message. I really appreciate your help. |
You have to change from web to worker, adding a file named worker: node gekko Then, you have to got to Resources of your heroku project and activate it and deactivate web. |
note that I am working on a web UI for gekko, details can be found here: #489. |
You need to replace example.com with your own domain, if you don't have one
you cannot use SSL (since it secures domains).
…On Wed, Oct 11, 2017 at 7:47 PM, metin02oktay ***@***.***> wrote:
Hello there. when I installed the gekko bot I compared it with an error
like this:
***@***.***:~# certbot certonly --standalone -d example.com -d
gekko.example.comSaving debug log to /var/log/letsencrypt/letsencrypt.log
Obtaining a new certificate
Performing the following challenges:
tls-sni-01 challenge for example.com
tls-sni-01 challenge for gekko.example.com
Waiting for verification...
Cleaning up challenges
Failed authorization procedure. example.com (tls-sni-01):
urn:acme:error:unauthorized :: The client lacks sufficient authorization ::
Incorrect validation certificate for tls-sni-01 challenge. Requested
0bc5b2042f3a165890141f639398042c.9742e28ceba767d599a712dbc3698f7d.acme.invalid
from [2606:2800:220:1:248:1893:25c8:1946]:443. Received 2 certificate(s),
first certificate had names "example.com, example.edu, example.net,
example.org, www.example.com, www.example.edu, www.example.net,
www.example.org", gekko.example.com (tls-sni-01):
urn:acme:error:connection :: The server could not connect to the client to
verify the domain :: DNS problem: NXDOMAIN looking up A for
gekko.example.com
IMPORTANT NOTES:
-
The following errors were reported by the server:
Domain: example.com
Type: unauthorized
Detail: Incorrect validation certificate for tls-sni-01 challenge.
Requested
0bc5b2042f3a165890141f639398042c.9742e28ceba767d599a712dbc3698f
7d.acme.invalid
from [2606:2800:220:1:248:1893:25c8:1946]:443. Received 2
certificate(s), first certificate had names "example.com,
example.edu, example.net, example.org, www.example.com,
www.example.edu, www.example.net, www.example.org"
To fix these errors, please make sure that your domain name was
entered correctly and the DNS A/AAAA record(s) for that domain
contain(s) the right IP address.
-
The following errors were reported by the server:
Domain: gekko.example.com
Type: connection
Detail: DNS problem: NXDOMAIN looking up A for gekko.example.com
To fix these errors, please make sure that your domain name was
entered correctly and the DNS A/AAAA record(s) for that domain
contain(s) the right IP address. Additionally, please check that
your computer has a publicly routable IP address and that no
firewalls are preventing the server from communicating with the
client. If you're using the webroot plugin, you should also verify
that you are serving files from the webroot path you provided.
***@***.***:~#
please help me :(
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#338 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA7MD-aSeU3xwHDSZLkqDdc2m2HJR23mks5srLjxgaJpZM4I8h8y>
.
--
PGP key at keybase.io/mikevanrossum
<https://keybase.io/mikevanrossum/key.asc>
|
Any docs for running this in the web?
The text was updated successfully, but these errors were encountered: