summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Add OgVM class to abstract VMsRoberto Hueso Gómez2020-04-281-9/+36
| | | | | This patch implements OgVM class. OgVM abstracts VM emulator from its operations.
* Poweroff VM before some operationsRoberto Hueso Gómez2020-04-281-22/+20
| | | | | | This patch includes changes to: - Poweroff VM before running operations that require access to virtual disks. - Poweroff VM before host system poweroff.
* Send last stored setup if VM is runningRoberto Hueso Gómez2020-04-281-6/+21
| | | | | When virtual mode is activated, send the last stored partitions setup because it is not possible to access a running virtual drive to get its information.
* Add OgQMP recv methodRoberto Hueso Gómez2020-04-281-1/+23
| | | | | | recv method is useful for receiving information that was not previously requested (such as "events"). This patch also implements automatic handshake on OgQMP by sending an "qmp_capabilities" request.
* Fix disk used size calculationRoberto Hueso Gómez2020-04-281-1/+1
| | | | | This patch calculates correctly the percentage of disk used. This could cause an overflow on the ogAdmSever DB.
* Control errors in OgQMP for virtual modeRoberto Hueso Gómez2020-04-221-59/+78
| | | | | This patch handles possible communication errors between ogclient and Qemu when making QMP requests.
* Add realtime log menuJavier Sánchez Parra2020-04-221-6/+26
| | | | | | | | | | | We observed that with the new ogClient the ogLive did not show the realtime log menu*. This commit changes the ogClient to launch the browser and show the realtime log menu when some commands are executed. * The realtime log menu is a menu that shows current status and info about the command that the ogLive is executing.
* Avoid killing ogclient in virtual modeRoberto Hueso Gómez2020-04-201-8/+8
|
* Avoid writting /software output to a fileRoberto Hueso Gómez2020-04-173-11/+9
|
* Use samba for create and restore virtual partitionsRoberto Hueso Gómez2020-04-173-5/+24
| | | | This requires to configure user and password for samba repositories.
* Use libguestfs for virtual setupRoberto Hueso Gómez2020-04-171-11/+12
|
* Use libguestfs for virtual refreshRoberto Hueso Gómez2020-04-171-14/+30
|
* Transform absolute paths into relative paths for virtual modeRoberto Hueso Gómez2020-04-171-15/+26
|
* Increase HTML menu regeneration casesJavier Sánchez Parra2020-04-161-0/+4
| | | | | | | | | | We have observed that the ogLive browser did not show the changes when an image restoration o script execution was called. The problem was that the HTML menu was not updated/regenerated in these cases. This commit adds the call to the HTML regeneration function to image restore and script execution commands. This way, when the browser is restarted it loads the updated HTML menu.
* Change browser behaviourJavier Sánchez Parra2020-04-161-0/+21
| | | | | | | | | | We have observed that the browser did not show changes. This happens because the ogClient opens the browser at the beginning and forget about it. To show correctly the changes ogClient had to restart the browser every time the menu html changes. This commit changes the behaviour to restart the browser when the menu html has changed.
* wait for 1 second if connection is refusedOpenGnSys Support Team2020-04-141-18/+6
|
* Sleep 1 second to avoid high CPU loadRoberto Hueso Gomez2020-04-141-0/+1
|
* Avoid connection status infinite print loopRoberto Hueso Gomez2020-04-141-7/+17
| | | | This patch avoids infinite writting of connection status messages to the log.
* Fix reboot and poweroff threads argsRoberto Hueso Gomez2020-04-131-2/+2
|
* Add placeholder for virtual execCMDRoberto Hueso Gomez2020-04-131-0/+4
|
* Use 75% of disk space in virtual modeRoberto Hueso Gomez2020-04-081-0/+3
|
* Add mode selection for ogClientRoberto Hueso Gomez2020-04-082-19/+31
|
* Encapsulate operations in classesRoberto Hueso Gomez2020-04-082-515/+517
|
* Add virtual operationsRoberto Hueso Gomez2020-04-072-0/+403
|
* missing update to use ogConfig.OG_PATH in linux/ogOperations.pyOpenGnSys Support Team2020-03-201-1/+1
|
* Make OG_PATH publicJavier Sanchez Parra2020-03-202-13/+15
| | | | | This commit changes the OG_PATH to a public varible of the class ogConfig. This way we improve the configurability of the path.
* rename getURI to get_uri in restRequestOpenGnSys Support Team2020-03-092-2/+2
|
* rename execcmd to shellrunOpenGnSys Support Team2020-03-091-2/+2
|
* use lowercase attribute name in restRequestOpenGnSys Support Team2020-03-091-13/+13
|
* Put state to IDLE after run/scheduleRoberto Hueso Gómez2020-03-031-0/+1
|
* Send complete HTTP header when response has no bodyRoberto Hueso Gómez2020-03-021-1/+2
|
* Rename operation to methodOpenGnSys Support Team2020-02-263-8/+8
| | | | As defined by the HTTP standard.
* Search the key in the parsed jsonJavier Sanchez Parra2020-02-261-13/+12
| | | | | | | | | | | | | | | | | | | | | Testing the ogClient I found that if a value of the json match a key the ogClient has an exception. For example: body = "... shell/run {"run": "fdisk -l"} ..." CURRENT Enters in if "disk" in body:... if "run" in body:... EXPECTED Enters in if "run" in body:... This commit changes the behaviour to search for the keys in the dictionary returned by json.loads() instead of searching in the raw string. This way the ogClient looks for the keys without searching in the values.
* Handle scripts that end in \rRoberto Hueso Gómez2020-02-251-1/+1
|
* Modify way to close PID processAlvaro Neira Ayuso2020-02-241-12/+17
| | | | | | With our client disconnection, we hid that the ogClient process will be closed too. This new way only close the subprocess keeping the ogClient still working.
* Use state machine to avoid race condition problemsAlvaro Neira Ayuso2020-02-231-11/+63
| | | | | | This patch allows us to control the thread using a state machine. This state machine controls if the client is busy or not. This new way to control the threads give us more control for avoiding race condition problems.
* remove unused gettersOpenGnSys Support Team2020-02-211-18/+0
|
* pep-0008 cleanupOpenGnSys Support Team2020-02-212-43/+43
| | | | | | | From pep-0008: Method Names and Instance Variables Use the function naming rules: lowercase with words separated by underscores as necessary to improve readability.
* Use 'bash' as the default shell for operations scriptsRoberto Hueso Gómez2020-02-091-12/+28
|
* Use 'with' keyword for file readingRoberto Hueso Gómez2020-02-051-9/+4
| | | | | | This is applied to /software and /hardware file reads. We should use 'with' instead of opening and closing a file since this prevents that files stay open after an exception is raised.
* Use python f-strings for commands compositionRoberto Hueso Gómez2020-02-051-14/+13
|
* Fix /session executionRoberto Hueso Gómez2020-02-051-1/+4
| | | | The script now reads arguments correctly.
* Fix /image/restore execution and responseRoberto Hueso Gómez2020-02-052-1/+10
|
* Fix /image/create execution and responseRoberto Hueso Gómez2020-02-052-7/+12
|
* (BUG) Rename OG_SCRIPT_PATH to OG_PATHAlvaro Neira Ayuso2020-02-041-2/+2
|
* Fix /setup execution and responseRoberto Hueso Gómez2020-02-032-16/+17
|
* Fix parseGetConf(...) configuration parsingRoberto Hueso Gómez2020-02-033-27/+29
| | | | This patch also reformats the response to the /refresh command.
* add space after Content-Length and Content-TypeOpenGnSys Support Team2020-01-281-2/+2
| | | | ogAdmServer needs this space to work fine.
* Change POST /refresh to GET /refreshRoberto Hueso Gómez2020-01-212-6/+6
| | | | | This patch changes the HTTP method for /refresh and cleans up the implementation of the /refresh Linux operator.
* Fix /software command Linux operationRoberto Hueso Gómez2020-01-212-4/+10
| | | | | This patch runs the script InventarioSoftware with the right arguments. This also increases the recv buffer size for the test server.