Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/drunomics/drush-phapp-env-mode
Provides drush commands for applying the phapp environment mode.
https://github.com/drunomics/drush-phapp-env-mode
Last synced: about 1 month ago
JSON representation
Provides drush commands for applying the phapp environment mode.
- Host: GitHub
- URL: https://github.com/drunomics/drush-phapp-env-mode
- Owner: drunomics
- Created: 2019-02-18T15:07:39.000Z (almost 6 years ago)
- Default Branch: 1.x
- Last Pushed: 2022-10-26T10:41:41.000Z (about 2 years ago)
- Last Synced: 2024-11-11T11:09:05.158Z (about 2 months ago)
- Language: PHP
- Size: 8.79 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Phapp environment switch
Provides config and drush commands for applying the Phapp environment mode variable.
## Prerequesites
* A [phapp-cli](https://github.com/drunomics/phapp-cli) enabled project.
* A working dotenv setup that loads PHAPP environment variables, as existing in
[drunomics/drupal-project](https://github.com/drunomics/drupal-project)## Setup
In drunomics/drupal-project, all setup steps are taken care already. For others:
1. Add the following to settings.php:
// Set active split configuration.
$split = getenv('PHAPP_ENV_MODE');
$config['config_split.config_split.' . $split]['status'] = TRUE;2. Export some config split configuration that will set further config per environment in your
config sync directory, name the split like the environment mode, "development", or "production".
You may use drunomics/dsk-config-split for creating suiting config.3. Run `phapp:apply-env-mode` during deployments right before `drush cim`.