File tree Expand file tree Collapse file tree 2 files changed +19
-2
lines changed Expand file tree Collapse file tree 2 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -133,7 +133,7 @@ public function getCommand(array $connection)
133
133
{
134
134
return [
135
135
'mysql ' => 'mysql ' ,
136
- 'mariadb ' => 'mysql ' ,
136
+ 'mariadb ' => 'mariadb ' ,
137
137
'pgsql ' => 'psql ' ,
138
138
'sqlite ' => 'sqlite3 ' ,
139
139
'sqlsrv ' => 'sqlcmd ' ,
Original file line number Diff line number Diff line change 4
4
5
5
class MariaDbSchemaState extends MySqlSchemaState
6
6
{
7
+ /**
8
+ * Load the given schema file into the database.
9
+ *
10
+ * @param string $path
11
+ * @return void
12
+ */
13
+ public function load ($ path )
14
+ {
15
+ $ command = 'mariadb ' .$ this ->connectionString ().' --database="${:LARAVEL_LOAD_DATABASE}" < "${:LARAVEL_LOAD_PATH}" ' ;
16
+
17
+ $ process = $ this ->makeProcess ($ command )->setTimeout (null );
18
+
19
+ $ process ->mustRun (null , array_merge ($ this ->baseVariables ($ this ->connection ->getConfig ()), [
20
+ 'LARAVEL_LOAD_PATH ' => $ path ,
21
+ ]));
22
+ }
23
+
7
24
/**
8
25
* Get the base dump command arguments for MariaDB as a string.
9
26
*
10
27
* @return string
11
28
*/
12
29
protected function baseDumpCommand ()
13
30
{
14
- $ command = 'mysqldump ' .$ this ->connectionString ().' --no-tablespaces --skip-add-locks --skip-comments --skip-set-charset --tz-utc --column-statistics=0 ' ;
31
+ $ command = 'mariadb-dump ' .$ this ->connectionString ().' --no-tablespaces --skip-add-locks --skip-comments --skip-set-charset --tz-utc ' ;
15
32
16
33
return $ command .' "${:LARAVEL_LOAD_DATABASE}" ' ;
17
34
}
You can’t perform that action at this time.
0 commit comments