Skip to content

CLI site

Nicholas K. Dionysopoulos edited this page Jun 4, 2026 · 1 revision

CLI: Site Management Commands

The site:* namespace is the largest in Panopticon's CLI and covers the full lifecycle of managed sites: adding and removing them, inspecting and updating their configuration, triggering updates and backups on demand, and managing Admin Tools security features remotely.

All commands that accept a site argument expect the numeric site ID. Use site:list to find the ID you need.

site:add

Adds a new site to Panopticon. The URL and API token are the minimum required; all other settings can be supplied now or changed later via site:config:set.

# Minimal — add a Joomla! site with just URL and token
php cli/panopticon.php site:add https://example.com \
    --token "abc123yourtokenhere"

# Full options — WordPress site with update policy, groups, and HTTP auth
php cli/panopticon.php site:add https://wp.example.com \
    --name "WP Example" \
    --token "abc123yourtokenhere" \
    --type wordpress \
    --enabled \
    --groups 3 \
    --groups 7 \
    --update-action minor \
    --update-when time \
    --update-time "03:00" \
    --email-update-error \
    --email-update-success
Option Description
url URL of the site (required positional argument)
--name Display name in Panopticon (defaults to the URL)
-t, --token API token from the connector extension
-y, --type CMS type: joomla (default) or wordpress
-e, --enabled / --no-enabled Enable the site immediately after creation
-g, --groups Numeric group IDs; repeat for multiple groups
--admin_user HTTP Basic Auth username (if the site is password-protected)
--admin_pass HTTP Basic Auth password
--update-action Core update policy: none, email, patch, minor, major
--update-when immediately or time (combined with --update-time)
--update-time 24-hour HH:MM in UTC, e.g. 03:00
--cc-email Extra email addresses to copy on update notifications; repeat for multiple
--email-update-error Send an email when an update fails
--email-update-success Send an email when an update succeeds

Tip: In an Ansible playbook or Terraform provisioner, pass all site details non-interactively and capture the numeric ID from the output for use in subsequent commands.


site:list

Lists all sites registered in Panopticon. The most commonly used command for finding a site's numeric ID before running other commands.

# List all sites
php cli/panopticon.php site:list

# Only enabled sites
php cli/panopticon.php site:list --enabled

# Sites matching a search term (title or URL)
php cli/panopticon.php site:list --search acme

# Sites running a specific Joomla! major version
php cli/panopticon.php site:list --cms-family 5.x

# Sites running a specific PHP major/minor
php cli/panopticon.php site:list --php-family 8.3

# Sites with available core updates
php cli/panopticon.php site:list --core-update

# Sites with available extension updates
php cli/panopticon.php site:list --extension-update

# Machine-readable output for scripting
php cli/panopticon.php site:list --format json

site:enable / site:disable

Enables or disables a site without deleting it. A disabled site is skipped by all automatic tasks — it will not be monitored, updated, or backed up automatically until re-enabled.

php cli/panopticon.php site:enable 42
php cli/panopticon.php site:disable 42

Useful for temporarily suspending monitoring of a site that is undergoing a major migration, without losing its configuration.


site:delete

Permanently removes a site and all associated task schedules and configuration from Panopticon. This does not touch the site itself.

php cli/panopticon.php site:delete 42

Warning: There is no confirmation prompt. Get the ID right with site:list first.


site:info:refresh

Forces a refresh of the cached site information (Joomla!/WordPress version, PHP version, installed extensions, update availability). Normally Panopticon refreshes this on a schedule; use this command to trigger an immediate re-check.

# Refresh all sites
php cli/panopticon.php site:info:refresh

# Force refresh even if the cache is still fresh
php cli/panopticon.php site:info:refresh --force

# Refresh specific sites by ID
php cli/panopticon.php site:info:refresh --id 3 --id 7 --id 12

# Adjust how many sites are contacted concurrently
php cli/panopticon.php site:info:refresh --batchSize 20

