File tree Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Original file line number Diff line number Diff line change 5
5
## Introduction
6
6
Sync remote database to a local database
7
7
8
- > Note this requires remote MySQL access in order to connect to a remote MySQL database. It does not use SSH currently. I'm open to PR's
8
+ Connection can be made over SSH or using a remote MySQL connection.
9
9
10
10
## Install
11
11
@@ -27,12 +27,32 @@ php artisan vendor:publish --provider="Dcblogdev\DbSync\DbSyncServiceProvider" -
27
27
28
28
Set the remote database credentials in your .env file
29
29
30
+ When using SSH Add:
30
31
```
32
+ REMOTE_USE_SSH=true
33
+ REMOTE_SSH_PORT=22
34
+ REMOTE_SSH_USERNAME=
31
35
REMOTE_DATABASE_HOST=
36
+
32
37
REMOTE_DATABASE_USERNAME=
33
38
REMOTE_DATABASE_NAME=
34
39
REMOTE_DATABASE_PASSWORD=
35
40
REMOTE_DATABASE_IGNORE_TABLES=''
41
+
42
+ REMOTE_REMOVE_FILE_AFTER_IMPORT=true
43
+ REMOTE_IMPORT_FILE=true
44
+ ```
45
+
46
+ For only MySQL remote connections:
47
+ ```
48
+ REMOTE_DATABASE_HOST=
49
+ REMOTE_DATABASE_USERNAME=
50
+ REMOTE_DATABASE_NAME=
51
+ REMOTE_DATABASE_PASSWORD=
52
+ REMOTE_DATABASE_IGNORE_TABLES=''
53
+
54
+ REMOTE_REMOVE_FILE_AFTER_IMPORT=true
55
+ REMOTE_IMPORT_FILE=true
36
56
```
37
57
38
58
Set a comma seperate list of tables NOT to export in ` REMOTE_DATABASE_IGNORE_TABLES `
You can’t perform that action at this time.
0 commit comments