You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2021/04/08 00:06:17 UTC

[GitHub] [apisix] moonming commented on a change in pull request #4003: docs: faq doc add use the FQDN address

moonming commented on a change in pull request #4003:
URL: https://github.com/apache/apisix/pull/4003#discussion_r609150699



##########
File path: docs/zh/latest/FAQ.md
##########
@@ -393,9 +393,33 @@ HTTP/1.1 200 OK
 ...
 
 # uri 匹配失败
-curl http://127.0.0.1:9080/12ab -i
+$ curl http://127.0.0.1:9080/12ab -i
 HTTP/1.1 404 Not Found
 ...
 ```
 
 在 route 中,我们可以通过 `uri` 结合 `vars` 字段来实现更多的条件匹配,`vars` 的更多使用细节请参考 [lua-resty-expr](https://github.com/api7/lua-resty-expr)。
+
+## upstream 节点是否支持配置 `FQDN`(Fully Qualified Domain Name) 地址
+
+这是支持,下面是一个 `FQDN` 为 `localhost.localdomain.com` 的示例:

Review comment:
       Grammar is wrong

##########
File path: docs/zh/latest/FAQ.md
##########
@@ -393,9 +393,33 @@ HTTP/1.1 200 OK
 ...
 
 # uri 匹配失败
-curl http://127.0.0.1:9080/12ab -i
+$ curl http://127.0.0.1:9080/12ab -i
 HTTP/1.1 404 Not Found
 ...
 ```
 
 在 route 中,我们可以通过 `uri` 结合 `vars` 字段来实现更多的条件匹配,`vars` 的更多使用细节请参考 [lua-resty-expr](https://github.com/api7/lua-resty-expr)。
+
+## upstream 节点是否支持配置 `FQDN`(Fully Qualified Domain Name) 地址
+
+这是支持,下面是一个 `FQDN` 为 `localhost.localdomain.com` 的示例:
+
+```shell
+curl http://127.0.0.1:9080/apisix/admin/routes/1  -H 'X-API-KEY: edd1c9f034335f136f87ad84b625c8f1' -X PUT -d '
+{
+    "uri": "/hello",
+    "upstream": {
+        "type": "roundrobin",
+        "nodes": {
+            "localhost.localdomain.com:1980": 1
+        }
+    }
+}'
+```
+
+```shell
+# 测试请求
+$ curl http://127.0.0.1:9080/hello -i

Review comment:
       are you really test?




-- 
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.

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