-
-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IPC GUI #610
Comments
A minimal example using jquery can be found here: Sending commands and reading replys works in firefox and chrome (rest unchecked), loading the log, only in firefox. (and not in chrome). For reading the logs nothing but jquery.load worked. But I am not sure if this functionality is really needed. Sending commands could be done without jquery. |
I'm using this ruby script to communicate with ASF through IPC.
|
I would say use a grid, like the one from syncfusion or bootstrap, with a bar on top for all possible actions. Then if you want to execute an action on one or multiple bots, just check the boxes before each bot (or just all) and click the corresponding button. A second tab in the menu could show a log. AdminLTE, which uses Bootstrap and could be a nice looking framework. |
@kaoyusu - how to use it? EDIT: hehe - yo soy muy stupido xD |
ASF-IPC-GUI.zip |
@JustArchi |
Then ASFui should be updated to match new structure - it was clearly stated in V3 migration article that current way of accessing IPC is considered to be temporary until a good idea of a proper API is ready. I don't plan supporting obsolete and much more problematic to execute ways such as Now the API is ready and I do plan to keep it as compatible as possible in future versions, but I don't want to hold on obsolete temporary dependencies that were announced to be temporary in the first place. |
It'd be a good idea to make use of extra time the version still being in pre-release and let @alvr correct the URL, since the change is really misc. |
OK, would be nice if you could update the wiki then to include the changed IPC endpoint. |
BTW, doesn't ASF output received IPC commands to console anymore? This was rather useful. |
Would be nice if people read 🤔 |
Is there any way to setup SSL for IPC server? 🤔 |
Nope, that would require from ASF server to have valid SSL certificate and add extra overhead. If you need ASF IPC interface over SSL then I strongly recommend to use reverse-proxy. Nginx can be a very good solution for that.
Then you can just set your website to use any protocol and port you want to, including securing it with SSL and certificate. |
Oh, forgot that I can use nginx as a proxy. 👍 |
Another way, change IPC server to *:80 and use Cloudflare Flexible SSL. Point domain to server's IP 😁 |
i always get 404 when i run it on my rootserver |
I'm not sure if IPC isn't completely ready yet (as of update V3.0.5.1), but issuing commands via POST request isn't working for me. Here's what I'm trying to do:
I also got this on ASF:
|
new IPC is broken |
@guihkx You have your error clearly stated in the response:
You can't send POST request without specifying As for the exception it's good that you reported it, will cover it in V3.0.5.2. @Benman2785 Nothing is broken, thanks for your concern. |
@guihkx You can continue hunting bugs in V3.0.5.2, especially all IPC-related exceptions 🙂 |
I just tried to replicate the request as stated in this section of the Wiki... Am I missing something? I really don't know. |
I just told you what you're missing - read again. |
Yes, the |
The example on the wiki doesn't require request body 🙂 |
@Basdower not that I am aware of. @Benman2785 404 means you screwed up the link. Check the wiki for correct syntax. |
@KlappPc i know - but here is my problem ;) i can do: this works - but i have to hardcode any command to the button - because if i try
it wont work - i always get 404 |
@Benman2785 i think you must provide a command in url
|
You need to append the command using javascript. The second example will append stuff as parameters, while you need it there as in your first example. |
@KlappPc https://discord.gg/qb7mHwV - pls find me there ;) @deluxghost as i did in the first try - but that is not what i want - i want a textfield where i can put my command and execute it lets say i want to redeem a key - i simply want to copy it in the textarea and klick redeem ;) |
@Benman2785 This can give you a hint |
thank you ;) Merry X-Mas // dennoch schone Weihnachten ;) |
@Benman2785 Danke gleichfalls. |
that was the problem i was looking a solution for thank you again edit - got it - also working with all my bots (in one file) ;) |
As you are working on the new IPC interface right now, how about adding more information to the response, so you do not have to parse the Result to receive the info you want? E.g.: curl -s -X POST -d '' "http://127.0.0.1:1242/Api/Command/redeem^%20bot%20SD,SF%20abcde-abcde-abcde%20aaaaa-aaaaa-aaaaa" | jq {
"Message": "OK",
"Resulttext": "\n<bot> Key: abcde-abcde-abcde | Status: Fail/BadActivationCode\n<bot> Key: aaaaa-aaaaa-aaaaa | Status: Fail/BadActivationCode",
"Result": [
{
"Key": "abcde-abcde-abcde",
"Status": false,
"Statustext": "BadActivationCode",
},
{
"Key": "aaaaa-aaaaa-aaaaa",
"Status": false,
"Statustext": "BadActivationCode",
}
],
"Success": true
} The structure is just the first I came up with. This can be improved and enhanced by missing information, e.g. bot instance. |
this is my console :B |
@Zarat99 looks nice! maybe we can work together on the design. Happy New Year. I am back from my holiday and will work on the GUI, so its half way functional. Then I will send it to you so you can merge it into ASF. Thanks for all the new features in IPC! |
@MrBurrBurr How's the GUI coming along? Wouldn't mind getting my hands on it :D |
I am working on it but I cant spend as much time on it as I would like to due to work and other projects. Maybe I should just upload the unfinished, "dirty" base GUI. That way more people could work on it together and maybe help me out. What do you think @JustArchi? |
@MrBurrBurr know how it is, as I deal with that same problem daily :x I honestly wouldn't mind it even in a "dirty" state as you put it as it's a lot better than what I'd ever be able to come up with more than likely >..< |
@MrBurrBurr That's up to you, you can post it if you want more people to work on it and eventually send PR, or finish it yourself. When it comes to me I'm just waiting for somebody to send a PR and start a thing, it's natural that other people will improve it once it's merged. |
@MrBurrBurr |
I will do some final clean up and remove some of the unfinished parts (like config generator). Then I will send a PR so you can implement the basic version of the GUI. In that way we got a base where everyone else that wants to help can do so. I guess the code will also turn from ugly into something useable once we got a base. 🙂 |
awesome ;) |
@MrBurrBurr how is cleanup going? still waiting to get my hands on your GUI xD |
To be honest I am kinda stuck right now. Clean up is almost done but my main problem right now is getting rid of all the hardcoded shit I used when the GUI was just ment for me. For example reading the config values like IPC Host and IPC Port. Right now I am not using node.js or any other manager so reading values from a JSON file is kinda dirty. I am open to help if anyone know how to counter that problem. |
@MrBurrBurr , what about a cookie ? |
I managed to solve some of my problems. Right now the code is still a mess and here and there are some bugs. Still I want to release it finally so more people can work on it and so we finally get things started. @JustArchi While doing the clean up I also came up with a lot of ideas for the GUI. I think we should make a list with improvements that we want to have (like you did before with issue #659). Here are some:
|
@MrBurrBurr I'm not archi but I say do it! but that's just me wanting the GUI already xD |
What do you mean by that? Physical location of files doesn't matter for functionality. Just create |
Closed by #731 |
I completely forgot that we intentionally omit sensitive details, so bot config update API should have a way to inherit them without exposing, this will do. Note to self: ALWAYS use custom JSON classes, so I won't need to break API just like like now, at worst I'll add new acceptable properties.
Since we have a nicely working HTTP IPC in ASF V3 now, we could make use of that fact and code a nice ASF GUI purely in html, javascript and css. IPC can easily communicate with ASF and execute commands, fetch status and expose other things over friendly HTTP interface, with all sort of needed events and stuff. Something like typical web-admin interface for a game server.
Of course, as usual I'm not interested in doing any of that myself, so I'm just putting up issue on hold in case anybody would want to make it happen. I'm too awful at html/css/js to start working on that, but I can help gluing everything together if somebody has html/css/js ready and general idea how entire thing should work/look like.
The text was updated successfully, but these errors were encountered: