mirror of
https://codeberg.org/PostERG/xamxam.git
synced 2026-05-07 03:29:19 +02:00
rename posterg → xamxam throughout: nginx conf, scripts, PHP source, docs
This commit is contained in:
@@ -18,7 +18,7 @@ class LiveReloadController {
|
||||
$appRoot . '/config',
|
||||
$appRoot . '/templates',
|
||||
];
|
||||
$this->stateFile = sys_get_temp_dir() . '/posterg-live-reload.txt';
|
||||
$this->stateFile = sys_get_temp_dir() . '/xamxam-live-reload.txt';
|
||||
}
|
||||
|
||||
public function handle(): array {
|
||||
|
||||
@@ -29,7 +29,7 @@ class MediaController
|
||||
}
|
||||
|
||||
// 2. Resolve path + storage jail
|
||||
$storageRoot = defined('STORAGE_ROOT') ? STORAGE_ROOT : '/var/www/posterg/storage';
|
||||
$storageRoot = defined('STORAGE_ROOT') ? STORAGE_ROOT : '/var/www/xamxam/storage';
|
||||
$fullPath = $storageRoot . '/' . $requestedPath;
|
||||
|
||||
$realStorage = realpath($storageRoot);
|
||||
|
||||
@@ -23,17 +23,17 @@ class SystemController
|
||||
// ── Constants ─────────────────────────────────────────────────────────────
|
||||
|
||||
public const LOG_FILES = [
|
||||
'nginx_access' => ['label' => 'nginx — accès', 'path' => '/var/log/nginx/posterg_access.log'],
|
||||
'nginx_error' => ['label' => 'nginx — erreurs', 'path' => '/var/log/nginx/posterg_error.log'],
|
||||
'nginx_access' => ['label' => 'nginx — accès', 'path' => '/var/log/nginx/xamxam_access.log'],
|
||||
'nginx_error' => ['label' => 'nginx — erreurs', 'path' => '/var/log/nginx/xamxam_error.log'],
|
||||
'php_error' => ['label' => 'PHP-FPM — erreurs', 'path' => '/var/log/php8.4-fpm.log'],
|
||||
];
|
||||
|
||||
public const ALLOWED_LINES = [50, 100, 200, 500];
|
||||
|
||||
/** Live deployed nginx config path. */
|
||||
public const NGINX_CONFIG_LIVE = '/etc/nginx/sites-available/posterg';
|
||||
public const NGINX_CONFIG_LIVE = '/etc/nginx/sites-available/xamxam';
|
||||
/** Local reference copy used as fallback in dev. */
|
||||
public const NGINX_CONFIG_LOCAL = APP_ROOT . '/nginx/posterg.conf';
|
||||
public const NGINX_CONFIG_LOCAL = APP_ROOT . '/nginx/xamxam.conf';
|
||||
|
||||
// ── TTLs ──────────────────────────────────────────────────────────────────
|
||||
private const TTL_STATUS = 120; // 2 minutes
|
||||
|
||||
@@ -35,7 +35,7 @@ class Database {
|
||||
|
||||
/**
|
||||
* Determine database path.
|
||||
* Priority: explicit override → APP_ROOT /storage/posterg.db.
|
||||
* Priority: explicit override → APP_ROOT /storage/xamxam.db.
|
||||
* APP_ROOT is defined by bootstrap.php before any controller loads Database.
|
||||
*/
|
||||
private function determineDatabasePath($customPath = null): string {
|
||||
@@ -44,7 +44,7 @@ class Database {
|
||||
}
|
||||
|
||||
$root = defined('APP_ROOT') ? APP_ROOT : __DIR__ . '/..';
|
||||
return $root . '/storage/posterg.db';
|
||||
return $root . '/storage/xamxam.db';
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -118,7 +118,7 @@ class SmtpRelay {
|
||||
}
|
||||
|
||||
// Build MIME message
|
||||
$boundary = 'posterg_' . bin2hex(random_bytes(8));
|
||||
$boundary = 'xamxam_' . bin2hex(random_bytes(8));
|
||||
$date = date('r');
|
||||
$fromHdr = ($s['from_name'] ?? '') !== ''
|
||||
? "=?UTF-8?B?" . base64_encode($s['from_name']) . "?= <{$s['from_email']}>"
|
||||
|
||||
Reference in New Issue
Block a user