|
22 | 22 | <h2><a href="#git" id="git">Configure GitHub App</a></h2>
|
23 | 23 | <p>
|
24 | 24 | Appwrite supports automatic deployments through Git integration.
|
25 |
| - In order for Appwrite to access your repos, you must configure a GitHub app to enable this integration. |
| 25 | + In order for Appwrite to access your repos, you must <a href="https://docs.github.com/en/apps/creating-github-apps/about-creating-github-apps/about-creating-github-apps" target="_blank" rel="noopener">create a GitHub app</a> to enable this integration. |
| 26 | + The GitHub app requires the following configurations. |
26 | 27 | </p>
|
27 | 28 |
|
28 |
| -<p>You'll have to configure the following environment variables.</p> |
| 29 | +<p> |
| 30 | + For automatic Git deployment to work, Appwrite needs to receive communication from GitHub, this means your Appwrite project must be accessible on the internet. |
| 31 | + If you're running on <code>localhost</code>, you need to run a proxy like <a href="https://ngrok.com/" target="_blank" rel="noopener">ngrok</a>. |
| 32 | +</p> |
| 33 | + |
| 34 | +<h3><a href="#callback" id="callback">Callback URL</a></h3> |
| 35 | +<p> |
| 36 | + GitHub will use <b>callback URLs</b> to redirect users back to Appwrite. |
| 37 | + Set these callback URLs under <b>Identifying and authorizing users</b>. |
| 38 | +</p> |
| 39 | +<table class="full"> |
| 40 | + <thead> |
| 41 | + <tr> |
| 42 | + <td>URLs</td> |
| 43 | + </tr> |
| 44 | + </thead> |
| 45 | + <tbody> |
| 46 | + <tr> |
| 47 | + <td><code>http://[HOSTNAME_OR_IP]/v1/vcs/github/callback</code></td> |
| 48 | + </tr> |
| 49 | + <tr> |
| 50 | + <td><code>http://[HOSTNAME_OR_IP]/v1/account/sessions/oauth2/callback/github/console</code></td> |
| 51 | + </tr> |
| 52 | + </tbody> |
| 53 | +</table> |
| 54 | + |
| 55 | +<h3><a href="#post-install" id="post-install">Post Installation</a></h3> |
| 56 | +<p> |
| 57 | + Check the <b>Redirect on update</b> box under the <b>Post installation</b> section. |
| 58 | +</p> |
| 59 | + |
| 60 | + |
| 61 | +<h3><a href="#github-webhooks" id="github-webhooks">Webhook</a></h3> |
| 62 | +<p> |
| 63 | + GitHub will notify Appwrite about events like new commits using webhooks. |
| 64 | + Under <b>Webhook</b>, you need to check the <b>Active</b> checkbox. |
| 65 | + You also need to set the <b>Webhook URL</b> as <code>https://[HOSTNAME_OR_IP]/v1/vcs/github/events</code>. |
| 66 | +</p> |
| 67 | + |
| 68 | +<p> |
| 69 | + If you're running Appwrite on <code>localhost</code>, GitHub can't send requests to Appwrite through webhooks and automatic deployments won't work. |
| 70 | + You'll need host Appwrite on a server or use a proxy like <a href="https://ngrok.com/" target="_blank" rel="noopener">ngrok</a> to make Appwrite accessible to GitHub. |
| 71 | +</p> |
| 72 | + |
| 73 | +<h3><a href="#repository-permission" id="repository-permission">Repository Permissions</a></h3> |
| 74 | +<p> |
| 75 | + Configure these permissions under the <b>Repository permission</b> dropdown. |
| 76 | +</p> |
| 77 | +<table class="full"> |
| 78 | + <thead> |
| 79 | + <tr> |
| 80 | + <td>Permission</td> |
| 81 | + <td>Access</td> |
| 82 | + </tr> |
| 83 | + </thead> |
| 84 | + <tbody> |
| 85 | + <tr> |
| 86 | + <td>Administration</td> |
| 87 | + <td>Read and write</td> |
| 88 | + </tr> |
| 89 | + <tr> |
| 90 | + <td>Checks</td> |
| 91 | + <td>Read and write.</td> |
| 92 | + </tr> |
| 93 | + <tr> |
| 94 | + <td>Commit Statuses</td> |
| 95 | + <td>Read and write</td> |
| 96 | + </tr> |
| 97 | + <tr> |
| 98 | + <td>Contents</td> |
| 99 | + <td>Read and write</td> |
| 100 | + </tr> |
| 101 | + <tr> |
| 102 | + <td>Issues</td> |
| 103 | + <td>Read and write</td> |
| 104 | + </tr> |
| 105 | + <tr> |
| 106 | + <td>Metadata</td> |
| 107 | + <td>Read-only</td> |
| 108 | + </tr> |
| 109 | + <tr> |
| 110 | + <td>Pull requests</td> |
| 111 | + <td>Read and write</td> |
| 112 | + </tr> |
| 113 | + <tr> |
| 114 | + <td>Webhooks</td> |
| 115 | + <td>Read and write</td> |
| 116 | + </tr> |
| 117 | + </tbody> |
| 118 | +</table> |
| 119 | + |
| 120 | +<h3><a href="#account-permission" id="account-permission">Account Permissions</a></h3> |
| 121 | +<p> |
| 122 | + Configure these permissions under the <b>Account Permission</b> dropdown. |
| 123 | +</p> |
| 124 | +<table class="full"> |
| 125 | + <thead> |
| 126 | + <tr> |
| 127 | + <td>Permission</td> |
| 128 | + <td>Access</td> |
| 129 | + </tr> |
| 130 | + </thead> |
| 131 | + <tbody> |
| 132 | + <tr> |
| 133 | + <td>Email address</td> |
| 134 | + <td>Read-only</td> |
| 135 | + </tr> |
| 136 | + </tbody> |
| 137 | +</table> |
| 138 | + |
| 139 | +<h3><a href="#subscribe-events" id="subscribe-events">Subscribe to Events</a></h3> |
| 140 | +<p> |
| 141 | + Select these under the <b>Subscribe to events</b> dropdown. |
| 142 | +</p> |
| 143 | +<table class="full"> |
| 144 | + <thead> |
| 145 | + <tr> |
| 146 | + <td>Event</td> |
| 147 | + <td></td> |
| 148 | + <td></td> |
| 149 | + </tr> |
| 150 | + </thead> |
| 151 | + <tbody> |
| 152 | + <tr> |
| 153 | + <td>Pull request</td> |
| 154 | + <td>Push</td> |
| 155 | + <td></td> |
| 156 | + </tr> |
| 157 | + </tbody> |
| 158 | +</table> |
| 159 | + |
| 160 | +<h3><a href="#github-variables" id="github-variables">Environment Variables</a></h3> |
| 161 | +<p>After creating your app, you'll have to configure the following environment variables.</p> |
29 | 162 |
|
30 | 163 | <table class="full">
|
31 | 164 | <thead>
|
|
37 | 170 | <tbody>
|
38 | 171 | <tr>
|
39 | 172 | <td>_APP_VCS_GITHUB_APP_NAME</td>
|
40 |
| - <td>Name of your GitHub app. This value should be set to your GitHub application's URL.</td> |
| 173 | + <td>Name of your GitHub app. This is the display name you'll see on GitHub and it will be visible in your GitHub app's URL.</td> |
41 | 174 | </tr>
|
42 | 175 | <tr>
|
43 | 176 | <td>_APP_VCS_GITHUB_PRIVATE_KEY</td>
|
|
64 | 197 |
|
65 | 198 | <p><a href="/docs/environment-variables"><i class="icon-angle-circled-right margin-start-negative-tiny margin-end-tiny"></i> Learn more about environment variables</a></p>
|
66 | 199 |
|
| 200 | +<h3><a href="#existing-apps" id="existing-apps">Update Existing GitHub Apps</a></h3> |
| 201 | +<p> |
| 202 | + There are additional steps if you're updating permissions in existing GitHub apps. |
| 203 | + Every time you update your GitHub app's permissions, GitHub will prompt you to review the changes. |
| 204 | + You will receive an email and you'll find a prompt under <b>Settings</b> > <b>Integrations</b> > <b>Applications</b> > <b>Installed GitHub Apps</b> > find your GitHub app > <b>Configure</b>. |
| 205 | + You need to accept the new permissions so they're applied to your app. |
| 206 | +</p> |
| 207 | + |
67 | 208 | <h2><a href="#functions" id="functions">Configure Function Runtimes</a></h2>
|
68 | 209 | <p>
|
69 | 210 | Not all function runtimes are enabled by default. Enable the runtimes that you need and disable unused runtimes to save disk space on your server.
|
|
80 | 221 |
|
81 | 222 | <p>You can find a full list of supported runtimes on the <a href="/docs/environment-variables#functions">environment variables</a> page.</p>
|
82 | 223 |
|
83 |
| -<p>You can also configure the maximum timeout that can be set on individual Appwrite functions. The maximum configurable timeout can be increased by changing the <code>_APP_FUNCTIONS_TIMEOUT</code> environment variable. This environment variable changes the configurable maximum but does not alter existing individual configurations.</p> |
| 224 | +<p>You can also configure the maximum timeout that can be set on individual Appwrite functions. The maximum configurable timeout can be increased by changing the <code>_APP_FUNCTIONS_TIMEOUT</code> environment variable. This environment variable changes the configurable maximum but does not alter existing configurations of individual functions.</p> |
84 | 225 |
|
85 |
| -<h2><a href="#storage" id="storage">Storage Adaptors</a></h2> |
| 226 | +<h2><a href="#storage" id="storage">Storage Adapters</a></h2> |
86 | 227 | <p>Appwrite's Storage Service can be configured to store files locally, or with self-hosted and cloud storage services. By default, Appwrite's Storage Service <b>stores files on your server's local storage</b>. If you expect large volumes of data or the need to have scalable data storage, you may choose to use a separate storage service.</p>
|
87 | 228 |
|
88 |
| -<p>Appwrite supports AWS S3, Digital Ocean Spaces, Backblaze, Akamai Object Storage, and Wasabi as storage adaptors. Some of these services can be self-hosted, just like Appwrite.</p> |
| 229 | +<p>Appwrite supports AWS S3, Digital Ocean Spaces, Backblaze, Akamai Object Storage, and Wasabi as storage adapters. Some of these services can be self-hosted, just like Appwrite.</p> |
89 | 230 |
|
90 |
| -<p>You can select which storage adaptor to use by setting the <code>_APP_STORAGE_DEVICE</code> environment variable. Valid values are <code>local</code>, <code>s3</code>, <code>dospaces</code>, <code>backblaze</code>, <code>linode</code> and <code>wasabi</code>. Each storage adaptor requires its own set of additional environment variables to configure.</p> |
| 231 | +<p>You can select which storage adapter to use by setting the <code>_APP_STORAGE_DEVICE</code> environment variable. Valid values are <code>local</code>, <code>s3</code>, <code>dospaces</code>, <code>backblaze</code>, <code>linode</code>, and <code>wasabi</code>. Each storage adapter requires its own set of additional environment variables to configure.</p> |
91 | 232 |
|
92 | 233 | <p>The maximum size for individual file uploads is controlled by the <code>_APP_STORAGE_LIMIT</code> environment variable, which defaults to 30 MB. See <a href="/docs/environment-variables#storage">Environment Variables</a> for more information.</p>
|
93 | 234 |
|
94 |
| -<p><a href="/docs/environment-variables#storage"><i class="icon-angle-circled-right margin-start-negative-tiny margin-end-tiny"></i> Configure storage adaptors</a></p> |
| 235 | +<p><a href="/docs/environment-variables#storage"><i class="icon-angle-circled-right margin-start-negative-tiny margin-end-tiny"></i> Configure storage adapters</a></p> |
95 | 236 |
|
96 | 237 | <h2><a href="#apply-changes" id="apply-changes">Applying Changes</a></h2>
|
97 | 238 | <p>After editing your <code>docker-compose.yml</code> or <code>.env</code> files, you will need to recreate your Appwrite stack by running the following compose command in your terminal.</p>
|
|
0 commit comments