|
5 | 5 |
|
6 | 6 | # WP Engine GitHub Action for Site Deployment |
7 | 7 |
|
8 | | -Use this GitHub Action to deploy code from a GitHub repo to a WP Engine environment of your choosing. |
9 | | -What this action lets you do: |
10 | | - * Deploy a full site directory or a subdirectory of your WordPress install |
| 8 | +Use this GitHub Action to deploy code from a GitHub repo to a WP Engine environment of your choosing. If you dot not have a WP Engine Account, [click here to get started!](https://wpengine.com/plans/?utm_content=wpe_gha) |
| 9 | + |
| 10 | +This action enables you to: |
| 11 | + * Deploy a full site directory or subdirectory of your WordPress install |
11 | 12 | * Perform a PHP Lint |
12 | | - * Custom rsync flags |
| 13 | + * Customize rsync flags |
13 | 14 | * Clear cache |
14 | 15 | * Execute a post-deploy script of your choosing |
15 | 16 |
|
16 | 17 | ## Setup Instructions |
17 | 18 |
|
18 | | -1. **SSH PRIVATE KEY SETUP IN GITHUB** |
19 | | -* [Generate a new SSH key pair](https://wpengine.com/support/ssh-keys-for-shell-access/#Generate_New_SSH_Key) if you have not already done so. Please note that this SSH Key needs to be *passwordless*. |
20 | | - |
21 | | -* Add the *SSH Private Key* to your [Repository Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository) or your [Organization Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-an-organization). Save the new secret "Name" as `WPE_SSHG_KEY_PRIVATE`. |
22 | 19 |
|
23 | | -**NOTE:** If using a GitHub Organization, adding the SSH key to the [Organization Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-an-organization) will allow all repos to reference the same SSH key for deploys using the method in the sample `main.yml`. The SSH Key also connects to all installs made available to its WP Engine User. One key can then effectively be used to deploy all projects to their respective sites on WP Engine. Less work. More deploys! |
| 20 | +1. **SSH PUBLIC KEY SETUP IN WP ENGINE** |
| 21 | +* [Generate a new SSH key pair](https://wpengine.com/support/ssh-keys-for-shell-access/#Generate_New_SSH_Key?utm_content=wpe_gha) if you have not already done so. Please note that this SSH Key needs to be *passwordless*. |
24 | 22 |
|
25 | | -2. **SSH PUBLIC KEY SETUP IN WP ENGINE** |
| 23 | +* Add *SSH Public Key* to WP Engine SSH Gateway Key settings. [This Guide will show you how.](https://wpengine.com/support/ssh-gateway/#Add_SSH_Key?utm_content=wpe_gha) |
26 | 24 |
|
27 | | -* Add *SSH Public Key* to WP Engine SSH Gateway Key settings. [This Guide will show you how.](https://wpengine.com/support/ssh-gateway/#Add_SSH_Key) |
| 25 | +2. **SSH PRIVATE KEY SETUP IN GITHUB** |
28 | 26 |
|
29 | | -**NOTE:** This Action DOES NOT utilize WP Engine GitPush or the GitPush SSH keys [found here.](https://wpengine.com/support/git/#Add_SSH_Key_to_User_Portal) |
| 27 | +* Add the *SSH Private Key* to your [Repository Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-a-repository) or your [Organization Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-an-organization). Save the new secret "Name" as `WPE_SSHG_KEY_PRIVATE`. |
30 | 28 |
|
31 | 29 | 3. **YML SETUP** |
32 | 30 |
|
@@ -112,11 +110,15 @@ jobs: |
112 | 110 | | `CACHE_CLEAR` | bool | Optionally clear page and CDN cache post deploy. This takes a few seconds. Default is TRUE. | |
113 | 111 |
|
114 | 112 |
|
| 113 | + |
| 114 | + |
115 | 115 | ### Further reading |
116 | 116 |
|
| 117 | +* **NOTE:** This Action DOES NOT utilize WP Engine GitPush or the GitPush SSH keys [found here.](https://wpengine.com/support/git/#Add_SSH_Key_to_User_Portal?utm_content=wpe_gha) |
| 118 | +* **TIP:** If using a GitHub Organization, adding the SSH key to the [Organization Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets#creating-encrypted-secrets-for-an-organization) will allow all repos to reference the same SSH key for deploys using the method in the sample `main.yml`. The SSH Key also connects to all installs made available to its WP Engine User. One key can then effectively be used to deploy all projects to their respective sites on WP Engine. Less work. More deploys! |
117 | 119 | * [Defining environment variables in GitHub Actions](https://docs.github.com/en/actions/reference/environment-variables) |
118 | 120 | * [Storing secrets in GitHub repositories](https://docs.github.com/en/actions/reference/encrypted-secrets) |
119 | | -* It is recommended to leverage one of [WP Engine's .gitignore templates.](https://wpengine.com/support/git/#Add_gitignore) |
| 121 | +* It is recommended to leverage one of [WP Engine's .gitignore templates.](https://wpengine.com/support/git/#Add_gitignore?utm_content=wpe_gha) |
120 | 122 | * This action excludes several files and directories from the deploy by default. See the [exclude.txt](https://github.com/wpengine/github-action-wpe-site-deploy/blob/main/exclude.txt) for reference. |
121 | 123 |
|
122 | 124 | ## Versioning |
|
0 commit comments