Useful after you have manually updated a site or changed its configuration and want Panopticon's dashboard to reflect the new state immediately.


site:extensions:refresh

Same as site:info:refresh but focuses specifically on the installed extensions list. Run this after installing or removing an extension on a site to ensure Panopticon's extension inventory is up to date.

php cli/panopticon.php site:extensions:refresh
php cli/panopticon.php site:extensions:refresh --force
php cli/panopticon.php site:extensions:refresh --id 3 --id 7

site:config:list / site:config:get / site:config:set

Inspect and modify the configuration parameters stored for a specific site. These correspond to the settings you can edit through the site's configuration page in the web interface.

# See all configuration keys for site 3
php cli/panopticon.php site:config:list 3

# JSON output — useful for scripting config audits
php cli/panopticon.php site:config:list 3 --format json

# Read a specific parameter
php cli/panopticon.php site:config:get 3 config.core_update.install

# Change the update action for a specific site
php cli/panopticon.php site:config:set 3 config.core_update.install email

# Change the scheduled update time (UTC, HH:MM)
php cli/panopticon.php site:config:set 3 config.core_update.release_time "02:00"

site:config:list is particularly useful when you need to know the exact key name for a parameter before using site:config:set.


site:update:joomla

Triggers an immediate Joomla! core update on the specified site. Panopticon checks for an available update and applies it; if no update is available, nothing happens (unless --force is used).

# Update site ID 3 if an update is available
php cli/panopticon.php site:update:joomla 3

# Force a files refresh even if there is no update
php cli/panopticon.php site:update:joomla 3 --force

This respects any pre- and post-update plugin events (onBeforeJoomlaUpdate, onAfterJoomlaUpdate), exactly as an automatic scheduled update would. Use it to apply an urgent security update immediately rather than waiting for the next scheduled window.


site:update:extensions

Triggers an immediate update of all pending Joomla! extension updates on the specified site.

php cli/panopticon.php site:update:extensions 3

site:update:wordpress

Triggers an immediate WordPress core update on the specified site.

php cli/panopticon.php site:update:wordpress 3
php cli/panopticon.php site:update:wordpress 3 --force

site:update:plugins

Triggers an immediate update of all pending WordPress plugin and theme updates on the specified site.

php cli/panopticon.php site:update:plugins 3

site:backup

Triggers an immediate Akeeba Backup job on the specified site.

# Back up using the default profile (ID 1)
php cli/panopticon.php site:backup 3

# Back up using a specific Akeeba Backup profile
php cli/panopticon.php site:backup 3 --profile 4

# Add a description to the backup record
php cli/panopticon.php site:backup 3 --profile 4 \
    --description "Pre-update manual backup"

Combine with site:update:joomla in a script to take a safety backup before applying an update:

#!/bin/bash
SITE_ID=3

php cli/panopticon.php site:backup $SITE_ID --description "Pre-update backup" && \
php cli/panopticon.php site:update:joomla $SITE_ID

site:scanner

Triggers an immediate Admin Tools PHP File Change Scanner run on the specified site. Requires Admin Tools Professional to be installed and active on the site.

php cli/panopticon.php site:scanner 3

site:security:enable / site:security:disable

Remotely enables or disables the Admin Tools system plugin on a site. This is useful during incident response: disabling Admin Tools temporarily removes all its security rules (WAF, IP blocking, etc.), which can restore access if a rule is incorrectly blocking your own IP or breaking the site.

php cli/panopticon.php site:security:enable 3
php cli/panopticon.php site:security:disable 3

Always re-enable the plugin as soon as the issue is resolved.


site:security:htaccess:enable / site:security:htaccess:disable

Remotely enables or disables the Admin Tools-generated .htaccess file on an Apache-based site. Like disabling the plugin itself, disabling the .htaccess file can restore access when a security rule in the .htaccess is blocking legitimate requests.

php cli/panopticon.php site:security:htaccess:enable 3
php cli/panopticon.php site:security:htaccess:disable 3

