summaryrefslogtreecommitdiffstats
path: root/src/ogRest.py
Commit message (Collapse)AuthorAgeFilesLines
* Add software command to inventory the machine softwareAlvaro Neira Ayuso2020-01-191-0/+12
| | | | | | | | ogAdmClient has a support to inventory the software in a machine. This new command allows the new ogClient to execute the same script to inventory the sw. The arguments will be received from the server as a json message. Format: { "disk" : "0", "partition" : "1"}
* Add session command to init the opengnsys sessionAlvaro Neira Ayuso2020-01-191-2/+17
| | | | | | | | ogAdmClient has a support for initializing the session in the machine. This new command allows the new ogClient to execute the same script to init the session. The arguments will be received from the server as a json message. Format: { "disk" : "0", "partition" : "1"}
* Create new object for creating dynamic json messagesAlvaro Neira Ayuso2020-01-191-12/+19
|
* (BUG) Handling command errorAlvaro Neira Ayuso2020-01-191-1/+7
| | | | | | This patch adds support for handling the error when the command is wrong formed. Now, if we send a shell/run command and the shell command is incomplete, the program crashes.
* Modify Thread methods namesAlvaro Neira Ayuso2020-01-191-4/+4
| | | | This patch modifies the method names to use names more clear.
* Blocks the program execution until a command is processingAlvaro Neira Ayuso2020-01-191-4/+5
| | | | | This patch changes the command process blocking the execution until is processing. Moreover, the response will be OK (200) instead of IN_PROGRESS (202).
* Create ogThread class to move all thread functionsAlvaro Neira Ayuso2020-01-191-16/+17
| | | | | | Right now, all the thread functions are declared inside the processor function. Those functions were created for execute specific commands in the machine (poweroff, reboot, etc). Creating this new class we are cleaning up the code.
* Execute command received using ThreadsAlvaro Neira Ayuso2020-01-191-1/+5
| | | | | Now we are blocking the execution when we apply a command sent from the server. This behavior is unacceptable for our client.
* Split the commands taking into account GET/POST operationsAlvaro Neira Ayuso2020-01-191-10/+16
|
* Add shell run and output commandsAlvaro Neira Ayuso2020-01-191-7/+47
| | | | | | | | Opengnsys needs a support to execute commands on the machine. This patch adds the support for executing two new commands "shell/run" and "shell/output". The first one, give us the support for executing a command in the machine and keep save in a queue the output. The second one, give us the support for sending the output from the command executed.
* Merge ogRest and ogProcess to have only one classAlvaro Neira Ayuso2020-01-191-7/+48
|
* Add ogRest class to generate API Rest ResponsesAlvaro Neira Ayuso2020-01-191-0/+14
This class now, allow us to generate API Rest responses. In the future, the idea is to complete this class with get and post messages if it's needed.