Commit Graph

109 Commits

Author SHA1 Message Date
VTS
47c6842b01
API: get poller group (#15493)
* API: get poller group

* missed string in doc

* return all poller groups if name/id aren't specified

* add missing doc link

* style fixes

* more style

---------

Co-authored-by: Tony Murray <murraytony@gmail.com>
2023-11-01 22:33:35 -05:00
Tony Murray
d304570c32
Redirect old install docs (#15505)
* Remove old install docs
redirect them to the current docs

* Add redirect for Debian 11 that apparently still exists?

* Clean up old links
2023-10-25 12:50:56 -05:00
Santiago Z
adc953a9a2
[DOC] Added social links in footer (#15195)
* [DOC] Added copyright and social links in footer

* Update mkdocs.yml
2023-08-04 17:56:43 +02:00
Neil Lathwood
49e40842c7
Re-add the Ubuntu Image page and links (#15041) 2023-05-18 08:38:45 -05:00
Tony Murray
24f6de37db
Remove references to VM images (#15031)
* Remove references to VM images
Use docker instead

* Remove references and add redirect
2023-05-09 10:51:12 -05:00
Jellyfrog
83126161d9
Update to mkdocs-material 8.3.9 (#14189) 2022-08-08 14:25:37 +02:00
Jellyfrog
b706211b77
Docs: Add instructions for PHP 8.1 and Ubuntu 22.04 (#14166) 2022-08-04 17:58:03 -05:00
Zane C. Bowers-Hadley
0bbcde1227
add the ability for storing app data to prevent spamming of the event log via via component usage (#14087)
* initial work on add the ability to save/fetch app data

* update to use get_app_data for ZFS

* update the poller for the new app_data stuff

* ZFS now logs changes to pools

* add schema update for app_data stuff

* small formatting fix

* add a missing \

* now adds a column

* sql-schema is no longer used, so remove the file that was added here

* misc cleanups

* rename the method in database/migrations/2022_07_03_1947_add_app_data.php

* hopefully fix the migration bit

* add the column to misc/db_schema.yaml

* more misc small DB fixes

* update the test as the json column uses collat of utf8mb4_bin

* revert the last change and try manually setting it to what is expected

* remove a extra ;

* update suricata as well

* correct the instance -> instances in one location to prevent the old instance list from being stomped

* remove a extra ;

* update fail2ban to use it as well

* remove two unused functions as suricata and fail2ban no longer use components

* style cleanup

* postgres poller updated to use it

* update html side of the postgres bits

* chronyd now uses app data bits now as well

* portactivity now uses it as well

* style fix

* sort the returned arrays from app_data

* correct log message for port activity

* collocation change

* try re-ordering it

* add in the new data column to the tests

* remove a extra ,

* hmm... ->collate('utf8mb4_unicode_ci') is not usable as apparently collate does not exist

* change the column type from json to longtext

* mv chronyd stuff while I sort out the rest of the tests... damn thing is always buggy

* hmm... fix a missing line then likely move stuff back

* style fix

* add fillable

* add the expexcted data for fail2ban json

* escape a " I missed

* add data for portactivity

* add suricata app data

* add app data to zfs legacy test

* put the moved tests back into place and update zfs-v1 test

* add app data for chronyd test

* add app data for fail2ban legacy test

* update zfs v1 app data

* add some notes on application dev work

* add Developing/Application-Notes.md to mkdocs.yml

* add data column to it

* added various suggestions from bennet-esyoil

* convert from isset to sizeof

* type fix

* fully remove the old save app data function and move it into a helper function... the other still needs cleaned up prior to removal

* update docs

* get_app_data is fully removed now as well

* a few style fixes

* add $casts

* update chronyd test

* attempt to fix the data

* more doc cleanup and try changing the cast

* style fix

* revert the changes to the chronyd test

* apply a few of murrant's suggestions

* document working with ->data as json and non-josn

* remove two no-longer used in this PR exceptions

* ->data now operates transparently

* style fix

* update data tests

* fix json

* test fix

* update the app notes to reflect how app data now works

* app test fix

* app data fix for linux_lsi

* json fix

* minor doc cleanup

* remove duplicate querty and use json_decode instead

* style fix

* modelize the app poller

* use a anon func instead of foreach

* test update

* style cleanup

* style cleanup

* another test cleanup

* more test cleanup

* reverse the test changes and add in some more glue code

* revert one of the test changes

* another small test fix

* Make things use models
Left some array access, but those will still work just fine.

* missed chronyd and portactivity

* rename poll to avoid make it any confusion

* Remove extra save and fix timestamp

* save any changes made to app->data

* nope, that was not it

* What are magic methods and how do they work?

* fix two typos

* update linux_lsi test

* change quote type

Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-07-22 16:01:55 -05:00
Santiago Z
72aa258c43
DOCS, switch to dark or light mode (#13953) 2022-04-26 09:35:02 +02:00
Jellyfrog
09929bd686
Implement OAuth and SAML2 support (#13764)
* Implement OAuth and SAML2 support via Socialite

* Add socialite docs

* fixes

* Additional information added

* wip

* 22.3.0 targeted version

* Allow mysql auth as long as there is a password saved

Co-authored-by: laf <gh+n@laf.io>
Co-authored-by: Tony Murray <murraytony@gmail.com>
2022-02-20 22:05:51 +01:00
Jellyfrog
8f474dd4d4
Rework documentation (#13709)
* Rework documentation

* Slightly adjust theme

* wip

* fixes

* Remove unneeded header

* Re-added Acknowledgement.md file

* Added Acknowledgement.md to mkdocs.yml

Co-authored-by: Neil Lathwood <gh+n@laf.io>
2022-02-08 23:02:28 +00:00
Peca Nesovanovic
08dd8a07db
Mikrotik vlans discovery, v2 (#13427)
* Mikrotik vlans discovery, v2

* styleci cleanup

* added Routeros entry in mkdocs.yml

* fixed typo in mkdocs.yml

* Better Vlan Eloquent Model

* Missed one

* Use new SnmpQuery code

Co-authored-by: Tony Murray <murraytony@gmail.com>
2021-10-26 18:31:44 -05:00
Tony Murray
1ec694595e
Docs link to webui settings in user's install (#13176)
* Docs link to webui settings in user's install

* Add note to re-assure users
2021-08-27 06:48:17 -05:00
djamp42
a7cb75ba2d
Support multiple db servers (#12963)
* add multiple db servers

* formating fixes

* add documentation, mysql_cluster

* add laravel db sticky

* fix formating

* fix space

* updated docs

* Fix whitespace

Co-authored-by: Tony Murray <murraytony@gmail.com>
2021-07-14 10:24:18 -05:00
SourceDoctor
4b9e480118
Define Port Groups (#12402)
* Define Port Groups

* .

* .

* .

* API Calls

* .

* .

* .

* minor changes

* .

* update forms

* remove link

* .

* change column settings

* change migration

* change update position

* db migration fix

* .

* .

* .

* add missing doc reference

* update test data

* update test data

* update test data

* .

* .

* .

* .

* .

* .

* .

* .

* port group association in seperate table

* .

* .

* show all found groups on port

* select multiple Portgroups per Port

* change on migration file

* change query to eloquent

* Code changes

* move port group menu to ports main menu

* port group update to eloquent

* .

* .

* update to new setting way

* add missing merge parameter

* Use select2 and port some things to Laravel
some fixes, hopefully no new added bugs

* schema

* don't use on update restrict unfortunately

* remove unused import and revert changes

Co-authored-by: Tony Murray <murraytony@gmail.com>
2021-04-06 17:25:08 -05:00
Jellyfrog
c97e49db3b
Fix doc building (#12711)
And upgrade
2021-04-06 19:22:58 +02:00
Hans Erasmus
0a7586b9ff
Fix php min version (#12372) 2020-12-01 08:45:53 +01:00
CrazyMax
a0062aa633
Remove hardcoded URLs to doc (#12364)
Co-authored-by: CrazyMax <crazy-max@users.noreply.github.com>
2020-11-27 23:34:58 +01:00
CrazyMax
d8c617d2ae
GitHub Actions for doc (#12353)
Co-authored-by: CrazyMax <crazy-max@users.noreply.github.com>
2020-11-25 22:18:02 +00:00
Jellyfrog
bd81f76caa
Use variable for PHP min version in docs (#12256)
* Use variable for PHP min version in docs

* Bump mkdocs deps
2020-10-24 11:19:45 +02:00
Jellyfrog
782db09bd4
Add docs for Supermicro Superdoctor (#12200) 2020-10-08 12:55:06 +02:00
Tony Murray
d66751c192
Revert "Ignore changelog in docs search (#12194)" (#12199)
This reverts commit 2832230c1c.
2020-10-06 07:40:35 -05:00
Jellyfrog
2832230c1c
Ignore changelog in docs search (#12194) 2020-10-06 02:20:51 +02:00
Tony Murray
551e95a2e0
Docs: don't index changelogs (#12166)
* Docs: don't index changelogs

* Exclude 2019 changelog
2020-09-30 10:11:32 +02:00
Jellyfrog
a06bf05192
Rewrite the docs for OS discovery (#12047)
To reflect it's now part of discovery instead of polling
2020-09-02 15:18:08 +02:00
Jellyfrog
2a795c069b
Rewrite the test data capture section (#12046) 2020-09-01 13:00:44 +02:00
Jellyfrog
b54aa09e52 Add Asuswrt-Merlin to mkdocs 2020-08-06 16:02:39 +02:00
Tony Murray
020c5fd7e1
Remove legacy code and fix missing device graphs (#11950)
* removing $graphs global

* remove unused things

* fix some additional graphs

* Fix graphs persisting too soon

* correct name for poller module performance graph

* only one type of graph is used here
2020-07-23 09:57:22 -05:00
Tony Murray
290398bd9b
Fix missing doc OpenWRT (#11924) 2020-07-10 08:35:17 -05:00
Tony Murray
71d5d29dbb Automatically change all tabs in install docs
Reduced the likelihood of a user viewing info for the wrong os.
2020-06-29 16:17:07 -05:00
Tony Murray
db5524dc09
Merge pull request #11762 from murrant/consolidate-install-doc
Update and Consolidate Install docs Ubuntu 20.04 and CentOS 8
2020-06-29 01:10:28 -05:00
SourceDoctor
63c74bf3e0
Bare Dashoboard Option (#11818)
* Bare Dashoboard Option

* .

* set highlight
2020-06-13 11:56:03 +02:00
Tony Murray
841203c8c5 Consolidated doc (Ubuntu 20.04 Nginx tested) 2020-05-31 21:45:39 -05:00
Nicolas Simond
cd9e5327bd
Updated summary to add new doc (#11482)
Updated summary to add installation doc for Debian 10 (Nginx): Installation/Installation-Debian-10-Nginx.md
2020-04-25 16:03:25 +02:00
Jellyfrog
f8c43ee90f
Correct docs menu name (#11207) 2020-02-26 14:38:21 -06:00
Mathieu Poussin
baf2f9a4ce
BGP API: Add filter by remote ASN (#11204)
* BGP API: Add filter by remote ASN

* Fix blocked merge
2020-02-26 14:29:44 +01:00
Tony Murray
1c48da68e3 Fix documentation TOC (#10580) 2019-09-05 14:37:23 +02:00
Tony Murray
604a200891
Python dispatcher service v2 (#10050)
* Refactor LibreNMS service
add ping

* services ported
remote legacy stats collection

* alerting

* implement unique queues

* update discovery queue manager

* remove message

* more cleanup

* Don't shuffle queue

* clean up imports

* don't try to discover ping only devices

* Fix for discovery not running timer

* Update docs a bit and and add some additional config options.
Intentionally undocumented.

* Wait until the device is marked up by the poller before discovering

* Handle loosing connection to db gracefully

* Attempt to release master after 5 db failures

* Sleep to give other nodes a chance to acquire

* Update docs and rename the doc to Dispatcher Service to more accurately reflect its function.

* add local notification
2019-05-20 11:35:47 -05:00
Tony Murray
9ede688d13
Replace legacy menu with new Blade generated one (#10173)
* Remove legacy index php file

* fix routing page missing data

* WIP

* fix $navbar global usage

* remove global use of $locations

* ObjectCache again...

* move vars.inc.php to init.php for legacy ajax

* navbar is more local than I thought before.  Fix it.

* Fix some sensors tables escaping

* restore custom menu functionality, but with blade
and docs

* cleanup

* tidy menu @if checks

* Fix up the rest of the global variables and remove print-menubar.php

* consolidate some counting in the menu

* filter out empty custom port descr types

* Fix up custom port groups

* Fix up apps menu

* Fix services menu when all are ok

* Limit cached data to the user it is for

* Fix style

* A few clean ups

* fix pseudowire bug
2019-05-10 11:02:39 -05:00
Tony Murray
3905423147
fix docs (#9953) 2019-03-13 21:43:54 -05:00
Neil Lathwood
09b2b5f1a1
Update docs for virtual images (#9456) 2018-11-17 14:19:38 +00:00
Neil Lathwood
1ee2e8e0e0
Updated to use new theme for docs site (#9320)
* Updated to use new theme for docs site

* Updated theme location

* Removed librenms.css

* Updated index page + re-added librenms.css

* Use built in theme modification

* flexbox grid, dump bootstrap

* tidy up things

* Added path and updated deploy script + mkdocs config

* Removed db schmea changes

* Updated to install python/pip 3

* Removed pip3 install

* Pip3 install

* Updated deploy-docs

* Updated deploy-docs
2018-10-27 23:04:34 +01:00
Neil Lathwood
86d862fb25
Added support for allowing alerts to un-ack (#9136)
* Add support for allowing alerts to un-ack

* Updated db_schema.yaml

* Update and rename 263.sql to 265.sql

* Fix up ui a bit.

* Renamed sql file
2018-09-19 23:38:01 +01:00
Tony Murray
79333c45f6
Allow trusted proxy via APP_TRUSTED_PROXIES (#9196)
* Allow trusted proxy via APP_TRUSTED_PROXIES
Set to '*' by default to emulate legacy behavior.
Set up doc describing environment variables

* Create helper to parse environment variables into arrays properly.

* Update doc blocks
2018-09-13 07:26:42 -05:00
bfarmerjr
de2f3028da Create Installation-Ubuntu-1804-Nginx.md (#8630)
* Create Installation-Ubuntu-1804-Nginx.md

A few tweaks are required to the Ubuntu 16.04 instructions to install on the newly released 18.04 version mostly relating to php being bumped to 7.2 from 7.0 and no mcrypt module for this php version in the distro repository.

* Create Installation-Ubuntu-1804-Apache.md

Used instructions from 1604 Apache as template and updated to work on Bionic (18.04).

* Update Installation-Ubuntu-1804-Nginx.md

Removed instructions for installing mcrypt module as I confirmed it works without it and it was mentioned it was no longer needed.

* Update Installation-Ubuntu-1804-Apache.md

The 1604 directions had a mixture of vi and vim for editing files. Since this is ubuntu and we want the instructions to be as easy as possible, I updated editor to be nano. I have no personal preference and can make it whatever we prefer, just figured it should be consistent between the two guides.

* Update mkdocs.yml

Added Ubuntu 18.04 instruction pages

* Update Installation-Ubuntu-1804-Apache.md

Corrected to libapache2-mod-php7.2 from libapache2-mod-php7.0

* Updated Ubuntu install docs

* Added missing mbstring + curl packages
2018-08-28 10:30:37 -05:00
Tony Murray
4c6f917d9e Updates to snmptrap handling (#9010)
* Updates to snmptrap handling
fix a bug in findDeviceByIP.  Add more tests for that.
Move handle outside of the Trap class, it doesn't fit.
Add developer docs.

* fix tests copy paste issue.

* Fix findByIp when port may not exist.

* Logging: Output context (and extra) if they exist

* Generic trap event logging and new config setting.
2018-08-14 07:56:16 +01:00
Tony Murray
9bc0c542a5 Allow ping checks to be ran separately from polling (#8821)
Allows ping checks at intervals not tied to the poller.  Pointless if you are not alerting on device status.
I updated the rrdstep.php script to treat ping-perf files separately and made it so it only converts if needed.

Docs here: https://docs.librenms.org/Extensions/Fast-Ping-Check/

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`
2018-07-30 22:58:38 +01:00
vivia11
e1118b628a Added Alert Transports Mapping (#8660)
Hello all,
I guess this is the second version of a more fully fleshed out alert contact mapping feature. The old one was GH-8507

Transports to convert:

  - [x] API
  - [x] Cisco Spark
  - [x] Elasticsearch
  - [x] GitLab
  - [x] Philips Hue
  - [x] Jira
  - [x] Mail
  - [ ] ~~PagerDuty~~ - Requires a callback so leaving for now
  - [x] Nagios
  - [x] IRC
  - [x] Discord
  - [x] Rocket.chat
  - [x] Hipchat
  - [x] Pushover
  - [x] Boxcar
  - [x] Telegram
  - [x] Pushbullet
  - [x] VictorOps
  - [x] OpsGenie
  - [x] Clickatell
  - [x] PlaySMS
  - [x] Canopsis
  - [x] osTicket
  - [x] Microsoft Teams
  - [x] SMSEagle
  - [x] Syslog
  - [x] Slack

The intention is for this feature to have three different levels to it:
1. Alert rule to an alert contact mapping (where the code is at now)
2. Alert rule to an alert group (made up of alert contacts) mapping
3. Alert contact mapping to different transport configurations.

There will be three transport configuration types.
1. Default (the configuration that is held in the configs table)
2. None (no transport configuration - will explain later)
3. Other (a configuration that will be defined in a different able)

Take Mail transport for example. It can either be of a "default" or "other" configuration. The hope is that in the future, users can send mail from different mail servers if they wish.
However, for ciscospark which requires a room ID and an api-token, I've decided that it has no transport configuration. Most likely, every alert contact will contain a different room-id and an api-token - which is why it has the transport config of "none".
For other transports : I am not familiar with them, so hopefully the community can add support for these. I can definitely help!

To add support for each transport will require several things:
- addition to the UI
- addition to forms/alert-contacts.inc.php
- modifications to its object class

Screenshots
![image](https://user-images.githubusercontent.com/28970851/39594533-2092ce9e-4eca-11e8-9c5d-cd002ece1425.png)
![image](https://user-images.githubusercontent.com/28970851/39594544-276e9856-4eca-11e8-80cc-82789ee0b2b2.png)
![image](https://user-images.githubusercontent.com/28970851/39594553-2fdf528c-4eca-11e8-8a40-4f149e767054.png)

I'm not sure if this is the best way to do things, so please let me know if there's a better way to structure the code! Any comments on code/db schema,/UI etc is welcome and encouraged! 

The UI is heavily based on alert rules (front end is not my strong suit). And parts of the code are based on the code that was written for alert rules.

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`
2018-07-21 20:34:59 +01:00
Neil Lathwood
ad6ec7f72a
Refactor alert templates to use Laravel Blade templating engine (#8803)
* Initial start on new templating support

* further updates

* more updates

* More working version

* Last fixes

* Small updates

* modified test to look for dbname.

* Schema update

* Added fix for not being able to disable Philips Hue transport

* Updated sql file

* Updated db_schema

* Set myclabs/deep-copy to be 1.7.x version in composer

* Fixes from murrant

* Forced nikic/php-parser to version 3.1.x in composer

* Updated composer to use custom fork of string-blade-compiler + fixed transport use

* Updated to always use correct template

* Merged legacy and blade templating engines

* Removed template type + fixed test-alert.php

* Added more template placeholders

* Added ability to reference data in templates as $alert->X

* Updated docs for templates

* Updated db_schema.yaml

* Added $alert->builder

* Clarify the use of $alert->builder

* Fixed the use of $alert->transport

* renamed schema file

* Added template validation

* Small update to fix travis issue

* Add Docs text to title bar

* Updated amqp to new of version

* Consistency in alert rule and template title bars
2018-07-14 22:15:43 +01:00
Neil Lathwood
216c554b7f testing: Added test unit for Docs (#8745)
* testing: Added test unit for Docs

* Update mkdocs.yml

* Avoid extra function

* contains -> diff
2018-05-25 23:10:25 -05:00