Files
coolify/app/Models/V5/RevokedAgentToken.php
T
Andras Bacsai 6ae45684f9 feat(v5): add server reconciliation and canvas APIs
Split V5 dashboard behavior into domain controllers and policies,
add agent token rotation/revocation, status reconciliation jobs,
ingress firewall syncing, and canvas connection APIs.

Add migrations for V5 status tracking, server capabilities, resource
connection aliases, and revoked agent tokens.
2026-07-06 17:40:37 +02:00

46 lines
1005 B
PHP

<?php
namespace App\Models\V5;
use Illuminate\Database\Eloquent\Relations\BelongsTo;
/**
* A host-agent JWT that has been revoked (typically on server destroy/re-home).
*
* flux does not yet consult this list (see AgentTokenIssuer::revoke docblock);
* it exists so the Laravel side owns the data and API needed for revocation the
* moment flux gains a revocation check.
*/
class RevokedAgentToken extends V5Model
{
protected bool $hasUuidColumn = false;
protected $table = 'v5_revoked_agent_tokens';
protected $fillable = [
'jti',
'server_id',
'revoked_at',
'expires_at',
];
/**
* @return array<string, string>
*/
protected function casts(): array
{
return [
'revoked_at' => 'datetime',
'expires_at' => 'datetime',
];
}
/**
* @return BelongsTo<Server, $this>
*/
public function server(): BelongsTo
{
return $this->belongsTo(Server::class);
}
}