Skip to content

Commit

Permalink
apply doc suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
Revolyssup committed Apr 2, 2024
1 parent 07afe44 commit ec03ce8
Show file tree
Hide file tree
Showing 226 changed files with 229 additions and 347 deletions.
3 changes: 1 addition & 2 deletions docs/en/latest/FAQ.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,7 @@ Let's take an example query `foo.com/product/index.html?id=204&page=2` and consi
There are two different ways to achieve this in Apache APISIX:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/admin-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,7 @@ By default, the Admin API checks for references between resources and will refus
You can make a force deletion by adding the request argument `force=true` to the delete request, for example:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/batch-processor.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@ The batch processor's configuration will be set inside the plugin's configuratio
For example:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/benchmark.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,7 @@ The result of Flame Graph:
And if you want to run the benchmark test in your machine, you should run another Nginx to listen 80 port.

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/certificate.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,7 @@ The following is an example of configuring an SSL certificate with a single SNI
Create an SSL object with the certificate and key valid for the SNI:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/debug-function.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,7 @@ In the response header of the request, through the response header of `X-APISIX-
## Example

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/discovery.md
Original file line number Diff line number Diff line change
Expand Up @@ -187,8 +187,7 @@ discovery:
Here is an example of routing a request with a URL of "/user/*" to a service which named "user-service" and use eureka discovery client in the registry :

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/discovery/consul.md
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,7 @@ To avoid confusion, use the full consul key url path as service name in practice
Here is an example of routing a request with a URL of "/*" to a service which named "service_a" and use consul discovery client in the registry :

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/discovery/consul_kv.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,7 @@ To avoid confusion, use the full consul key url path as service name in practice
Here is an example of routing a request with a URL of "/*" to a service which named "http://127.0.0.1:8500/v1/kv/upstreams/webpages/" and use consul_kv discovery client in the registry :

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/discovery/nacos.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ discovery:
Here is an example of routing a request with an URI of "/nacos/*" to a service which named "http://192.168.33.1:8848/nacos/v1/ns/instance/list?serviceName=APISIX-NACOS" and use nacos discovery client in the registry:
:::note
You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/grpc-proxy.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@ Here's an example, to proxying gRPC service by specified route:
* the grpc server example:[grpc_server_example](https://github.com/api7/grpc_server_example)

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/mtls.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,7 @@ Please replace the following certificate paths and domain name with your real on
* Note: The same CA certificate as the server needs to be used *

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugin-develop.md
Original file line number Diff line number Diff line change
Expand Up @@ -371,8 +371,7 @@ end
Write the logic of the plugin in the corresponding phase. There are two parameters `conf` and `ctx` in the phase method, take the `limit-conn` plugin configuration as an example.

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/api-breaker.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,7 @@ In an unhealthy state, if the Upstream service responds with a status code from
The example below shows how you can configure the Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/authz-casbin.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,7 @@ You can enable the Plugin on a Route by either using the model/policy file paths
The example below shows setting up Casbin authentication from your model/policy configuration file:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/authz-casdoor.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,7 @@ Once this is done, the user is redirected to the original URL they wanted to vis
To remove the `authz-casdoor` Plugin, you can delete the corresponding JSON configuration from the Plugin configuration. APISIX will automatically reload and you do not have to restart for this to take effect.

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/authz-keycloak.md
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,7 @@ curl --location --request POST 'http://127.0.0.1:9080/api/token' \
The example below shows how you can enable the `authz-keycloak` Plugin on a specific Route. `${realm}` represents the realm name in Keycloak.

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/aws-lambda.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ This Plugin supports authorization via AWS API key and AWS IAM secrets.
The example below shows how you can configure the Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/azure-functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ The relative order priority is as follows:
To add a new master API key, you can make a request to `/apisix/admin/plugin_metadata` with the required metadata as shown below:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/basic-auth.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ For Route:
To enable the Plugin, you have to create a Consumer object with the authentication configuration:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/batch-requests.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,7 @@ plugins:
By default, the maximum body size that can be sent to `/apisix/batch-requests` can't be larger than 1 MiB. You can change this configuration of the Plugin through the endpoint `apisix/admin/plugin_metadata/batch-requests`:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/body-transformer.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ Use cases:
You can enable the Plugin on a specific Route as shown below:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/brotli.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,7 @@ If the upstream is returning a compressed response, then the Brotli plugin won't
The example below enables the `brotli` Plugin on the specified Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/cas-auth.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ to do authentication, from the SP (service provider) perspective.
You can enable the Plugin on a specific Route as shown below:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/chaitin-waf.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,7 @@ The response headers are listed below:
An example configuration is as follows.

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/clickhouse-logger.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,7 @@ Configuring the Plugin metadata is global in scope. This means that it will take
The example below shows how you can configure through the Admin API:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/client-control.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ This Plugin requires APISIX to run on APISIX-Runtime. See [apisix-build-tools](h
The example below enables the Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/consumer-restriction.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ The example below shows how you can use the `consumer-restriction` Plugin on a R
You can first create two consumers `jack1` and `jack2`:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/cors.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,7 @@ So, you have to set the CORS headers first, then access the `domain-B.com` URL,
You can enable the Plugin on a specific Route or Service:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/csrf.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,7 @@ NOTE: `encrypt_fields = {"key"}` is also defined in the schema, which means that
The example below shows how you can enable the Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/datadog.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,7 @@ See [defining tags](https://docs.datadoghq.com/getting_started/tagging/#defining
By default, the Plugin expects the DogStatsD service to be available at `127.0.0.1:8125`. If you want to change this, you can update the Plugin metadata as shown below:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/degraphql.md
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,7 @@ In the GET request, the variables are passed in the query string.
To remove the `degraphql` Plugin, you can delete the corresponding JSON configuration from the Plugin configuration. APISIX will automatically reload and you do not have to restart for this to take effect.

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/dubbo-proxy.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,7 @@ plugins:
Now, when APISIX is reloaded, you can add it to a specific Route as shown below:
:::note
You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/echo.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,7 @@ At least one of `before_body`, `body`, and `after_body` must be specified.
The example below shows how you can enable the `echo` Plugin for a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/elasticsearch-logger.md
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,7 @@ This Plugin supports using batch processors to aggregate and process entries (lo
The example below shows a complete configuration of the Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/error-log-logger.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,7 @@ Once you have enabled the Plugin, you can configure it through the Plugin metada
You can set the TCP server address by configuring the Plugin metadata as shown below:
:::note
You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/ext-plugin-post-resp.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,7 @@ Execution of External Plugins will affect the response of the current request.
The example below enables the `ext-plugin-post-resp` Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/ext-plugin-pre-req.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@ Execution of External Plugins will affect the behavior of the current request.
The example below enables the `ext-plugin-pre-req` Plugin on a specific Route:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/fault-injection.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@ This means that the relationship between the first two expressions is AND, and t
You can enable the `fault-injection` Plugin on a specific Route as shown below:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
3 changes: 1 addition & 2 deletions docs/en/latest/plugins/file-logger.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,8 +108,7 @@ You can also set the format of the logs by configuring the Plugin metadata. The
The example below shows how you can configure through the Admin API:

:::note

You can get the get the admin_key from config.yaml like this.
You can fetch the `admin_key` from `config.yaml` and save to an environment variable with the following command:

```bash
admin_key=$(yq '.deployment.admin.admin_key[0].key' conf/config.yaml | sed 's/"//g')
Expand Down
Loading

0 comments on commit ec03ce8

Please sign in to comment.