tokers commented on code in PR #1018:
URL: 
https://github.com/apache/apisix-ingress-controller/pull/1018#discussion_r873525549


##########
docs/en/latest/practices/enable-authentication-and-restriction.md:
##########
@@ -27,36 +27,124 @@ Consumers are used for the authentication method 
controlled by Apache APISIX, if
 
 ## Attributes
 
-### Authentication
+### Authentication methods
 
-#### [`keyAuth`](https://apisix.apache.org/docs/apisix/plugins/key-auth/)
+#### `keyAuth`
 
-Consumers add their key either in a header `apikey` to authenticate their 
requests.
+Consumers add their key either in a header `apikey` to authenticate their 
requests. For more information about `keyAuth`, please refer to [APISIX 
jwt-auth](https://apisix.apache.org/docs/apisix/plugins/key-auth/).
+
+<details>
+  <summary>keyAuth yaml configure</summary>
 
 ```yaml
-keyAuth:
-  value:
-    key: ${key}
+apiVersion: apisix.apache.org/v2beta3
+kind: ApisixConsumer
+metadata:
+  name: ${name}
+spec:
+  authParameter:
+    keyAuth:
+      value:
+        key: ${key} #required
+```
+
+</details>
+
+#### `basicAuth`
+
+Consumers add their key either in a header `Authentication` to authenticate 
their requests.For more information about `basicAuth`, please refer to [APISIX 
basic-auth](https://apisix.apache.org/docs/apisix/plugins/basic-auth/).
+
+<details>
+  <summary>basicAuth yaml configure</summary>
+
+```yaml
+apiVersion: apisix.apache.org/v2beta3
+kind: ApisixConsumer
+metadata:
+  name: ${name}
+spec:
+  authParameter:
+    basicAuth:
+      value:
+        username: ${username} #required
+        password: ${password} #required
+```
+
+</details>

Review Comment:
   I think after each example, we need to give users a tip about using the 
`valueRef` field to reference a K8s Secret object so that we can avoid the 
hardcoded sensitive data in the ApisixConsumer object.



##########
docs/en/latest/practices/enable-authentication-and-restriction.md:
##########
@@ -27,36 +27,124 @@ Consumers are used for the authentication method 
controlled by Apache APISIX, if
 
 ## Attributes
 
-### Authentication
+### Authentication methods
 
-#### [`keyAuth`](https://apisix.apache.org/docs/apisix/plugins/key-auth/)
+#### `keyAuth`
 
-Consumers add their key either in a header `apikey` to authenticate their 
requests.
+Consumers add their key either in a header `apikey` to authenticate their 
requests. For more information about `keyAuth`, please refer to [APISIX 
jwt-auth](https://apisix.apache.org/docs/apisix/plugins/key-auth/).
+
+<details>
+  <summary>keyAuth yaml configure</summary>
 
 ```yaml
-keyAuth:
-  value:
-    key: ${key}
+apiVersion: apisix.apache.org/v2beta3
+kind: ApisixConsumer
+metadata:
+  name: ${name}
+spec:
+  authParameter:
+    keyAuth:
+      value:
+        key: ${key} #required
+```
+
+</details>
+
+#### `basicAuth`
+
+Consumers add their key either in a header `Authentication` to authenticate 
their requests.For more information about `basicAuth`, please refer to [APISIX 
basic-auth](https://apisix.apache.org/docs/apisix/plugins/basic-auth/).
+
+<details>
+  <summary>basicAuth yaml configure</summary>
+
+```yaml
+apiVersion: apisix.apache.org/v2beta3
+kind: ApisixConsumer
+metadata:
+  name: ${name}
+spec:
+  authParameter:
+    basicAuth:
+      value:
+        username: ${username} #required
+        password: ${password} #required
+```
+
+</details>
+
+#### `jwtAuth`

Review Comment:
   ```suggestion
   #### JWT Auth
   
   ```



##########
docs/en/latest/practices/enable-authentication-and-restriction.md:
##########
@@ -27,36 +27,124 @@ Consumers are used for the authentication method 
controlled by Apache APISIX, if
 
 ## Attributes
 
-### Authentication
+### Authentication methods
 
-#### [`keyAuth`](https://apisix.apache.org/docs/apisix/plugins/key-auth/)
+#### `keyAuth`
 
-Consumers add their key either in a header `apikey` to authenticate their 
requests.
+Consumers add their key either in a header `apikey` to authenticate their 
requests. For more information about `keyAuth`, please refer to [APISIX 
jwt-auth](https://apisix.apache.org/docs/apisix/plugins/key-auth/).
+
+<details>
+  <summary>keyAuth yaml configure</summary>
 
 ```yaml
-keyAuth:
-  value:
-    key: ${key}
+apiVersion: apisix.apache.org/v2beta3
+kind: ApisixConsumer
+metadata:
+  name: ${name}
+spec:
+  authParameter:
+    keyAuth:
+      value:
+        key: ${key} #required
+```
+
+</details>
+
+#### `basicAuth`

Review Comment:
   ```suggestion
   #### Basic Auth
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@apisix.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to