|
|
# Continuous Integration
|
|
|
|
|
|
## Environments
|
|
|
|
|
|
A complete environments is a Virtual Machine with:
|
|
|
|
|
|
- Ubuntu 20.04 LTS
|
|
|
- Drupal 9.x (with LAMP, apache2, mariadb 15.x & php 8.x
|
|
|
- Node-Red 2.2.x
|
|
|
|
|
|
... and environments types are
|
|
|
|
|
|
### Production
|
|
|
[network.guifi.net](https://network.guifi.net) (VM 5612) at main PROD cluster (clu01) in BCNZF site
|
|
|
|
|
|
[network.guifi.net](https://network.guifi.net) (VM 5612) at main PROD cluster (clu01), BCNZF site.
|
|
|
|
|
|
### Test
|
|
|
|
|
|
[test.network.guifi.net](https://test.network.guifi.net). Weekly snapshot (Sundays 10am) from PROD
|
|
|
|
|
|
### Development
|
|
|
|
|
|
At developers wish...
|
|
|
|
|
|
## Process for promoting to PROD
|
|
|
|
|
|
### Synching TEST/PRE to PROD
|
|
|
Drupal official docs on configuration synchronization between sites using drush:
|
|
|
[https://www.drupal.org/docs/configuration-management/workflow-using-drush](https://www.drupal.org/docs/configuration-management/workflow-using-drush)
|
|
|
|
|
|
So, in the case of promoting from our test.network.guifi.net (TEST/PRE) to network.guifi.net (PROD)
|
|
|
Drupal official docs on configuration synchronization between sites using drush: <https://www.drupal.org/docs/configuration-management/workflow-using-drush>
|
|
|
|
|
|
So, in the case of promoting from our test.network.guifi.net (TEST/PRE) to network.guifi.net (PROD), follow the next steps:
|
|
|
|
|
|
#### 1.- Preliminar:
|
|
|
After a clean snapshot at test from prod, apply the changes you want to test, and if everything looks ok, then apply to prod by completing the next steps.
|
|
|
|
|
|
After a clean snapshot at test from prod, apply the changes you want to test, and if everything looks ok, then apply to prod by completing the next steps.\
|
|
|
Be sure that the unique differences between PRE & PROD are the ones you want to promote, and that the "config" directory located at "sites/default/files/config_\*/ is either clean, or even better, remove it's contents to ensure that is clean:
|
|
|
|
|
|
`cd /var/www/html/net9/web/sites/default/files`
|
|
|
|
|
|
`cd config_*`
|
|
|
|
|
|
`rm -rf *`
|
|
|
|
|
|
#### 2.- Export current configuration at PRE/TEST site as user "fundacio" using drush:
|
|
|
|
|
|
```
|
|
|
```plaintext
|
|
|
cd /var/www/html/net9/web
|
|
|
drush config:export
|
|
|
```
|
|
|
|
|
|
|
|
|
``` |
|
|
\ No newline at end of file |