sarga/public/installer/MigrationRun.php

15 lines
320 B
PHP
Raw Normal View History

2019-06-03 11:02:50 +00:00
<?php
ini_set('max_execution_time', 300);
// array to pass back data
2020-02-19 00:31:23 +00:00
$data = array();
2019-06-03 11:02:50 +00:00
// run command on terminal
$command = 'cd ../.. && php artisan migrate --force';
$last_line = exec($command, $data['migrate'], $data['results']);
// return a response
//return all our data to an AJAX call
echo json_encode($data);