You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+37-13
Original file line number
Diff line number
Diff line change
@@ -66,21 +66,45 @@ cp .env.example .env
66
66
67
67
7. Import the database from a production WordPress instance.
68
68
69
-
```sh
70
-
# You need SSH admin access to this production server
71
-
ssh wp-05.ops.jquery.net
72
-
sudo -u tarsnap mysqldump --databases `sudo -u tarsnap mysql -B -N -e "SHOW DATABASES LIKE 'wordpress_%'"` > wordpress.sql
73
-
```
69
+
```sh
70
+
# You need SSH admin access to this production server
71
+
ssh wp-05.ops.jquery.net
74
72
75
-
Then, on your local machine, run:
73
+
sudo -u tarsnap mysqldump --databases `sudo -u tarsnap mysql -B -N -e "SHOW DATABASES LIKE 'wordpress_%'"` > wordpress.sql
74
+
```
76
75
77
-
```sh
78
-
# Copy the SQL dump from your home directory on the server (as created by the previous command)
79
-
scp wp-05.ops.jquery.net:~/wordpress.sql .
80
-
# Docker root database password must match your .env file
81
-
# NOTE: There must be no space between -p and the password!
82
-
docker exec -i jquerydb mysql -u root -proot < wordpress.sql
83
-
```
76
+
Then, on your local machine, run:
77
+
78
+
```sh
79
+
# Copy the SQL dump from your home directory on the server (as created by the previous command)
80
+
# NOTE: There must be no space between -p and the password!
81
+
scp wp-05.ops.jquery.net:~/wordpress.sql .
82
+
docker exec -i jquerydb mysql -u root -proot < wordpress.sql
83
+
```
84
+
85
+
Optionally, import the blog database as well. This uses a slightly different set of commands because blog have a shorter naming convention for their database and theme than the doc sites.
86
+
87
+
```sh
88
+
ssh wpblogs-01.ops.jquery.net
89
+
90
+
# Export wordpress_jquery, and import as wordpress_blog_jquery_com.
91
+
# Use --no-create-db to omit DB name during export, so we can set expected name during import.
echo 'CREATE DATABASE IF NOT EXISTS wordpress_blog_jquery_com; CREATE DATABASE IF NOT EXISTS wordpress_blog_jqueryui_com; CREATE DATABASE IF NOT EXISTS wordpress_blog_jquerymobile_com;' | docker exec -i jquerydb mysql -u root -proot
0 commit comments