Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e7ad758

Browse files
authored
Merge pull request magento#4839 from magento/Cloud-2002.0.20
Cloud 2002.0.20 release
2 parents ef93d28 + e9ff478 commit e7ad758

27 files changed

+1230
-334
lines changed

_data/toc/cloud-guide.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ pages:
3838
- label: Magento Cloud CLI
3939
url: /cloud/reference/cli-ref-topic.html
4040

41+
- label: ece-tools package
42+
url: /cloud/reference/ece-tools-reference.html
43+
4144
- label: Git
4245
url: /cloud/reference/git-integration.html
4346

@@ -105,6 +108,9 @@ pages:
105108
- label: Connect to the database
106109
url: /cloud/docker/docker-database.html
107110

111+
- label: Functional testing in Docker
112+
url: /cloud/docker/docker-development-testing.html
113+
108114
- label: Docker quick reference
109115
url: /cloud/docker/docker-quick-reference.html
110116

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
{: .bs-callout .bs-callout-info}
1+
{: .bs-callout-info}
22
For current {{ site.data.var.ece }} release information, see [Release notes for ece-tools]({{ page.baseurl }}/cloud/release-notes/cloud-tools.html).

guides/v2.1/cloud/bk-cloud.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ Amazon Web Services (AWS) powers the underlying Infrastructure as a Service (Iaa
2222

2323
## {{site.data.var.ct}} package
2424

25-
The `{{site.data.var.ct}}` package is a scalable deployment tool that simplifies the Cloud upgrade process. In 2018, we deprecated the `magento-cloud-configuration` and `ece-patches` packages in favor of providing a single package. We encourage all customers to [upgrade to use `{{site.data.var.ct}}`]({{page.baseurl}}/cloud/project/ece-tools-upgrade-project.html) as soon as possible to benefit from the package features, such as commands to create a backup of the database, apply custom patches, and verify environment configuration.
25+
The [`{{site.data.var.ct}}` package][ece] is a scalable deployment tool that simplifies the Cloud upgrade process. In 2018, we deprecated the `magento-cloud-configuration` and `ece-patches` packages in favor of providing a single package. We encourage all customers to [upgrade to use `{{site.data.var.ct}}`]({{page.baseurl}}/cloud/project/ece-tools-upgrade-project.html) as soon as possible to benefit from the package features, such as commands to create a backup of the database, apply custom patches, and verify environment configuration.
2626

2727
<!-- Link definitions -->
2828

@@ -31,3 +31,5 @@ The `{{site.data.var.ct}}` package is a scalable deployment tool that simplifies
3131

3232
[Cloud Stack]: {{site.baseurl}}/common/images/cloud/CloudStack.png
3333
{: width="804px" height="721px"}
34+
35+
[ece]: {{page.baseurl}}/cloud/reference/ece-tools-reference.html

guides/v2.1/cloud/docker/docker-config.md

Lines changed: 50 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -52,38 +52,44 @@ For example, the following command starts the Docker configuration generator for
5252
./vendor/bin/ece-tools docker:build --mode="developer" --php 7.2
5353
```
5454

55-
### Prerequisites
55+
## Prerequisites
5656

57-
You must have the following software installed on your local workstation:
57+
1. You must have the following software installed on your local workstation:
5858

59-
- PHP version 7.1 or later
60-
- [[email protected]](https://formulae.brew.sh/formula/[email protected])
61-
- [[email protected]](https://formulae.brew.sh/formula/[email protected])
62-
- [Composer](https://getcomposer.org)
63-
- [Docker](https://www.docker.com/get-started)
64-
- [docker-sync](https://docker-sync.readthedocs.io/en/latest/getting-started/installation.html)—file synchronization is required for developer mode
59+
- PHP version 7.1 or later
60+
- [[email protected]](https://formulae.brew.sh/formula/[email protected])
61+
- [[email protected]](https://formulae.brew.sh/formula/[email protected])
62+
- [Composer](https://getcomposer.org)
63+
- [Docker](https://www.docker.com/get-started)
64+
- File synchronization required for developer mode—use one of the following:
65+
- [docker-sync](https://docker-sync.readthedocs.io/en/latest/getting-started/installation.html)
66+
- [mutagen](https://mutagen.io/documentation/installation/#installation)
6567

66-
Before you begin, you must add the following hostname to your `/etc/hosts` file:
68+
1. Update the hosts file.
6769

68-
```
69-
127.0.0.1 magento2.docker
70-
```
70+
Before you begin, you must add the following hostname to your `/etc/hosts` file:
7171

72-
Alternatively, you can run the following command to add it to the file:
72+
```
73+
127.0.0.1 magento2.docker
74+
```
7375
74-
```bash
75-
echo "127.0.0.1 magento2.docker" | sudo tee -a /etc/hosts
76-
```
76+
Alternatively, you can run the following command to add it to the file:
7777
78-
### Stopping default Apache instance on Mac OS
78+
```bash
79+
echo "127.0.0.1 magento2.docker" | sudo tee -a /etc/hosts
80+
```
7981
80-
Because Mac OS provides built-in Apache service, and may occupy port `80`, you must stop the service with the following command:
82+
1. Stop the default Apache instance on Mac OS.
8183
82-
```bash
83-
sudo apachectl stop
84-
```
84+
Because Mac OS provides built-in Apache service, and may occupy port `80`, you must stop the service with the following command:
85+
86+
```bash
87+
sudo apachectl stop
88+
```
8589
86-
#### To launch Docker:
90+
1. Optionally, [enable Xdebug]({{page.baseurl}}/cloud/docker/docker-development-debug.html#enable-xdebug).
91+
92+
## Launch the Docker environment
8793
8894
1. Download a Magento application template from the [Magento Cloud repository](https://github.com/magento/magento-cloud). Be careful to select the branch that corresponds with the Magento version.
8995
@@ -110,7 +116,7 @@ Continue launching your Docker environment in the default _production_ mode.
110116
1. _Optional_: If you have a custom PHP configuration file, copy the default configuration DIST file to your custom configuration file and make any necessary changes.
111117
112118
```bash
113-
cp docker/config.php.dist docker/config.php
119+
cp .docker/config.php.dist .docker/config.php
114120
```
115121
116122
Convert custom PHP configuration files to Docker ENV files.
@@ -121,12 +127,12 @@ Continue launching your Docker environment in the default _production_ mode.
121127
122128
This generates the following Docker ENV files:
123129
124-
* `docker/config.env`
130+
* `.docker/config.env`
125131
126132
{: .bs-callout .bs-callout-info}
127133
The `{{site.data.var.ct}}` version 2002.0.12 package does not support the `docker:config:convert` command.
128134
129-
1. _Optional_: Configure the Docker global variables in the `docker-compose.yml` file. For example, you can [enable and configure Xdebug]({{ page.baseurl }}/cloud/docker/docker-development-debug.html).
135+
1. _Optional_: Configure the Docker global variables in the `docker-compose.yml` file. For example, you can [configure Xdebug]({{ page.baseurl }}/cloud/docker/docker-development-debug.html#configure-xdebug).
130136
131137
1. Build files to containers and run in the background.
132138
@@ -138,15 +144,15 @@ Continue launching your Docker environment in the default _production_ mode.
138144
139145
- Build Magento in the Docker container:
140146
141-
```bash
142-
docker-compose run build cloud-build
143-
```
147+
```bash
148+
docker-compose run build cloud-build
149+
```
144150
145151
- Deploy Magento in the Docker container:
146152
147-
```bash
148-
docker-compose run deploy cloud-deploy
149-
```
153+
```bash
154+
docker-compose run deploy cloud-deploy
155+
```
150156
151157
{: .bs-callout .bs-callout-info}
152158
For `{{site.data.var.ct}}` v2002.0.12, install Magento with the `docker-compose run cli magento-installer` command.
@@ -184,7 +190,7 @@ The `{{site.data.var.ct}}` version 2002.0.18 and later supports developer mode.
184190
1. _Optional_: If you have a custom PHP configuration file, copy the default configuration DIST file to your custom configuration file and make any necessary changes.
185191
186192
```bash
187-
cp docker/config.php.dist docker/config.php
193+
cp .docker/config.php.dist .docker/config.php
188194
```
189195
190196
Convert custom PHP configuration files to Docker ENV files.
@@ -195,16 +201,24 @@ The `{{site.data.var.ct}}` version 2002.0.18 and later supports developer mode.
195201
196202
This generates the following Docker ENV files:
197203
198-
* `docker/config.env`
204+
* `.docker/config.env`
199205
200206
1. _Optional_: Configure the Docker global variables in the `docker-compose.yml` file. For example, you can [enable and configure Xdebug]({{ page.baseurl }}/cloud/docker/docker-development-debug.html).
201207
202208
1. Start the file synchronization.
203209
210+
For the `docker-sync` tool:
211+
204212
```bash
205213
docker-sync start
206214
```
207215
216+
For the `mutagen` tool:
217+
218+
```bash
219+
bash ./mutagen.sh
220+
```
221+
208222
1. Build files to containers and run in the background.
209223
210224
```bash
@@ -272,11 +286,11 @@ docker-sync stop
272286

273287
## Advanced usage
274288

275-
### Extending docker-compose.yml configuration
289+
### Extend the Docker configuration
276290

277-
You can use Docker's built-in [extension mechanism](https://docs.docker.com/compose/reference/overview/#specifying-multiple-compose-files).
291+
You can use the built-in extension mechanism of Docker to [specify multiple compose files](https://docs.docker.com/compose/reference/overview/#specifying-multiple-compose-files). The following example replaces the default value of the `ENABLE_SENDMAIL` environment variable.
278292

279-
1. Create a `docker-compose-dev.yml` file inside your project's root directory and add the following content:
293+
1. Create a `docker-compose-dev.yml` file inside your project root directory and add the following content:
280294

281295
```yaml
282296
version: '2'
@@ -286,8 +300,6 @@ You can use Docker's built-in [extension mechanism](https://docs.docker.com/comp
286300
- ENABLE_SENDMAIL=true
287301
```
288302
289-
This replaces the default value of the `ENABLE_SENDMAIL` environment variable.
290-
291303
1. Pass both configuration files while executing your commands. For example:
292304
293305
```bash

guides/v2.1/cloud/docker/docker-database.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ functional_areas:
77
- Configuration
88
---
99

10-
There are two ways to connect to the database. Before you begin, you can find the database credentials in the `database` section of the `docker/config.php` file. The examples use the following default credentials:
10+
There are two ways to connect to the database. Before you begin, you can find the database credentials in the `database` section of the `.docker/config.php` file. The examples use the following default credentials:
1111

12-
> Filename: `docker/config.php`
12+
> Filename: `.docker/config.php`
1313
1414
```php?start_inline=1
1515
return [
@@ -85,4 +85,4 @@ return [
8585
| 10.0.38-MariaDB-1~xenial |
8686
+--------------------------+
8787
```
88-
{: .no-copy}
88+
{: .no-copy}

guides/v2.1/cloud/docker/docker-development-debug.md

Lines changed: 33 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -18,29 +18,43 @@ If you use Microsoft Windows, take the following steps before continuing:
1818

1919
## Enable Xdebug
2020

21-
To enable Xdebug, you must configure your `docker-compose.yaml` file at the time you configure your local workstation to [Launch Docker]({{ page.baseurl }}/cloud/docker/docker-config.html).
21+
To enable Xdebug for your project, add `xdebug` to the `runtime:extensions` section of the `.magento.app.yaml` file.
2222

2323
```yaml
24-
generic:
25-
image: alpine
26-
environment:
27-
- PHP_MEMORY_LIMIT=2048M
28-
- DEBUG=false
29-
- ENABLE_SENDMAIL=false
30-
- UPLOAD_MAX_FILESIZE=64M
31-
- MAGENTO_ROOT=/app
32-
- PHP_ENABLE_XDEBUG=false
33-
- PHP_IDE_CONFIG=serverName=magento_cloud_docker
34-
- XDEBUG_CONFIG=remote_host=host.docker.internal
35-
env_file:
36-
- ./docker/config.env
24+
runtime:
25+
extensions:
26+
- redis
27+
- xsl
28+
- json
29+
- blackfire
30+
- newrelic
31+
- xdebug
3732
```
3833
39-
You can change any Xdebug configuration using the`XDEBUG_CONFIG` option. For example, to change the `xdebug.remote_port` option:
34+
## Configure Xdebug
4035
41-
```yaml
42-
XDEBUG_CONFIG='remote_host=host.docker.internal remote_port=9002'
43-
```
36+
1. Rebuild the `docker-compose.yml` file by continuing to configure your local workstation to [launch the Docker environment]({{ page.baseurl }}/cloud/docker/docker-config.html). The following is an excerpt from the `docker-compose.yml` file that shows Docker global variables.
37+
38+
```yaml
39+
generic:
40+
image: alpine
41+
environment:
42+
- PHP_MEMORY_LIMIT=2048M
43+
- UPLOAD_MAX_FILESIZE=64M
44+
- MAGENTO_ROOT=/app
45+
- PHP_IDE_CONFIG=serverName=magento_cloud_docker
46+
- XDEBUG_CONFIG=remote_host=host.docker.internal
47+
- 'PHP_EXTENSIONS=bcmath bz2 calendar exif gd gettext intl mysqli pcntl pdo_mysql soap sockets sysvmsg sysvsem sysvshm opcache zip redis xsl xdebug'
48+
env_file:
49+
- ./.docker/config.env
50+
```
51+
{:.no-copy}
52+
53+
1. Change any Xdebug configuration using the`XDEBUG_CONFIG` option. For example, to change the `xdebug.remote_port` option:
54+
55+
```yaml
56+
XDEBUG_CONFIG='remote_host=host.docker.internal remote_port=9002'
57+
```
4458

4559
#### To configure PhpStorm to work with Xdebug:
4660

@@ -68,7 +82,7 @@ XDEBUG_CONFIG='remote_host=host.docker.internal remote_port=9002'
6882

6983
1. Click **Apply**.
7084

71-
## Using Xdebug
85+
## Use Xdebug
7286

7387
The following steps describe debugging web requests and CLI commands.
7488

0 commit comments

Comments
 (0)