/usr/share/icingaweb2/modules/monitoring/application/views/scripts/show/components/command.phtml is in icingaweb2-module-monitoring 2.1.0-1ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | <?php
$parts = explode('!', $object->check_command);
$command = array_shift($parts);
if ($showInstance): ?>
<tr>
<th><?= $this->translate('Instance') ?></th>
<td><?= $this->escape($object->instance_name) ?></td>
</tr>
<?php endif ?>
<tr>
<th><?= $this->translate('Command') ?></th>
<td>
<?= $this->escape($command) ?>
<?php if ($this->hasPermission('monitoring/command/schedule-check') && $object->passive_checks_enabled) {
$title = sprintf(
$this->translate('Submit a one time or so called passive result for the %s check'), $command
);
if ($object->getType() === $object::TYPE_HOST) {
echo $this->qlink(
$this->translate('Process check result'),
'monitoring/host/process-check-result',
array('host' => $object->getName()),
array(
'class' => 'action-link',
'data-base-target' => '_self',
'icon' => 'reply',
'title' => $title
)
);
} else {
echo $this->qlink(
$this->translate('Process check result'),
'monitoring/service/process-check-result',
array('host' => $object->getHost()->getName(), 'service' => $object->getName()),
array(
'class' => 'action-link',
'data-base-target' => '_self',
'icon' => 'reply',
'title' => $title
)
);
}
} ?>
</td>
</tr>
<?php
$row = "<tr>\n <th>%s</th>\n <td>%s</td>\n</tr>\n";
for ($i = 0; $i < count($parts); $i++) {
printf($row, '$ARG' . ($i + 1) . '$', $this->escape($parts[$i]));
}
|