site:security:unblock

Removes an IP address from the Admin Tools blocked IPs list on the specified site. If you omit the IP address, Panopticon automatically unblocks the server's own public IP — the most common case when the Panopticon server has been accidentally blocked.

# Unblock the Panopticon server's own IP
php cli/panopticon.php site:security:unblock 3

# Unblock a specific IP address
php cli/panopticon.php site:security:unblock 3 203.0.113.42

# Unblock multiple addresses at once
php cli/panopticon.php site:security:unblock 3 203.0.113.42 198.51.100.7

This is the fastest way to recover when a site is blocking Panopticon's connection, without needing to log in to the site's administrator backend.


site:notify:certificates

Checks all (or specific) sites for SSL/TLS certificate expiration and sends warning emails to configured recipients. This is what the built-in sslTlsCertificatesAlerts system task does on its automatic schedule; use this command to trigger the check on demand.

# Check all sites
php cli/panopticon.php site:notify:certificates

# Check only specific sites
php cli/panopticon.php site:notify:certificates --id 3 --id 7

# Override the warning threshold (number of days before expiry)
php cli/panopticon.php site:notify:certificates --warnDays 14

# Send emails even if they were already sent for this expiry cycle
php cli/panopticon.php site:notify:certificates --force

site:overrides:list

Lists the template overrides that need review for a specific site. Panopticon tracks these when a Joomla! core or extension update may have changed the original template file that a custom override is based on.

php cli/panopticon.php site:overrides:list 3
php cli/panopticon.php site:overrides:list 3 --format json

site:summary:update

Generates and sends the pending updates summary email for a specific site. Normally triggered automatically as a scheduled task; use this to send it on demand or to test the email template.

# Send with both core and extension updates
php cli/panopticon.php site:summary:update 3

# Send only core update summary
php cli/panopticon.php site:summary:update 3 --core --no-extension

# Send only extension update summary
php cli/panopticon.php site:summary:update 3 --no-core --extension

site:summary:action

Generates and sends the scheduled actions summary email for a specific site, covering actions taken within a given period.

php cli/panopticon.php site:summary:action 3 --period daily
php cli/panopticon.php site:summary:action 3 --period weekly
php cli/panopticon.php site:summary:action 3 --period monthly

site:uptime:monitor

Runs an uptime check pass against all configured sites. This is what the built-in uptime monitoring task does; call it from the CLI to run the check immediately outside the normal schedule.

php cli/panopticon.php site:uptime:monitor

Common workflows

Adding multiple sites from a script

#!/bin/bash
# Provision a list of client sites from environment variables

while IFS=',' read -r name url token group; do
    php cli/panopticon.php site:add "$url" \
        --name "$name" \
        --token "$token" \
        --enabled \
        --groups "$group" \
        --update-action email
done < sites.csv

Checking which sites have pending updates

# Show sites with pending core updates
php cli/panopticon.php site:list --core-update --format json | jq '.[].id'

# Show sites with pending extension updates
php cli/panopticon.php site:list --extension-update --format table

Emergency security lockdown script

If a shared-hosting account is under attack and you need to quickly disable Admin Tools on all sites to diagnose what is causing false-positive blocks:

#!/bin/bash
# Disable Admin Tools on all sites, then re-enable after 5 minutes

for id in $(php cli/panopticon.php site:list --format json | jq '.[].id'); do
    php cli/panopticon.php site:security:disable "$id"
done

echo "Admin Tools disabled on all sites. Re-enabling in 5 minutes..."
sleep 300

for id in $(php cli/panopticon.php site:list --format json | jq '.[].id'); do
    php cli/panopticon.php site:security:enable "$id"
done

Getting Started

Installation

Using Panopticon

Administration

How it works

For Experts

Installation and updates

Customisation

CLI Reference

Reference

JSON API

AI integration

Translation

Miscellaneous

Clone this wiki locally