undefined function yaml_parse_file

Here are the steps when you encounter the error below, it means that the yaml library is missing as it is not native to php per say

undefined function yaml_parse_file

Install YAML library for PHP when you see the error below

yum search yaml

First step is to install yaml via pecl

pecl install yaml-2.0.0

Second step is to create the following file

/etc/php/conf.d/ext-yaml.ini

And add the following line

echo "extension=yaml.so"

Then restart php server

service php-fpm restart

CRON JOB RESTART APACHE AUTOMATICALLY


Every 30 minutes 

/etc/crontab

  */30  *  *  *  *       root /etc/init.d/httpd restart > /dev/null 2>&1

  */30  *  *  *  *       root /etc/init.d/mysql restart > /dev/null 2>&1

Every hour

/etc/crontab

  0  *  *  *  *       root /etc/init.d/httpd restart > /dev/null 2>&1

Every minute

/etc/crontab

  *  *  *  *  *       root /etc/init.d/httpd restart > /dev/null 2>&1

Check logs 

tail n- 200  /var/log/cron

tail n- 200  /var/log/messages

Plus link here regarding dev/null 2>&1

————————————————————————

PHP DocBlock

/**
 * Returns a list of XXXXXXX
 *
 * @param string $route_group_uuid
 *
 * @return Array $listCarrierRoute
 *
 * @throws \Exception
 *
 * @version 05-05-2020
 * @author David Raleche <david@raleche.com>
 * @reference JIRA Ticket PMM2-862 Create route groups XXXXX
 */

Developer Helper – Command Cine

PSR-2 Code Styling

vendor/bin/phpcs --standard=PSR2  app src
vendor/bin/phpcbf --standard=PSR2  app src
vendor/bin/phpcbf --standard=PSR2 --report=json app src

phpunit

vendor/bin/phpunit
vendor/bin/phpunit --log-junit web/phpunit/phpunit.xml --coverage-clover web/phpunit/coverage.xml --coverage-html web/phpunit/

Swagger Generate swagger documentation Swagger endpoint

vendor/bin/openapi -o "web/swagger.json" app/ src/ web/