Skip to content
This repository was archived by the owner on Nov 19, 2024. It is now read-only.

Commit 4a5173e

Browse files
authored
Merge branch 'master' into patch-100
2 parents 3ad0adf + 46dddbc commit 4a5173e

File tree

24 files changed

+365
-225
lines changed

24 files changed

+365
-225
lines changed

.github/workflows/linter.yml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,11 @@ name: Lint Code Base
1111
# https://help.github.com/en/articles/workflow-syntax-for-github-actions
1212
#
1313

14-
#############################
15-
# Start the job on all push #
16-
#############################
14+
###################################
15+
# Start the job on a pull request #
16+
###################################
1717
on:
18-
pull_request:
19-
branches:
20-
- master
21-
- 2.*-develop
18+
pull_request
2219

2320
###############
2421
# Set the Job #
@@ -50,4 +47,5 @@ jobs:
5047
VALIDATE_ALL_CODEBASE: false
5148
DEFAULT_BRANCH: master
5249
VALIDATE_HTML: false
50+
VALIDATE_OPENAPI: false
5351
MARKDOWN_CONFIG_FILE: .markdownlint.json

.github/workflows/main.yml

Lines changed: 0 additions & 22 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ This site is built by [Jekyll](https://jekyllrb.com/), which is an open-source t
1515
You can build the site locally in the following ways:
1616

1717
- [Installing the project dependencies locally](#build-locally) (Mac, Linux)
18-
- [Using Docker (docker-compose)](#docker-docker-compose) (Mac, Linux, Windows)
18+
- [Using Docker (docker-compose)](https://github.com/magento/devdocs/wiki/Build-DevDocs-with-Docker) (Mac, Linux, Windows)
1919
- [Using a Vagrant virtual machine](https://github.com/magento-devdocs/vagrant-for-magento-devdocs) (Mac, Linux, Windows)
2020
- [Build DevDocs in Windows](https://github.com/magento/devdocs/wiki/Build-DevDocs-in-Windows) (Windows 7 & 10)
2121
- [Building older versions of the documentation](https://github.com/magento/devdocs/wiki/Build-DevDocs-with-Docker)

_plugins/debug/site_post_render.rb

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# frozen_string_literal: true
2+
3+
# Copyright © Magento, Inc. All rights reserved.
4+
# See COPYING.txt for license details.
5+
6+
# To enable this plugin, add to your '_config.local.yml' the following:
7+
#
8+
# debug: site_post_render
9+
#
10+
# This plugin runs an IRB session (https://github.com/ruby/irb) of a Jekyll application in a serving mode when it's at a state after rendering the whole site, but before writing any files.
11+
# See the ":site, :post_render" hook: https://jekyllrb.com/docs/plugins/hooks/
12+
# Available objects to explore are 'site' and 'payload'.
13+
#
14+
# Several helpful methods (to use a method, chain to an object such as 'site.methods', 'payload.keys'):
15+
# - '.methods.sort'
16+
# - '.instance_variables.sort'
17+
# - '.keys.sort'
18+
#
19+
# Examples:
20+
#
21+
# To view available configuration data of the site
22+
# > payload.site.keys
23+
#
24+
# To view the number of pages:
25+
# > payload.site.pages.count
26+
#
27+
# To find a page by path and view its data:
28+
# > page = payload.site.pages.select { |page| page.path == 'cloud/env/variables-build.md' }[0]
29+
# > page.data
30+
#
31+
# To exit from the IRB session:
32+
# > exit!
33+
#
34+
Jekyll::Hooks.register :site, :post_render do |site, payload|
35+
next unless site.config['serving']
36+
37+
# rubocop:disable Lint/Debugger
38+
binding.irb if site.config['debug'] == 'site_post_render'
39+
# rubocop:enable Lint/Debugger
40+
end

_plugins/debug/site_pre_render.rb

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# frozen_string_literal: true
2+
3+
# Copyright © Magento, Inc. All rights reserved.
4+
# See COPYING.txt for license details.
5+
6+
# To enable this plugin, add to your '_config.local.yml' the following:
7+
#
8+
# debug: site_pre_render
9+
#
10+
# This plugin runs an IRB session (https://github.com/ruby/irb) of a Jekyll application in a serving mode when it's at a state just before rendering the whole site.
11+
# See the ":site, :pre_render" hook: https://jekyllrb.com/docs/plugins/hooks/
12+
# Available objects to explore are 'site' and 'payload'.
13+
#
14+
# Several helpful methods (to use a method, chain to an object such as 'site.methods', 'payload.keys'):
15+
# - '.methods.sort'
16+
# - '.instance_variables.sort'
17+
# - '.keys.sort'
18+
#
19+
# Examples:
20+
#
21+
# To view available configuration data of the site
22+
# > payload.site.keys
23+
#
24+
# To view the number of pages:
25+
# > payload.site.pages.count
26+
#
27+
# To find a page by path and view its data:
28+
# > page = payload.site.pages.select { |page| page.path == 'cloud/env/variables-build.md' }[0]
29+
# > page.data
30+
#
31+
# To exit from the IRB session:
32+
# > exit!
33+
#
34+
Jekyll::Hooks.register :site, :pre_render do |site, payload|
35+
next unless site.config['serving']
36+
37+
# rubocop:disable Lint/Debugger
38+
binding.irb if site.config['debug'] == 'site_pre_render'
39+
# rubocop:enable Lint/Debugger
40+
end

docker-compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: '3.6'
22

33
services:
44
jekyll:
5-
image: jekyll/jekyll:latest
5+
image: jekyll/jekyll:3.8.6
66
command: jekyll serve --watch --incremental --open-url --livereload
77
ports:
88
- 4000:4000

src/_data/toc/configuration-guide.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -353,6 +353,9 @@ pages:
353353
- label: Set up optional database replication
354354
url: /config-guide/multi-master/multi-master_slavedb.html
355355

356+
- label: Revert from a split database to a single database
357+
url: /config-guide/revert-split-database.html
358+
356359
- label: Custom Logging
357360
url: /config-guide/log/log-intro.html
358361
children:

src/_includes/cloud/enable-ssh.md

Lines changed: 38 additions & 82 deletions
Original file line numberDiff line numberDiff line change
@@ -15,89 +15,31 @@ For more information on SSH keys, see the following:
1515

1616
## Locate an existing SSH key pair {#existing}
1717

18-
An existing SSH key pair is typically located in the `.ssh` subdirectory of the user's home directory. This folder is hidden and may not display in the file manager or finder unless configured to display hidden files and folders.
19-
20-
You can quickly verify if you have SSH keys by entering commands using terminal access.
21-
22-
To check for SSH keys, enter the following command:
23-
24-
```bash
25-
ls ~/.ssh
26-
```
27-
28-
If you have SSH keys, a directory listing is displayed similar to the following:
29-
30-
```terminal
31-
id_rsa id_rsa.pub known_hosts
32-
```
33-
34-
If you do not have SSH keys, you need to generate the keys for adding to your Magento ECE account and GitHub account. See [Create a new SSH key pair](#ssh-create-new-key-pair).
35-
36-
If you already have SSH keys, continue to:
37-
38-
- [Add a public SSH key to your Magento account](#ssh-add-to-account) section
39-
- [Add your SSH key to your GitHub account](https://help.github.com/articles/adding-a-new-ssh-key-to-your-github-account/)
40-
41-
## Create a new SSH key pair {#ssh-create-new-key-pair}
42-
43-
Use the `ssh-keygen` command to create an SSH key pair. `ssh-keygen` is typically installed on Linux systems.
18+
An existing SSH key pair is typically located in the `.ssh` subdirectory of the user home directory. This folder is hidden and may not display in the File Manager or Finder if your system is not configured to display hidden files and folders.
4419

4520
{:.procedure}
46-
To create an SSH key pair:
21+
To check for SSH keys:
4722

48-
1. The command syntax follows, entering the email used for your GitHub account:
23+
1. In the terminal, list the contents of your SSH directory.
4924

5025
```bash
51-
ssh-keygen -t rsa
26+
ls ~/.ssh
5227
```
5328

54-
GitHub also uses the key length `-b 4096` in the command. Follow the prompts to complete the key.
55-
56-
1. When prompted to "Enter a file in which to save the key," press **Enter** to save the file to the default location. The prompt displays the location.
57-
58-
1. When prompted to enter a secure passphrase, enter a phrase to use like a password. Make note of this passphrase. You may be requested to enter it depending on tasks you complete using a terminal during development.
29+
1. Review the output.
5930

60-
1. After creating the SSH key pair, start the ssh-agent:
31+
If you have SSH keys, a directory listing is displayed similar to the following:
6132

62-
For Mac or Linux:
63-
64-
```bash
65-
eval "$(ssh-agent -s)"
33+
```terminal
34+
id_rsa id_rsa.pub known_hosts
6635
```
6736

68-
For Mac, you can edit the `~/.ssh/config` file to automatically load keys into the ssh-agent and store passphrases in your keychain.
69-
70-
```conf
71-
Host *
72-
AddKeysToAgent yes
73-
UseKeychain yes
74-
IdentityFile ~/.ssh/id_rsa
75-
```
37+
If the directory does not exist or has no SSH key files, you must generate at least one SSH key and add it to your GitHub account. For instructions, see [Generate a new SSH key](https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent) in the GitHub documentation.
7638

77-
{:.bs-callout-info}
78-
You can specify multiple SSH keys by adding multiple `IdentityFile` entries to your configuration.
39+
If you have at least one SSH key in your directory, add the key to your Magento and GitHub accounts:
7940

80-
For Windows:
81-
82-
```shell
83-
eval $(ssh-agent -s)
84-
```
85-
86-
1. Add the SSH key to the ssh-agent. If you used a different name for the key file name, replace `id_rsa` with that file name.
87-
88-
For Mac:
89-
90-
```bash
91-
ssh-add -K ~/.ssh/id_rsa
92-
```
93-
94-
For Windows or Linux:
95-
96-
```shell
97-
ssh-add ~/.ssh/id_rsa
98-
```
99-
100-
1. [Add your SSH key to your GitHub account.](https://help.github.com/articles/adding-a-new-ssh-key-to-your-github-account/) The instructions include Mac, Windows, and Linux.
41+
- [Add an SSH key to your GitHub account](https://help.github.com/articles/adding-a-new-ssh-key-to-your-github-account/)
42+
- [Add your public SSH key to your Magento account](#ssh-add-to-account)
10143

10244
### Test the SSH keys {#test}
10345

@@ -120,13 +62,14 @@ You can add SSH keys to your account in any of the following ways:
12062
- Using the [{{site.data.var.ece}} CLI](#add-key-cli)
12163
- Using the [{{site.data.var.ece}} Web Interface](#add-key-web)
12264

123-
### Add a key using the CLI {#add-key-cli}
65+
### Add your SSH key using the CLI {#add-key-cli}
12466

12567
{:.procedure}
12668
To add an SSH key using the CLI:
12769

12870
1. Open a terminal application on your local workstation.
129-
1. If you haven't done so already, log in (or switch to) the [Magento file system owner]({{ site.baseurl }}/cloud/before/before-workspace-file-sys-owner.html) to the server on which your SSH keys are located.
71+
72+
1. If you have not done so already, log in (or switch to) the [Magento file system owner]({{ site.baseurl }}/cloud/before/before-workspace-file-sys-owner.html) to the server on which your SSH keys are located.
13073

13174
1. Log in to your project:
13275

@@ -140,30 +83,43 @@ To add an SSH key using the CLI:
14083
magento-cloud ssh-key:add ~/.ssh/id_rsa.pub
14184
```
14285

143-
### Add a key using the Project Web Interface {#add-key-web}
86+
{:.bs-callout-tip}
87+
You can list and delete SSH keys using the Magento Cloud CLI commands `ssh-key:list` and `ssh-key:delete`.
14488

145-
You will select and add your SSH public key to each environment in your account.
89+
### Add your SSH key using the Project Web Interface {#add-key-web}
90+
91+
You must add your SSH public key to your account. After you add the key, you must redeploy all active environments on your account to install the key.
14692

14793
- Starter: Add to Master (Production) and any environments you create by branching from Master
148-
- Pro: Add the key to Staging, Production, and Integration environments
94+
- Pro: Add the key to the Staging, Production, and Integration environments
14995

15096
{:.procedure}
151-
To add an SSH key using the Project Web Interface:
97+
To add an SSH key using the Project Web interface:
98+
99+
1. Get your public key.
152100

153-
1. Copy your SSH public key to the clipboard.
101+
- In the terminal, navigate to the `~/.ssh` directory.
154102

155-
If you do not already have SSH keys on that machine, see [GitHub documentation](https://help.github.com/articles/generating-an-ssh-key) to create them.
103+
- Copy the contents of the public key file `~/.ssh/<keyname>.pub` to the clipboard.
104+
105+
If there are no SSH key files in the directory, you must create one. See [Generate a new SSH key](https://docs.github.com/en/free-pro-team@latest/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent) in the GitHub documentation.
156106

157107
1. Login and access your project through the [Project Web Interface](https://accounts.magento.cloud).
158-
1. In your selected branch, an icon displays if you do not have an SSH key added.
108+
109+
1. In your project, look for the **No SSH key** icon to the right of the command field. This icon is visible when the project does not contain an SSH key.
159110

160111
![No SSH key]({{ site.baseurl }}/common/images/cloud/cloud_ssh-key-install.png)
161112

162-
1. Copy and paste the content of your public SSH key in the screen.
113+
1. Click the icon to add the key.
114+
115+
- Copy and paste the content of your public SSH key in the **Public key** field.
116+
117+
![Add SSH key]({{ site.baseurl }}/common/images/cloud/cloud_ssh-key-add.png)
163118

164-
![Add SSH key]({{ site.baseurl }}/common/images/cloud/cloud_ssh-key-add.png)
119+
- Follow the prompts on your screen to complete the task.
165120

166-
1. Follow the prompts on your screen to complete the task.
121+
{:.bs-callout-tip}
122+
You can view and manage the SSH keys on your account in _Account settings_. In the upper right corner of the Project Web interface, click **your-user-name** > **Account Settings**.
167123

168124
## Set global Git variables
169125

src/cloud/cdn/cloud-vcl-custom-snippets.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,9 @@ You can create and manage custom VCL snippets from the Magento Admin UI or by us
4545

4646
- [Magento Admin UI](#manage-custom-vcl-snippets-from-the-magento-admin-ui)—We recommend using the Magento Admin UI to manage custom VCL snippets because it automates the process to validate and upload the custom snippet and apply your changes to the Fastly service configuration. Additionally, you can view and edit the custom VCL snippets added to the Fastly service configuration from the Admin UI.
4747

48+
{:.bs-callout-info}
49+
You must use the Fastly API to [delete custom VCL snippets](https://devdocs.magento.com/cloud/cdn/cloud-vcl-custom-snippets.html#manage-vcl), or you can delete the contents of the snippet in the Magento Admin UI and upload an empty snippet. See [Delete a custom snippet](https://devdocs.magento.com/cloud/cdn/fastly-vcl-badreferer.html#delete-the-custom-vcl-snippet).
50+
4851
- [Fastly API](#manage-custom-vcl-snippets-using-the-api)—Manage custom VCL snippets using the API if you cannot access the Magento Admin UI. For example, if the site is down and you need to troubleshoot the Fastly service configuration or add a custom VCL snippet. Additionally, some operations can only be completed using the API, for example reactivating an older VCL version or viewing all the VCL snippets included in a specified the VCL version. See [API quick reference for VCL snippets](#manage-vcl).
4952

5053
### Example VCL snippet code {#vcl-curl}

src/cloud/docker/docker-containers-service.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,8 @@ The Test container, based on the [magento/magento-cloud-docker-php][php-cloud] D
218218
**Docker base image**: [magento/magento-cloud-docker-nginx:1.19-1.2.0][tls]<br>
219219
**Ports**: `443` (default), `8080:80` (Varnish bypass)<br/>
220220

221+
By default, the TLS container is included with the Docker Compose configuration. However, you can generate a configuration without TLS by adding the `--no-tls` option to the `ece-docker build:compose` command.
222+
221223
The TLS termination proxy container facilitates the Varnish SSL termination over HTTPS.
222224

223225
- The default port for TLS communication is `443`.
@@ -267,6 +269,11 @@ docker-compose exec varnish varnishadm ban req.url '~' '.'
267269

268270
The Web container uses NGINX to handle web requests after TLS and Varnish. This container passes all requests to the FPM container to serve the PHP code. See [Request flow]({{site.baseurl}}/cloud/docker/docker-containers.html#request-flow).
269271

272+
This container provides two NGINX configuration options for building the Docker configuration:
273+
274+
- `--nginx-worker-processes` to set the number of worker processes for NGINX. The default is `1`.
275+
- `--nginx-worker-connections` to set the maximum number of connections that each worker process can handle simultaneously. The default is `1024`.
276+
270277
The NGINX configuration for this container is the standard Magento [nginx config], which includes the configuration to auto-generate NGINX certificates for the container. You can customize the NGINX configuration by mounting a new configuration file using a volume.
271278

272279
{:.procedure}

0 commit comments

Comments
 (0)