mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Merge remote-tracking branch 'upstream/master' into psr2-html
This commit is contained in:
+23
-6
@@ -3,17 +3,30 @@ matrix:
|
||||
fast_finish: true
|
||||
include:
|
||||
- php: 7.0
|
||||
env: PHP_L=1
|
||||
env:
|
||||
PHP_L=1
|
||||
EXECUTE_BUILD_DOCS=false
|
||||
- php: 5.3
|
||||
env: PHP_L_OLD=1
|
||||
env:
|
||||
PHP_L_OLD=1
|
||||
EXECUTE_BUILD_DOCS=false
|
||||
- php: 5.4
|
||||
env: PHP_L_OLD=1
|
||||
env:
|
||||
PHP_L_OLD=1
|
||||
EXECUTE_BUILD_DOCS=false
|
||||
- php: 5.5
|
||||
env: PHP_L=1
|
||||
env:
|
||||
PHP_L=1
|
||||
EXECUTE_BUILD_DOCS=false
|
||||
- php: 5.6
|
||||
env: PHP_L=1 PHPCS=1
|
||||
env:
|
||||
PHP_L=1
|
||||
PHPCS=1
|
||||
EXECUTE_BUILD_DOCS=true
|
||||
- php: hhvm
|
||||
env: PHP_L_OLD=1
|
||||
env:
|
||||
PHP_L_OLD=1
|
||||
EXECUTE_BUILD_DOCS=false
|
||||
|
||||
allow_failures:
|
||||
- php: 7.0
|
||||
@@ -27,7 +40,11 @@ cache:
|
||||
before_script:
|
||||
- composer install --prefer-dist --no-interaction
|
||||
|
||||
after_success:
|
||||
- test $TRAVIS_PULL_REQUEST == "false" && test $TRAVIS_BRANCH == "master" && test $EXECUTE_BUILD_DOCS == "true" && bash scripts/deploy-docs.sh
|
||||
|
||||
script:
|
||||
- if [[ $PHP_L == 1 ]]; then find . -path './vendor' -prune -o -name "*.php" -print0 | xargs -0 -n1 -P8 php -l | grep -v '^No syntax errors detected' ; test $? -eq 1; fi
|
||||
- if [[ $PHP_L_OLD == 1 ]]; then find . -regextype posix-extended -regex "\./(lib/influxdb-php|vendor)" -prune -o -name "*.php" -print0 | xargs -0 -n1 -P8 php -l | grep -v '^No syntax errors detected' ; test $? -eq 1; fi
|
||||
- if [[ $PHP_CS == 1 ]]; then vendor/bin/phpcs -n -p --colors --extensions=php --standard=PSR2 --ignore=html/lib/* .; fi
|
||||
- phpunit
|
||||
|
||||
@@ -119,6 +119,7 @@ LibreNMS contributors:
|
||||
- Vladislav Solovei <vladsol2009@gmail.com> (vladsol)
|
||||
- Daniel van Dorp <daniel@vandorp.biz> (djvdorp)
|
||||
- Phil Regnauld <regnauld@x0.dk> (reegnauld)
|
||||
- Bennett Blodinger <bennett.blodinger@gmail.com> (benwa)
|
||||
|
||||
[1]: http://observium.org/ "Observium web site"
|
||||
Observium was written by:
|
||||
|
||||
@@ -107,5 +107,5 @@ Disk I/O can be found under the menu Devices>All Devices>[localhost hostname]>He
|
||||
Depending on many factors, you should see the Ops/sec drop by ~30-40%.
|
||||
|
||||
|
||||
[1]: http://librenms.readthedocs.org/Installation/Installation-(RHEL-CentOS)/#add-localhost
|
||||
[1]: http://librenms.readthedocs.org/Installation/Installation-CentOS-7-Apache/
|
||||
"Add localhost to LibreNMS"
|
||||
|
||||
@@ -51,7 +51,7 @@ You should now see a new tab in your device page called ping.
|
||||
|
||||
### Install and integrate Smokeping [Debian/Ubuntu] ###
|
||||
|
||||
> This guide assumes you have already <a href="http://docs.librenms.org/Installation/Installation-(Debian-Ubuntu)/">installed librenms</a>, and you installed apache2 in the process. Tested with Ubuntu 14.04 and Apache 2.4.
|
||||
> This guide assumes you have already <a href="http://docs.librenms.org/Installation/Installing-LibreNMS/">installed librenms</a>, and you installed apache2 in the process. Tested with Ubuntu 14.04 and Apache 2.4.
|
||||
|
||||
Nearly everything we do will require root, and at one point we'll encounter a problem if we just use sudo, so we'll just switch to root at the beginning...
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ Varnish is caching software that sits logically between an HTTP client and an HT
|
||||
|
||||
In this example we will assume your Apache 2.4.X HTTP server is working and
|
||||
configured to process HTTP requests on port 80. If not, please see
|
||||
[Using HTTPd Apache2](http://librenms.readthedocs.org/Installation/Installation-(RHEL-CentOS)/#using-httpd-apache2)
|
||||
[Installing LibreNMS](http://librenms.readthedocs.org/Installation/Installing-CentOS-7-Apache)
|
||||
|
||||
|
||||
#### Install Varnish 4.0 RPM ####
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
NOTE: What follows is a very rough list of commands. This works on a fresh install of CentOS 6.4 and CentOS 7.
|
||||
NOTE: What follows is a very rough list of commands. This works on a fresh install of CentOS 6.x.
|
||||
|
||||
NOTE: These instructions assume you are the root user. If you are not, prepend `sudo` to all shell commands (the ones that aren't at `mysql>` prompts) or temporarily become a user with root privileges with `sudo -s`.
|
||||
|
||||
@@ -20,10 +20,10 @@ If you want to install yourself then we have some new documentation which should
|
||||
|
||||
If the above are missing or incomplete then you can try our old docs below.
|
||||
|
||||
[Debian/Ubuntu](http://docs.librenms.org/Installation/Installation-(Debian-Ubuntu)/)
|
||||
[Debian/Ubuntu](http://docs.librenms.org/Installation/Installation-Ubuntu-1404-Apache/)
|
||||
|
||||
[RHEL/CentOS](http://docs.librenms.org/Installation/Installation-(RHEL-CentOS)/
|
||||
[RHEL/CentOS](http://docs.librenms.org/Installation/Installation-CentOS-6-Apache-Nginx/
|
||||
|
||||
[Debian/Ubuntu Lighttpd](http://docs.librenms.org/Installation/Installation-Lighttpd-(Debian-Ubuntu)/)
|
||||
[Debian/Ubuntu Lighttpd](http://docs.librenms.org/Installation/Installation-Ubuntu-1404-Lighttpd/)
|
||||
|
||||
[Debian/Ubuntu Nginx](http://docs.librenms.org/Installation/Installation-Nginx-(Debian-Ubuntu)/)
|
||||
[Debian/Ubuntu Nginx](http://docs.librenms.org/Installation/Installation-Ubuntu-1404-Nginx/)
|
||||
|
||||
+14
-1
@@ -1 +1,14 @@
|
||||
# Welcome to the documentation for [LibreNMS](https://github.com/librenms/librenms)
|
||||
### Welcome to the LibreNMS docs
|
||||
|
||||
Some of these docs are work in progress or may be missing configuration examples for varying distros.
|
||||
If you find this is the case then please feel free to edit them on [GitHub](https://github.com/librenms/librenms/tree/master/doc)
|
||||
and submit a pull request.
|
||||
|
||||
The docs should provide you with information on various elements to the software:
|
||||
|
||||
- Installation
|
||||
- Support / FAQ
|
||||
- Developing for LibreNMS
|
||||
- Available extensions
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
body {
|
||||
background-image:none !important;
|
||||
}
|
||||
|
||||
.dropdown-menu {
|
||||
max-height: 400px !important;
|
||||
overflow-x: hidden !important;
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ $temp_output = '
|
||||
<div class="panel panel-default panel-condensed table-responsive">
|
||||
<table class="table table-hover table-condensed table-striped">
|
||||
<thead>
|
||||
<tr class="info">
|
||||
<tr>
|
||||
<th> </th>
|
||||
<th><span class="grey">Total</span></th>
|
||||
<th><span class="green">Up</span></th>
|
||||
@@ -16,7 +16,7 @@ $temp_output = '
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<td><a href="devices/">Devices</a></td>
|
||||
<td><a href="devices/"><span>'.$devices['count'].'</span></a></td>
|
||||
<td><a href="devices/state=up/format=list_detail/"><span class="green"> '.$devices['up'].'</span></a></td>
|
||||
@@ -25,7 +25,7 @@ $temp_output = '
|
||||
<td><a href="devices/disabled=1/format=list_detail/"><span class="black"> '.$devices['disabled'].'</span></a></td>
|
||||
'.($config['summary_errors'] ? '<td>-</td>' : '').'
|
||||
</tr>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<td><a href="ports/">Ports</a></td>
|
||||
<td><a href="ports/"><span>'.$ports['count'].'</span></a></td>
|
||||
<td><a href="ports/format=list_detail/state=up/"><span class="green"> '.$ports['up'].'</span></a></td>
|
||||
@@ -36,7 +36,7 @@ $temp_output = '
|
||||
</tr>';
|
||||
if ($config['show_services']) {
|
||||
$temp_output .= '
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<td><a href="services/">Services</a></td>
|
||||
<td><a href="services/"><span>'.$services['count'].'</span></a></td>
|
||||
<td><a href="services/state=ok/view=details/"><span class="green">'.$services['up'].'</span></a></td>
|
||||
|
||||
@@ -5,7 +5,7 @@ $temp_output = '
|
||||
<div class="panel panel-default panel-condensed table-responsive">
|
||||
<table class="table table-hover table-condensed table-striped">
|
||||
<thead>
|
||||
<tr class="info">
|
||||
<tr>
|
||||
<th>Summary</th>
|
||||
<th><a href="devices/">Devices</a></th>
|
||||
<th><a href="ports/">Ports</a></th>
|
||||
@@ -21,7 +21,7 @@ $temp_output .= '
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<th><span class="green">Up</span></th>
|
||||
<td><a href="devices/format=list_detail/state=up/"><span class="green">'. $devices['up'] .'</span></a></td>
|
||||
<td><a href="ports/format=list_detail/state=up/"><span class="green">'. $ports['up'] .'</span></a></td>
|
||||
@@ -34,7 +34,7 @@ if ($config['show_services']) {
|
||||
|
||||
$temp_output .= '
|
||||
</tr>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<th><span class="red">Down</span></th>
|
||||
<td><a href="devices/format=list_detail/state=down/"><span class="red">'. $devices['down'] .'</span></a></td>
|
||||
<td><a href="ports/format=list_detail/state=down/"><span class="red">'. $ports['down'] .'</span></a></td>
|
||||
@@ -48,7 +48,7 @@ if ($config['show_services']) {
|
||||
|
||||
$temp_output .= '
|
||||
</tr>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<th><span class="grey">Ignored</span></th>
|
||||
<td><a href="devices/format=list_detail/ignore=1/"><span class="grey">'. $devices['ignored'] .'</span></a></td>
|
||||
<td><a href="ports/format=list_detail/ignore=1/"><span class="grey">'. $ports['ignored'] .'</span></a></td>
|
||||
@@ -62,7 +62,7 @@ if ($config['show_services']) {
|
||||
|
||||
$temp_output .= '
|
||||
</tr>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<th><span class="black">Disabled/Shutdown</span></th>
|
||||
<td><a href="devices/format=list_detail/disabled=1/"><span class="black">'. $devices['disabled'] .'</span></a></td>
|
||||
<td><a href="ports/format=list_detail/state=admindown/"><span class="black">'. $ports['shutdown'] .'</span></a></td>
|
||||
@@ -77,7 +77,7 @@ if ($config['show_services']) {
|
||||
if ($config['summary_errors']) {
|
||||
$temp_output .= '
|
||||
</tr>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<th><span class="black">Errored</span></th>
|
||||
<td>-</td>
|
||||
<td><a href="ports/format=list_detail/errors=1/"><span class="black"> '.$ports['errored'].'</span></a></td>
|
||||
@@ -91,7 +91,7 @@ if ($config['summary_errors']) {
|
||||
|
||||
$temp_output .= '
|
||||
</tr>
|
||||
<tr class="active">
|
||||
<tr>
|
||||
<th><span class="grey">Total</span></th>
|
||||
<td><a href="devices/"><span>'. $devices['count'] .'</span></a></td>
|
||||
<td><a href="ports/"><span>'. $ports['count'] .'</span></a></td>
|
||||
|
||||
@@ -153,7 +153,7 @@ function rrdtool($command, $filename, $options, $timeout = 0)
|
||||
global $config, $debug, $vdebug, $rrd_pipes;
|
||||
|
||||
// do not ovewrite files when creating
|
||||
if ($command == 'create') {
|
||||
if ($command == 'create' && version_compare($config['rrdtool_version'], '1.4.3', '>=')) {
|
||||
$options .= ' -O';
|
||||
}
|
||||
// rrdcached commands: >=1.5.5: all, >=1.5 all: except tune, <1.5: all except tune and create
|
||||
@@ -180,8 +180,8 @@ function rrdtool($command, $filename, $options, $timeout = 0)
|
||||
) {
|
||||
c_echo("[%rRRD Disabled%n]\n");
|
||||
$output = array(null, null);
|
||||
} elseif ($command == 'create' && version_compare($config['rrdtool_version'], '1.5', '<') && is_file($filename)) {
|
||||
// do not overwrite RRD if it already exists and RRDTool ver. < 1.5
|
||||
} elseif ($command == 'create' && version_compare($config['rrdtool_version'], '1.4.3', '<') && is_file($filename)) {
|
||||
// do not overwrite RRD if it already exists and RRDTool ver. < 1.4.3
|
||||
c_echo("RRD[%g$filename already exists%n]\n", $debug);
|
||||
$output = array(null, null);
|
||||
} else {
|
||||
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
site_name: LibreNMS Documentation
|
||||
theme: mkdocs
|
||||
docs_dir: doc
|
||||
site_dir: out
|
||||
site_url: http://docs.librenms.org
|
||||
markdown_extensions:
|
||||
- pymdownx.superfences
|
||||
extra_css:
|
||||
- librenms.css
|
||||
include_next_prev: false
|
||||
site_author: LibreNMS
|
||||
site_description: LibreNMS user and developer documentation
|
||||
repo_url: https://github.com/librenms/librenms
|
||||
repo_name: GitHub
|
||||
@@ -0,0 +1,28 @@
|
||||
#!/bin/bash
|
||||
GH_REPO="@github.com/librenms-docs/librenms-docs.github.io.git"
|
||||
FULL_REPO="https://${GH_TOKEN}$GH_REPO"
|
||||
|
||||
pip install --user mkdocs
|
||||
pip install --user pymdown-extensions
|
||||
|
||||
mkdir -p out
|
||||
|
||||
cd out
|
||||
|
||||
git init
|
||||
git remote add origin $FULL_REPO
|
||||
git fetch
|
||||
git config user.name "librenms-docs"
|
||||
git config user.email "[email protected]"
|
||||
git checkout master
|
||||
|
||||
cd ../
|
||||
|
||||
mkdocs build --clean
|
||||
|
||||
cd out
|
||||
|
||||
touch .
|
||||
git add -A .
|
||||
git commit -m "GH-Pages update by travis after $TRAVIS_COMMIT"
|
||||
git push -q origin master
|
||||
Reference in New Issue
Block a user