sarga/public/installer/MigrationRun.php

15 lines
323 B
PHP
Raw Normal View History

<?php
2019-03-26 06:27:30 +00:00
ini_set('max_execution_time', 300);
2019-01-24 05:33:11 +00:00
// array to pass back data
$data = array();
2019-01-24 05:33:11 +00:00
// run command on terminal
2019-03-08 04:59:01 +00:00
$command = 'cd ../.. && php artisan migrate --force';
2019-01-24 05:33:11 +00:00
$last_line = exec($command, $data['migrate'], $data['results']);
2019-01-24 05:33:11 +00:00
// return a response
//return all our data to an AJAX call
2019-01-24 05:33:11 +00:00
echo json_encode($data);