Use Log facility when Laravel is booted.
Update init.php so we can easily boot Laravel for CLI scripts. (and just Eloquent, but that may go away)
Move all debug setup into set_debug() function and use that across all scripts.
Log Laravel database queries.
Send debug output to librenms log file when enabling debug in the webui.
Allow for colorized Log CLI output. (currently will leave % tags in log file output)
** Needs testing and perhaps tweaking still.
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.
- [x] 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`
* Add support for Allied Telesis AlliedWare Plus products
- Uses mibs from 5.4.7-2.1 for AlliedWare Plus products
- Updates Legacy AlliedWare mibs
- Added Allied Telesis svg
* Remove unnecessary "trim" from snmpget
* Add new line to end of file
* Minor fixes for commit
* awplus: initial ntp commit
This isn't completely working, however initial patch of it partially working
* awplus: Add NTP support
- Fixed polling issues for awplus. Now offset and delay graphs work.
- html/includes/graphs/device/ntp_*.inc.php
-- Removed extra "\" from MAX count which showed up in Graph legend
- html/includes/graphs/device/ntp_delay.inc.php
-- Present legend in either seconds, or milliseconds (depending on vendor)
- html/includes/graphs/device/ntp_dispersion.inc.php
-- Present legend in either seconds, or milliseconds (depending on vendor)
- html/includes/graphs/device/ntp_offset.inc.php
-- Removed rrd minimum (-l 0). This is because offset can be below 0.
--- It's better for the graph to auto scale than set a fixed minimum to display here.
- html/includes/graphs/device/ntp_stratum.inc.php
-- Changed graph to go from 0 to max of 16. NTP Stratum can only be 0 to 16.
* awplus: Add NTP test data
* updated awplus ntp poller
* device: awplus convert NTP poller into seconds
* device: fix NTP graph formatting
* device: Improve NTP formatting
* device: unset awplus NTP variable
* fix formatting
* device: awplus change NTP from numerical OIDs to named
* device: update awplus ntp json tests
* device: fix cisco and awplus ntp database creation
* device: update awplus json
* Refactor remove use of pear Net_IPv4 and Net_IPv6
Caution, I added tests to test the functionality of the new functions, but I'm not 100% certain the replaced usages match 100%. Please test.
Left usage in generate-iplist.php because I'm not sure the use of that script, so I didn't want to implement additional functionality to support it.
Add support for ipv6 fo ipInNetwork() function
Add phpdocs to functions
Remove accidental inclusion
Use binary operations instead of string for networKFromIp()
Tidy up binary operations in ipInNetwork()
tidy parsing cidr network
Change to a class based implementation.
Update phpdocs.
Fully catch exceptions for hex parsing.
Fix mistake.
support older phpunit versions
Fix php shifting to negative with php 5
* Fix graph authorization. Uncaught exception and checking an ipv4 against an ipv6 network == fail.
* Also remove colons from hex strings.
* Fix typo in bgp polling
Two passes of removing invalid characters from hex strings. (That way we don't mangle valid IPs)
~ Changed: Message for the NTP discovery and polling altered. A stratum of 16
is not 'Insane' its actually not in sync as per the RFC 5909 specification.
See: https://tools.ietf.org/html/rfc5905#page-21 Fig. 11 for reference.
* Implement an autoloader
When cleaning up classes for psr2, things got a bit unwieldy, so I implemented a class autoloader.
I created a PSR-0 compliant LibreNMS directory and moved all classes there that made sense.
Implemented LibreNMS\ClassLoader which supports adding manual class mappings
This reduces the file includes needed and only loads classes when needed.
* Add teh autoloader to graph.php
* Add a small bit of docs
Fix incomplete class in includes/discovery/functions.inc.php