Skip to content

Commit

Permalink
Merge pull request #190 from kcristiano/docs2024
Browse files Browse the repository at this point in the history
update README.md with examples
  • Loading branch information
totten authored Mar 1, 2024
2 parents 0f774b8 + 84290dd commit 8eb5256
Showing 1 changed file with 23 additions and 7 deletions.
30 changes: 23 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ Bootstrap
configuring "multi-site", adding bespoke "symlinks", or moving the `wp-admin` folder. For advanced layouts, you
may need to set an environment variable.
* __`CIVICRM_BOOT`__: To enable the _standard boot protocol_, set this environment variable. Specify the CMS type and base-directory. Examples:
* __`CIVICRM_BOOT`__ (*new protocol*): Boot the CMS first (and then ask it to boot CiviCRM). This is more representative of a typical HTTP page-view, and it is compatible with commands like `core:install`. Set this environment variable to specify the CMS type and base-directory. Compare:
```bash
export CIVICRM_BOOT="Drupal://var/www/public"
Expand All @@ -212,10 +212,7 @@ Bootstrap
export CIVICRM_BOOT="Auto://."
```
(Note: In the standard protocol, `cv` loads a CMS first and then asks it to bootstrap CiviCRM. This is more representative of
a typical HTTP page-view, and it is compatible with commands like `core:install`. However, it has not been used for as long.)
* __`CIVICRM_SETTINGS`__: To enable the _legacy boot protocol_, set this environment variable. Specify the `civicrm.settings.php` location. Examples:
* __`CIVICRM_SETTINGS`__ (*old protocol*): Boot CiviCRM first (and then ask it to boot the CMS). Set this environment variable to specify the `civicrm.settings.php` location. Compare:
```bash
export CIVICRM_SETTINGS="/var/www/sites/default/files/civicrm.settings.php"
Expand All @@ -229,9 +226,28 @@ Bootstrap
> ___NOTE___: In absence of a configuration variable, the __Automatic__ mode will behave like `CIVICRM_SETTINGS="Auto"` (in v0.3.x).
This is tentatively planned to change in v0.4.x, where it will behave like `CIVICRM_BOOT="Auto://."`
Additionally, the following variables may be used to supplement:
Additionally, some deployments handle multiple sites ("multisite"/"multidomain"). You should target a specific site using `--hostname` or `HTTP_HOST`.
Here are a few examples of putting these together:
```bash
## Use --hostname for a domain
export CIVICRM_BOOT="WordPress:/$HOME/public_html/"
cv --hostname='www.example.org' ext:list -L
```
```bash
## Use HTTP_HOST for a domain
export CIVICRM_BOOT="WordPress:/$HOME/public_html/"
export HTTP_HOST=www.example.org
cv ext:list -L
```
* __`HTTP_HOST`__: For multisite deployments, set this variable to the hostname (e.g. `HTTP_HOST=www.example.com`).
```bash
## Use --hostname for a subfolder
export CIVICRM_BOOT="WordPress:/$HOME/public_html/"
cv --hostname='www.example.org/nyc' ext:list -L
```
Autocomplete
============
Expand Down

0 comments on commit 8eb5256

Please sign in to comment.