PHP code example of jalallinux / php-pm2
1. Go to this page and download the library: Download jalallinux/php-pm2 library . Choose the download type require .
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
jalallinux / php-pm2 example snippets
pm2()->list(string $sortField = 'name', bool $desc = true): array<Process>
pm2()->link(string $publicKey, string $secretKey, string|null $machineName = null): bool
pm2()->unlink(): bool
pm2()->start(string $command = null, array $options = []): bool
pm2()->findBy(string $key, string $value): \JalalLinuX\Pm2\Structure\Process|null
pm2()->kill(): bool
pm2()->pid(string $name): int|null
pm2()->flush(): bool
pm2()->update(): mixed
pm2()->stopAll(): bool
pm2()->restartAll(): bool
pm2()->deleteAll(): bool
pm2()->stop(string $idOrName): bool
pm2()->restart(string $idOrName): bool
pm2()->delete(string $idOrName): bool
pm2()->save(bool $force = true): bool
pm2()->logOut(string $idOrName = null, int $lines = 100): string
pm2()->logErr(string $idOrName = null, int $lines = 100): string
pm2()->startup(): bool
pm2()->version(): string
pm2()->install(string $version = 'latest'): false|string|null
pm2()->isInstall(bool $forceInstall = false, string $version = 'latest'): bool
bash
composer