mirror of https://github.com/LX3JL/xlxd.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
1.4 KiB
40 lines
1.4 KiB
<?php
|
|
/**
|
|
* ysfpeers.php — YSF Peers page (dashboard2)
|
|
*
|
|
* Displays connected YSF gateways parsed from the co-located YSF reflector's
|
|
* systemd journal. The journal parser is shared with dashboard1; the renderer
|
|
* is dashboard2-specific (Bootstrap table classes, SafeOutput helpers).
|
|
*
|
|
* Enabled via $PageOptions['YSFPeerPage']['Show'] = true in config.inc.php.
|
|
* IP display and masquerade settings are inherited from RepeatersPage config.
|
|
*/
|
|
|
|
if (empty($PageOptions['YSFPeerPage']['Show'])) {
|
|
if (!empty($PageOptions['YSFPeerPage']['NoLocalPeer'])) {
|
|
echo '<p class="text-muted">No local YSF peer (127.0.0.1) in xlxd.interlink, this page only works with a YSF reflector on this host.</p>';
|
|
} else {
|
|
echo '<p class="text-muted">This page is not enabled.</p>';
|
|
}
|
|
return;
|
|
}
|
|
|
|
require_once('./pgs/parse_journal_peers.php');
|
|
|
|
// Re-use pre-parsed data from index.php when available (avoids a second
|
|
// journalctl call on pages that also need the count in the nav menu)
|
|
if (!isset($YSFPeers) || !is_array($YSFPeers)) {
|
|
$YSFPeers = ParseJournalPeers($PageOptions['YSFPeerPage']);
|
|
}
|
|
|
|
$__peers = $YSFPeers;
|
|
$__peerLabel = 'YSF Gateway';
|
|
$__pageSlug = 'ysfpeers';
|
|
$ipModus = $PageOptions['RepeatersPage']['IPModus'];
|
|
$maskChar = $PageOptions['RepeatersPage']['MasqueradeCharacter'];
|
|
|
|
$Reflector->LoadFlags();
|
|
|
|
require('./pgs/render_journal_peers.php');
|
|
?>
|