- Jan 04, 2010
-
-
Iustin Pop authored
Of all daemons, only rapi did abort when given argument. None of our daemons use any arguments, but they accepted them blindly. This is a very bad experience for the user. This patch adds checking and exiting in all daemons, in a uniform way. One other option would have been to add a flag to GenericMain (noargs=True). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
This removes unused variables in the rest of the code (outside lib/). Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
Iustin Pop authored
This patch should have only: - pylint disables - docstring changes - whitespace changes Signed-off-by:
Iustin Pop <iustin@google.com> Reviewed-by:
Olivier Tharan <olive@google.com>
-
- Oct 29, 2009
-
-
Michael Hanselmann authored
This enables the use of hashed passwords in rapi_users. Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Aug 25, 2009
-
-
Michael Hanselmann authored
Signed-off-by:
Michael Hanselmann <hansmi@google.com> Reviewed-by:
Iustin Pop <iustin@google.com>
-
- Jul 26, 2009
-
-
Guido Trotter authored
Signed-off-by:
Guido Trotter <ultrotter@google.com>
-
- Jul 25, 2009
-
-
Guido Trotter authored
With three ganeti daemons, and one or two more coming, the daemon's main function started becoming too much cut&pasted code. Collapsing most of it in a daemon.GenericMain function. Some more code could be collapsed between the two http-based daemons, but since the new daemons won't be http-based we won't do it right now. As a bonus a functionality for overriding the network port on the command line for all network based nodes is added. Signed-off-by:
Guido Trotter <ultrotter@google.com>
-
- Jul 24, 2009
-
-
Guido Trotter authored
The <DAEMON>_PID constants were created to reference a daemon pid file, but actually contain a daemon's name, because the various functions that work with pidfiles abstract the filename from the daemon name themselves. Removing the constants and using the actual daemon name constants in their place. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Guido Trotter authored
The original LOG_<DAEMON_NAME> constants for daemon logfiles are gone. In their place there is a DAEMONS_LOGFILES dict, indexed by daemon name. This is a minor change with the objective to uniform most of the daemon's main() functions code, which is very similar one to the other. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Guido Trotter authored
Currently rapi is the only daemon which accepts a port option, rather than querying its own port from services, and failing back to the default if not found. Changing this to conform to what other daemons do. Also update the ganeti-rapi(8) manpage Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Jul 23, 2009
-
-
Guido Trotter authored
substitute exit(1) with exit(constants.EXIT_FAILURE). Also fix a wrongly indented line. Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
Guido Trotter authored
Signed-off-by:
Guido Trotter <ultrotter@google.com> Reviewed-by:
Michael Hanselmann <hansmi@google.com>
-
- Feb 13, 2009
-
-
Iustin Pop authored
This patch fixes many small issues related to write functions: - update documentations w.r.t. how to add users - update the instance add function for latest API - add instance delete - fix addition of tags - update some error messages Reviewed-by: imsnah
-
Iustin Pop authored
This patch changes the format of the HTTP error messages from text/html, which is hard to parse from RAPI clients, to JSON which can be automatically parsed. The error message is an object, which contains always three keys: - code, an integer with the error code - message, a short description - explain, holding (if available) a description of the error In order to implement this, there is a bit of change to the http server and executor classes. I've tested and the error handling still works (but less optimal, no error message) in case the error formatting itself raises an exception. Reviewed-by: imsnah
-
Iustin Pop authored
This changes the RAPI error codes for luxi errors; a timeout error is now reported properly as 504, while any other luxi error is reported as 502. It would be good to convert even more errors into proper return codes in the future. Reviewed-by: imsnah
-
Iustin Pop authored
This patch displays a nicer error message compared to the default stacktrace. Reviewed-by: imsnah
-
- Feb 05, 2009
-
-
Iustin Pop authored
This patch fixes the SSL mode (by actually constructing SSL parameters from the command line options) and enables SSL by default; the old “-S” option which enabled SSL is now changed to “--no-ssl”. The certificate and key are by default pointing to the Ganeti auto-generated certificate for rapi. Reviewed-by: imsnah
-
- Feb 04, 2009
-
-
Iustin Pop authored
For queries, we don't want to require authentication. We fix this by adding an override GetAuthRealm in the rapi daemon. We also fix a method name. Reviewed-by: imsnah
-
- Jan 09, 2009
-
-
Iustin Pop authored
The current fork+close fds sequence has deficiencies which are hard to work around: - logging can start logging before we fork (e.g. if we need to emit messages related to master checking), and thus use FDs which we can't track nicely - the queue locks the queue file, and again this fd needs to be kept open which is hard from the main loop (and this error is currently hidden by the fact that we don't log it) Given the above, it's much simpler, in case we will fork later, to close file descriptors right at the beginning of the program, and in Daemonize only close/reopen the stdin/out/err fds. In addition, we also close() the handlers we remove in SetupLogging so that the cleanup is more thorough. Reviewed-by: imsnah
-
- Jan 06, 2009
-
-
Iustin Pop authored
Two bad indentation cases and a missing variable. Reviewed-by: imsnah
-
- Dec 19, 2008
-
-
Michael Hanselmann authored
Passwords are stored in "$localstatedir/lib/ganeti/rapi_users". User options specify the access permissions of a user (see docstring for ganeti.http.ReadPasswordFile), for which only "write" is supported to grant write access. Every other user has read-only access. Reviewed-by: amishchenko
-
Michael Hanselmann authored
This will be used to evaluate access permissions to resources. Reviewed-by: amishchenko
-
- Dec 11, 2008
-
-
Iustin Pop authored
This patch should fix all outstanding epydoc parsing errors; as such, we switch epydoc into verbose mode so that any new errors will be visible. Reviewed-by: imsnah
-
- Dec 04, 2008
-
-
Michael Hanselmann authored
Reviewed-by: amishchenko
-
Michael Hanselmann authored
It should be consistent. Reviewed-by: amishchenko
-
- Oct 24, 2008
-
-
Michael Hanselmann authored
At the same time, simplify the interface a bit by not using a tuple. Reviewed-by: killerfoxi, ultrotter
-
- Oct 21, 2008
-
-
Oleksiy Mishchenko authored
Reviewed-by: iustinp
-
- Oct 20, 2008
-
-
Iustin Pop authored
Since now we use only one function from the logger module (SetupLogging), we move it to utils.py (which is already imported by all users of this function), and we remove the module. Reviewed-by: imsnah
-
- Oct 17, 2008
-
-
Oleksiy Mishchenko authored
Reviewed-by: imsnah
-
- Oct 16, 2008
-
-
Michael Hanselmann authored
Requests are no longer logged to a separate file. Reviewed-by: amishchenko
-
- Oct 15, 2008
-
-
Michael Hanselmann authored
Reviewed-by: ultrotter
-
- Jul 31, 2008
-
-
Oleksiy Mishchenko authored
Add instance tag handling, improved error logging. ...oh, yes adopt instance listing for RAPI2! Reviewed-by: iustinp
-
- Jul 30, 2008
-
-
Iustin Pop authored
This patch moves the CheckMaster function from ganeti-masterd to ssconf (most logical place, it cannot go in utils since we would have recursive imports between ssconf and utils) and changes ganeti-rapi to also call this function. This is needed so that starting ganeti-rapi on a non-master node does the right thing. Reviewed-by: ultrotter
-
- Jul 29, 2008
-
-
Iustin Pop authored
Reviewed-by: imsnah
-
Iustin Pop authored
This is needed for controlling it cleanly with start-stop daemon. Reviewed-by: ultrotter
-
- Jul 28, 2008
-
-
Michael Hanselmann authored
Reviewed-by: iustinp
-
Michael Hanselmann authored
All other daemons have their main code in themselves and not in a module. This patch does the same to ganeti-rapi by moving the code from lib/rapi/RESTHTTPServer.py to daemons/ganeti-rapi. Reviewed-by: iustinp
-
- Jul 11, 2008
-
-
Oleksiy Mishchenko authored
Reviewed-by: iustinp
-