14 Commits

Author SHA1 Message Date
20b4215204 Swich links to https (#12511)
* Switch librenms links to https

* Convert librenms links in comments

* Switch gnu.org url to https

* switch php urls to https
2021-02-09 00:29:04 +01:00
5f0388f0e3 Remove DB credentials from config.php
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
2020-06-27 07:47:08 -05:00
2a5b1fd071 Clearer python-memcached info (#11772) 2020-06-04 20:36:25 -05:00
0b68c70a97 Python wrapper sql cleanup (#11628)
* Clean up wrapp mysql connect a bit

* fix typo
2020-05-19 10:14:09 -05:00
ec3dc4f89b Don't use command_runner (#11618) 2020-05-15 08:29:30 -05:00
1dd0d46edd Migrate Python scripts to Python 3 (#10759)
* Migrate to python3

* Migrate to python3

* Migrate to python3

* Migrate to python3

* Code refactoring and python 2 compat

* Code refactoring and python 2 compat

* Code refactoring and python 2 compat

* Code refactoring and python 2 compat

* Added shared code for wrappers

* Fix python version check

* Allow pure python MySQL library

* move library.py
remove python2 support bits
remove duplicate code

* fix log location

* whitespace?

* fix pre-existing bug

* fix bug when no devices/services exist

* fix pylint issues

* update imports to match

Co-authored-by: Tony Murray <murraytony@gmail.com>
2020-05-15 00:37:34 -05:00
34f0788461 Fix connecting via socket (#11523)
When trying to use this services-wrapper.py on FreeBSD I was unable to connect to my database. When using the socket logic from the other wrapper python scripts it works fine. Streamline this wrapper with that same logic from poller-wrapper.py and discovery-wrapper.py.
2020-05-02 12:11:18 -05:00
b3690ea11e Read the db_port as integer (#11392)
db_port must be read as integer.
I have missed to add this in the pull 11284
2020-04-08 16:27:53 -05:00
c9e90cc827 db_port setting missing (#11284)
If db_port is set in the config.php, services-wrapper will not work.
This fixes the issue and adds a check if db_port is set to be used as the DB port when connecting.
I used 'if SETTING in config' method as this is used below in the script.
2020-03-13 20:37:45 +01:00
a1aaafa6ff Added ability to enable debug output with wrappers (#8830)
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`
2018-06-20 22:56:51 +01:00
45f98872bb Revert "Ability to enable debug output with wrappers" (#8829)
Reverts librenms/librenms#8811
2018-06-16 14:32:28 +01:00
fd77b23624 Added debug options to wrapper scripts to record output to logs/ dir (#8811)
* 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
2018-06-15 14:22:43 +01:00
b1a414e785 feature: support non-standard unix socket (#5724)
* 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
2017-04-06 22:02:37 +01:00
c5a3d82040 feature: Add services-wrapper.py to enable support for distributed setups with service checks #4658 2017-01-12 08:29:29 +00:00