22
33This is a small command line tool for downloading and configuring
44WordPress for Google Cloud Platform. The script allows you to create a
5- working WordPress project for
6- [ App Engine standard environment] [ appengine-standard ] or
5+ working WordPress project for the
6+ [ App Engine standard environment] [ appengine-standard ] or the
77[ App Engine flexible environment] [ appengine-flexible ] .
88
99## Common Prerequisites
1010
1111* Install [ Composer] [ composer ]
12- * Create a new Cloud Project on [ Developers Console] [ dev -console]
12+ * Create a new Cloud Project using the [ Cloud Console] [ cloud -console]
1313* Enable Billing on that project
1414* [ Enable Cloud SQL API] [ cloud-sql-api-enable ] (For App Engine flexible environment)
15- * Create App Engine default bucket at [ App Engine Setting Page] [ app-engine-setting ]
15+ * Create App Engine default bucket at [ App Engine Settings Page] [ app-engine-setting ]
1616* Install [ Google Cloud SDK] [ gcloud-sdk ]
1717
1818## Prerequisites for standard environment only
@@ -40,25 +40,25 @@ $ gsutil defacl ch -u AllUsers:R gs://YOUR_PROJECT_ID.appspot.com
4040
4141## Create and configure a Cloud SQL instance
4242
43- If you will use App Engine flexible environment, create a Cloud SQL
44- 2nd generation instance, and if you will use App Engine standard
43+ If you will use the App Engine flexible environment, create a Cloud SQL
44+ 2nd generation instance, and if you will use the App Engine standard
4545environment, create a Cloud SQL 1st generation instance.
4646
47- In this guide, we use ` wp ` for various resource names; the instance
47+ In this guide, we use ` wp ` for various resource names: the instance
4848name, the database name, and the user name.
4949
50- ### Create and configure a Cloud SQL 1st generation instance(for standard environment)
50+ ### Create and configure a Cloud SQL 1st generation instance (for the standard environment)
5151
5252Go to the [ SQL settings in the Cloud Console] [ sql-settings ] and create
5353an instance ` wp ` and database named ` wp ` . Go to the Access Control ->
5454Users, then change the password for ` root@localhost ` . You will use
55- this password for accessing from App Engine application.
55+ this password for accessing Cloud SQL from your App Engine application.
5656
5757Also create the ` wp ` database in the local mysql server. The local
58- mysql instance is required to run ` wp-cli ` tool for
58+ mysql instance is required to run the ` wp-cli ` tool for
5959installing/upgrading plugins and themes.
6060
61- ### Create and configure a Cloud SQL 2nd generation instance(for flexible environment)
61+ ### Create and configure a Cloud SQL 2nd generation instance (for the flexible environment)
6262
6363You can create a new Cloud SQL Second Generation instance with the
6464following command:
@@ -76,11 +76,11 @@ $ gcloud sql instances set-root-password wp \
7676 --password YOUR_INSTANCE_ROOT_PASSWORD # Don't use this password!
7777```
7878
79- To access this MySQL instance, we’ll use Cloud SQL Proxy. Please
80- download an appropriate binary from
81- [ the download page] [ cloud-sql-proxy-download ] , make it executable.
79+ To access this MySQL instance, use Cloud SQL Proxy.
80+ Download an appropriate binary from
81+ [ the download page] [ cloud-sql-proxy-download ] and make it executable.
8282
83- If you haven’t created a service account for the project, please
83+ If you haven’t created a service account for the project,
8484create it on [ the Credentials section] [ credentials-section ] in the
8585Console (Choose a new service account). Download the JSON key file and
8686save it in a secure place.
@@ -94,8 +94,8 @@ $ cloud_sql_proxy \
9494 -credential_file=PATH_TO_YOUR_SERVICE_ACCOUNT_JSON
9595```
9696
97- Now you can access to the Cloud SQL instance with the normal MySQL
98- client. Please create a new database and a user as follows:
97+ Now you can access the Cloud SQL instance with the normal MySQL
98+ client. Create a new database and a user as follows:
9999
100100```
101101$ mysql -h 127.0.0.1 -u root -p
@@ -106,8 +106,6 @@ mysql> exit
106106Bye
107107```
108108
109- In the above example, I created a new database wp and a new user wp.
110-
111109## How to use
112110
113111First install the dependencies in this directory as follows:
@@ -147,7 +145,7 @@ $ vendor/bin/wp(.bat) server --path=wordpress
147145
148146Then access http://localhost:8080/ . Follow the installation steps,
149147create the admin user and its password. Login to the Dashboard and
150- update if any of the plugins have update .
148+ update if any of the plugins have updates .
151149
152150Now it’s ready for the first deployment.
153151
@@ -163,15 +161,15 @@ $ gcloud app deploy \
163161Then access your site, and continue the installation step. The URL is:
164162https://PROJECT_ID.appspot.com/
165163
166- Go to the Dashboard, and in the Plugins page, activate the following
164+ Go to the Dashboard. On the Plugins page, activate the following
167165plugins:
168166
169167
170- - For standard environment
168+ - For the standard environment
171169 - App Engine WordPress plugin (also set the e-mail address in its
172- setting page)
170+ settings page)
173171 - Batcache Manager
174- - For flexible environment
172+ - For the flexible environment
175173 - Batcache Manager
176174 - GCS media plugin
177175
@@ -220,8 +218,8 @@ update the config file manually in that case.
220218
221219### Update the base image
222220
223- We sometimes release the security update for
224- [ the php-docker image] [ php-docker ] . Then you’ll have to re-deploy your
221+ We sometimes release a security update for
222+ [ the php-docker image] [ php-docker ] . You have to re-deploy your
225223WordPress instance to get the security update.
226224
227225Enjoy your WordPress installation!
@@ -231,7 +229,7 @@ Enjoy your WordPress installation!
231229[ sql-settings ] : https://console.cloud.google.com/sql/instances
232230[ memcache-dashboard ] : https://console.cloud.google.com/appengine/memcache
233231[ composer ] : https://getcomposer.org/
234- [ dev -console] : https://console.cloud.google.com/
232+ [ cloud -console] : https://console.cloud.google.com/
235233[ cloud-sql-api-enable ] : https://console.cloud.google.com/flows/enableapi?apiid=sqladmin
236234[ app-engine-setting ] : https://console.cloud.google.com/appengine/settings
237235[ gcloud-sdk ] : https://cloud.google.com/sdk/
0 commit comments