coollabsio/coolify · error · RuntimeException

Private key material is required.

Error message

Private key material is required.

What it means

Error "Private key material is required." thrown in coollabsio/coolify.

Source

Thrown at app/Services/ServerTransfer/ServerTransferImporter.php:374

                } catch (Throwable $e) {
                    $result['claimed'] = false;
                    $result['claim'] = null;
                    $result['warnings'][] = 'Server imported, but automatic claim failed: '.$e->getMessage();
                }
            }
        }

        return $result;
    }

    /**
     * @param  array<string, mixed>  $payload
     */
    private function importPrivateKey(array $payload, int $teamId, bool $preserveUuids): PrivateKey
    {
        $material = (string) data_get($payload, 'private_key');
        if ($material === '') {
            throw new RuntimeException('Private key material is required.');
        }

        $fingerprint = PrivateKey::generateFingerprint($material)
            ?? data_get($payload, 'fingerprint');

        if ($fingerprint) {
            $existing = PrivateKey::query()->where('fingerprint', $fingerprint)->first();
            if ($existing) {
                if ((int) $existing->team_id !== $teamId) {
                    throw ValidationException::withMessages([
                        'private_key' => ['This SSH private key already exists on another team on this instance.'],
                    ]);
                }

                return $existing;
            }
        }

View on GitHub (pinned to 70b9acc424)

When it happens

Trigger: Thrown at app/Services/ServerTransfer/ServerTransferImporter.php:374 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of coollabsio/coolify@70b9acc424 (2026-08-17). Data as JSON: /api/errors/cc62fad8fb5f374e. Report an issue: GitHub.