* Add module support for wrapper script calls
The scripts poller.php and discovery.php offer a module
option (-m), which may be used to specify specific modules
for polling/discovery, possibly for special (and then faster) testing
or for example rediscovering the fdb table (on all hosts).
Until now, this was not possible with the python wrapper scripts.
Now they support a '-m' option, where comma separated module names
may be passed. This will currently only work with poller and discovery, though.
* Replace single quotation signs with double ones (empty strings only)
* Fix more code lines (quotation signs, indentation)
Also 'reduced' if-else-clause size at end of LibreNMS/wrapper.py
(do not call method at each branch, instead prepare a value for modules)
* Add commas after last parameter of dict+methode
Also an additional comment sign before #
* Fix two leftover single quot. signs …
* doc: Add documentation for module support
* New service/discovery/poller wrapper
* Convert old wrapper scripts to bootstrap loaders for wrapper.py
* Move wrapper.py to LibreNMS module directory
* Reformat files
* File reformatting
* bootstrap files reformatting
* Fusion service and wrapper database connections and get_config_data functions
* Moved subprocess calls to command_runner
* LibreNMS library and __init__ fusion
* Reformat files
* Normalize logging use
* Reformatting code
* Fix missing argument for error log
* Fix refactor typo in DBConfig class
* Add default timeout for config.php data fetching
* distributed discovery should finish with a timestamp instead of an epoch
* Fix docstring inside dict prevents service key to work
* Fix poller insert statement
* Fix service wrapper typo
* Update docstring since we changed function behavior
* Normalize SQL statements
* Convert optparse to argparse
* Revert discovery thread number
* Handle debug logging
* Fix file option typo
* Reformat code
* Add credits to source package
* Rename logs depending on the wrapper type
* Cap max logfile size to 10MB
* Reformat code
* Add exception for Redis < 5.0
* Make sure we always log something from service
* Fix bogus description
* Add an error message on missing config file
* Improve error message when .env file cannot be loaded
* Improve wrapper logging
* Fix cron run may fail when environment path is not set
* Add missing -wrapper suffix for logs
* Conform to prior naming scheme
* Linter fix
* Add inline copy of command_runner
* Another linter fix
* Raise exception after logging
* Updated inline command_runner
* Add command_runner to requirements
* I guess I love linter fixes ;)
* Don't spawn more threads than devices
* Fix typo in log call
* Add exit codes to log on error, add command line to debug log
* Add thread name to error message
* Log errors in end message for easier debugging
* Typo fix
* In love of linting
* Add inline command_runner library
* New service/discovery/poller wrapper
* Convert old wrapper scripts to bootstrap loaders for wrapper.py
* Add command_runner to current requirements
* Move wrapper.py to LibreNMS module directory
* Reformat files
* File reformatting
* bootstrap files reformatting
* Fusion service and wrapper database connections and get_config_data functions
* Moved subprocess calls to command_runner
* LibreNMS library and __init__ fusion
* Reformat files
* Normalize logging use
* Reformatting code
* Fix missing argument for error log
* Fix refactor typo in DBConfig class
* Add default timeout for config.php data fetching
* distributed discovery should finish with a timestamp instead of an epoch
* Fix docstring inside dict prevents service key to work
* Fix poller insert statement
* Fix service wrapper typo
* Update docstring since we changed function behavior
* Normalize SQL statements
* Convert optparse to argparse
* Revert discovery thread number
* Handle debug logging
* Fix file option typo
* Reformat code
* Add credits to source package
* Rename logs depending on the wrapper type
* Cap max logfile size to 10MB
* Reformat code
* Add exception for Redis < 5.0
* Make sure we always log something from service
* Fix bogus description
Better validation when config.php does not exist
Update docs and quote password
only populate legacy vars in config_to_json
drop .travis.yml config copy
remove credentials from config.php.default
Check for existance of .env instead of config.php in python scripts
legacy credential cleanup
tiny cleanups
consistent env for artisan server and artisan dusk
Now with optparse (python 2.3+)
Does not include your doc updates @laf
If I get some time later, I'll add them, feel free to as well.
DO NOT DELETE THIS TEXT
#### Please note
> Please read this information carefully. You can run `./scripts/pre-commit.php` to check your code before submitting.
- [ ] Have you followed our [code guidelines?](http://docs.librenms.org/Developing/Code-Guidelines/)
#### Testers
If you would like to test this pull request then please run: `./scripts/github-apply <pr_id>`, i.e `./scripts/github-apply 5926`
* Ability to enable debug output with wrappers
Output is redirected to a per-device file in the log directory.
* Add warning
* Added some docs to help with debugging using this new option
* Supply MySQL database hostname when using Unix sockets to connect
* Pass unix_socket parameter when db_socket is set
* Set db_host to localhost when db_socket is set
* Add support for custom MySQL unix-socket
* NULL must be lowercase!
* Naive edit of html/install.php
* fixup
* Refactor dbConnect
Use it everywhere
* $config needs to be global
Don't need to set $database_link
* small cleanups
If the poller master doesn't complete in time and ends up with overlapping jobs, neither job will ever complete because both running jobs will think they are the master and wait for the remaining node to exit.