pterodactyl.ts
    Preparing search index...

    Class PanelServer

    Implements

    • ServerAttributes
    Index

    Constructors

    Properties

    allocation: number
    allocations?: NodeAllocation[]
    associatedEgg?: Egg
    associatedNest?: Nest
    associatedNode?: PanelNode
    container: {
        environment: { [key: string]: string | number | boolean | null };
        image: string;
        installed: 0 | 1;
        startup_command: string;
    }
    created_at: Date
    databases?: ServerDatabase[]
    description: string
    egg: number
    eggData?: RawPanelEgg
    external_id?: string | null
    feature_limits: { allocations: number; backups: number; databases: number }
    id: number
    identifier: string
    limits: {
        cpu: number;
        disk: number;
        io: number;
        memory: number;
        oom_disabled: boolean;
        swap: number;
        threads: string | null;
    }
    location?: PanelLocation
    name: string
    nest: number
    node: number
    owner?: PanelUser
    status: ServerStatus
    subusers?: ServerSubUser[]
    suspended: boolean
    updated_at: Date
    user: number
    uuid: string
    variables?: ServerVariable[]

    Methods

    • Add environment vars with which the server will start

      Parameters

      • key: string
      • value: string

      Returns Promise<void>

    • Set the new allocation limit

      Parameters

      • limit: number

        How many allocations can be created for this server

      Returns Promise<void>

    • Set the new backup limit

      Parameters

      • limit: number

        How many backups can be created for this server

      Returns Promise<void>

    • Parameters

      • limit: number

        The new cpu limit in %

      Returns Promise<void>

    • Set which cores can be used by a server Example: 0; 1-3; 4,5,6;

      Parameters

      • pinning: string | (string | number)[]

      Returns Promise<void>

    • Set the custom docker image for this server

      Parameters

      • image: string

        The new image for this container

      Returns Promise<void>

    • Set the new database limit

      Parameters

      • limit: number

        How many databases can be created for this server

      Returns Promise<void>

    • Set the description for this server

      Parameters

      • description: string

        The new description for this server

      Returns Promise<void>

    • Set the docker image for this server

      Parameters

      • image: string

        The new image for this container

      Returns Promise<void>

    • Set the environment vars with which the server will start

      Parameters

      • environment: { [environment: string]: string }

        Overwrites all current variables

      Returns Promise<void>

    • Set the external id for this server

      Parameters

      • externalId: string

        The new external id for this server

      Returns Promise<void>

    • Set the new nest for this server

      Parameters

      • nest: number | Nest

        The new nest for this server

      • egg: number | Egg

        The new egg for this server

      Returns Promise<void>

    • Enable the OOM killer This will kill the server if it exceeds the memory limit This may cause the server processes to exit unexpectedly This CAN cause to data corruption

      Parameters

      • active: boolean

        Should the oom killer be active

      Returns Promise<void>

    • Skip install script

      Parameters

      • skip: boolean

        Whether the install script should be skipped

      Returns Promise<void>

    • Set the startup command with which the server will start This can include environment vars via {{ VAR_NAME }}

      Parameters

      • startup: string

      Returns Promise<void>

      startup This will use the default startup command if you set the egg via .setEgg(egg: PanelEgg)