Add shenyu-nginx documentation (#745)

* Add shenyu-nginx documentation

* Add shenyu-nginx documentation

* Add shenyu-nginx documentation

* Add shenyu-nginx documentation

* Add shenyu-nginx documentation
diff --git a/docs/deployment/deployment-cluster.md b/docs/deployment/deployment-cluster.md
index fe4afa4..18ea2d5 100644
--- a/docs/deployment/deployment-cluster.md
+++ b/docs/deployment/deployment-cluster.md
@@ -86,3 +86,161 @@
 ```
 
 * verify nginx, looking at your `ShenYu Bootstrap` log or `Nginx` log, Where will the verification request go.
+
+Apache ShenYu Nginx Module
+
+---
+
+This module provided SDK to watch available ShenYu instance list as upstream nodes by Service Register Center for OpenResty.
+1. [ETCD](#greeting-etcd) (Supported)
+2. [Nacos](#greeting-nacos) (Supported)
+3. [Zookeeper](#greeting-zookeeper) (Supported)
+4. Consul (TODO)
+
+In the cluster mode, Apache ShenYu supports the deployment of multiple ShenYu instances, which may have new instances joining or leaving at any time.
+Hence, Apache ShenYu introduces Service Discovery modules to help client to detect the available instances.
+Currently, Apache ShenYu Bootstrap already supports Apache Zookeeper, Nacos, Etcd, and consul. Client or LoadBalancer can get the available ShenYu instances by those Service register center.
+
+## Getting Started
+
+- Prerequisite:
+1. Luarocks
+2. OpenResty
+
+### Build from source
+
+The first, clone the source from GitHub.
+
+```
+git clone https://github.com/apache/shenyu-nginx
+```
+
+Then, build from source and install.
+
+```
+cd shenyu-nginx
+luarocks make rockspec/shenyu-nginx-main-0.rockspec
+```
+
+### Greeting ETCD
+
+Modify the Nginx configure, create and initialize the ShenYu Register to connect to the target register center.
+The module will fetch the all of ShenYu instances which are registered to Etcd in the same cluster.
+It works like Etcd client to watch(based on long polling) ShenYu instance lists.
+
+Here is an example for Etcd.
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.etcd")
+    register.init({
+        balancer_type = "chash",
+        etcd_base_url = "http://127.0.0.1:2379",
+    })
+}
+```
+
+1. `balancer_type` specify the balancer. It has supported `chash` and `round robin`.
+2. `etcd_base_url` specify the Etcd server.(Currently, authentication is not supported.)
+
+Add an `upstream block` for ShenYu and enable to update upstream servers dynamically. This case will synchronize the ShenYu instance list with register center.
+And then pick one up for handling the request.
+
+```
+upstream shenyu {
+    server 0.0.0.1; -- bad 
+    
+    balancer_by_lua_block {
+        require("shenyu.register.etcd").pick_and_set_peer()
+    }
+}
+```
+
+Finally, restart OpenResty.
+
+```
+openresty -s reload
+```
+
+Here is a completed [example](https://github.com/apache/shenyu-nginx/blob/main/example/etcd/nginx.conf) working with ETCD.
+
+### Greeting Nacos
+
+Modify the Nginx configure, create and initialize the ShenYu Register to connect to target register center.  Here is an example for Nacos.
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.nacos")
+    register.init({
+        shenyu_storage = ngx.shared.shenyu_storage,
+        balancer_type = "chash",
+        nacos_base_url = "http://127.0.0.1:8848",
+        username = "nacos",
+        password = "naocs",
+    })
+}
+```
+
+1. `balancer_type` specify the balancer. It has supported `chash` and `round robin`.
+2. `nacos_base_url` specify the Nacos server address.
+3. `username` specify the username to log in Nacos. (it is only required when Nacos auth enable)
+4. `password` specify the password to log in Nacos.
+
+Modify the `upstream` to enable to update upstream servers dynamically. This case will synchronize the ShenYu instance list with register center.
+And then pick one up for handling the request.
+
+```
+upstream shenyu {
+    server 0.0.0.1; -- bad 
+    
+    balancer_by_lua_block {
+        require("shenyu.register.nacos").pick_and_set_peer()
+    }
+}
+```
+
+Finally, restart OpenResty.
+
+```
+openresty -s reload
+```
+
+Here is a completed [example](https://github.com/apache/shenyu-nginx/blob/main/example/nacos/nginx.conf) working with Nacos.
+
+## Greeting Zookeeper
+
+Modify the Nginx configure, create and initialize the ShenYu register to connect to target register center.
+Listen for changes to the node via the zookeeper watch event. Here is an example of the zookeeper configuration.
+
+```
+init_worker_by_lua_block {
+        local register = require("shenyu.register.zookeeper")
+        register.init({
+           servers = {"127.0.0.1:2181","127.0.0.1:2182"},
+           shenyu_storage = ngx.shared.shenyu_storage,
+           balancer_type = "roundrobin"
+        });
+    }
+```
+
+1. `servers` zookeeper cluster address.
+2. ``balancer_type`` specify the balancer. It has supported `chash` and `round robin`.
+
+Modify the upstream to enable to update upstream servers dynamically. This case will synchronize the ShenYu instance list with register center. And then pick one up for handling the request.
+
+```
+ upstream shenyu {
+        server 0.0.0.1;
+        balancer_by_lua_block {
+            require("shenyu.register.zookeeper").pick_and_set_peer()
+        }
+    }
+```
+
+Finally, restart OpenResty.
+
+```
+openresty -s reload
+```
+
+Here is a completed [example](https://github.com/apache/shenyu-nginx/blob/main/example/zookeeper/nginx.conf) working with Zookeeper.
diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/deployment/deployment-cluster.md b/i18n/zh/docusaurus-plugin-content-docs/current/deployment/deployment-cluster.md
index 44e6999..516f327 100644
--- a/i18n/zh/docusaurus-plugin-content-docs/current/deployment/deployment-cluster.md
+++ b/i18n/zh/docusaurus-plugin-content-docs/current/deployment/deployment-cluster.md
@@ -84,3 +84,147 @@
 ```
 
 * 验证nginx配置是否生效,在`ShenYu Bootstrap`或者`Nginx`的日志文件中查看请求被分发到那台服务器上。
+
+
+### Apache Shenyu-nginx模块实现集群
+
+> 该模块提供SDK,用于通过注册中心为OpenResty自动监听Apache Shenyu可用的实例节点。
+>在集群模式下,Apache Shenyu支持部署多个Shenyu实例,随时可能有新的实例上线或下线。因此,Apache Shenyu引入了服务发现
+> OpenResty 模块来帮助客户端检测可用Shenyu实例。目前Apache Shenyu已经支持Zookeeper、Nacos、Etcd和Consul。Client或LoadBalancer
+> 可以通过这些Service注册中心获取可用的Shenyu实例。
+1. [Etcd](#Etcd开始)(支持)
+2. [Nacos](#Nacos开始)(支持)
+3. [Zookeeper](#Zookeeper开始)(支持)
+4. Consul(进行中)
+
+#### 入门
+
+* 先决条件
+1. Luarocks
+2. OpenResty
+
+#### 从源码构建
+
+首先,从GitHub clone源码。
+
+```
+git clone https://github.com/apache/shenyu-nginx
+```
+
+然后,从源代码构建并安装。
+
+```
+cd shenyu-nginx
+luarocks make rockspec/shenyu-nginx-main-0.rockspec
+```
+
+#### Etcd开始
+
+修改Nginx配置,创建并初始化Shenyu register模块,连接至目标注册中心。该模块将获取在同一个集群中注册到Etcd的
+所有Shenyu实例。它与Etcd客户端一样监视(基于长轮询)Shenyu实例列表。
+*Etcd示例:*
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.etcd")
+    register.init({
+        balancer_type = "chash",
+        etcd_base_url = "http://127.0.0.1:2379",
+    })
+}
+```
+
+1. `balancer_type`指定负载均衡模式。它支持`chash`和`round` `robin`。
+2. `etcd_base_url`指定 `Etcd` 服务器。(目前不支持身份验证)。
+
+最后,重启OpenResty。
+
+```
+openresty -s reload
+```
+
+这就是一个完整的Etcd的使用[示例](https://github.com/apache/shenyu-nginx/blob/main/example/etcd/nginx.conf) 。
+
+#### Nacos开始
+
+修改Nginx配置,创建并初始化Shenyu register模块,连接至目标注册中心。以下是Nacos的示例:
+
+**Nacos示例:**
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.nacos")
+    register.init({
+        shenyu_storage = ngx.shared.shenyu_storage,
+        balancer_type = "chash",
+        nacos_base_url = "http://127.0.0.1:8848",
+        username = "nacos",
+        password = "naocs",
+    })
+}
+```
+
+1. `balancer_type`指定负载均衡模式。它支持`chash`和`round` `robin`。
+2. `nacos_base_url`指定 `Nacos` 服务器地址。
+3. `username`指定登录 `Nacos` 的用户名。(仅在启用 Nacos auth 时才需要)
+4. `password`指定登录 `Nacos` 的密码。
+
+修改`upstream`启用动态更新shenyu实例列表。本案例将Shenyu实例列表与注册中心同步。
+
+```
+upstream shenyu {
+    server 0.0.0.1; -- bad 
+    
+    balancer_by_lua_block {
+        require("shenyu.register.nacos").pick_and_set_peer()
+    }
+}
+```
+
+最后,重启OpenResty。
+
+```
+openresty -s reload
+```
+
+这就是一个完整的Nacos的使用[example](https://github.com/apache/shenyu-nginx/blob/main/example/nacos/nginx.conf) 。
+
+#### Zookeeper开始
+
+修改Nginx配置,创建并初始化Shenyu register模块,连接目标注册中心。
+通过 zookeeper watch 事件监听Shenyu实例列表的变化。下面是 zookeeper 配置的示例。
+
+**Zookeeper示例:**
+
+```
+init_worker_by_lua_block {
+        local register = require("shenyu.register.zookeeper")
+        register.init({
+           servers = {"127.0.0.1:2181","127.0.0.1:2182"},
+           shenyu_storage = ngx.shared.shenyu_storage,
+           balancer_type = "roundrobin"
+        });
+    }
+```
+
+1. `servers` zookeeper 集群地址。
+2. `balancer_type`指定负载均衡模式。它支持chash和round robin。
+
+修改`upstream`启用动态更新Shenyu实例列表。本案例将Shenyu实例列表与注册中心同步。
+
+```
+upstream shenyu {
+        server 0.0.0.1;
+        balancer_by_lua_block {
+            require("shenyu.register.zookeeper").pick_and_set_peer()
+        }
+    }
+```
+
+最后,重启 OpenResty。
+
+```
+openresty -s reload
+```
+
+这是一个使用 Zookeeper的完整[示例](https://github.com/apache/incubator-shenyu-nginx/blob/main/example/zookeeper/nginx.conf) 。
diff --git a/i18n/zh/docusaurus-plugin-content-docs/version-2.5.0/deployment/deployment-cluster.md b/i18n/zh/docusaurus-plugin-content-docs/version-2.5.0/deployment/deployment-cluster.md
index d222d4b..0a00fdd 100644
--- a/i18n/zh/docusaurus-plugin-content-docs/version-2.5.0/deployment/deployment-cluster.md
+++ b/i18n/zh/docusaurus-plugin-content-docs/version-2.5.0/deployment/deployment-cluster.md
@@ -84,3 +84,146 @@
 ```
 
 * 验证nginx配置是否生效,在`ShenYu Bootstrap`或者`Nginx`的日志文件中查看请求被分发到那台服务器上。
+
+### Apache Shenyu-nginx模块实现集群
+
+> 该模块提供SDK,用于通过注册中心为OpenResty自动监听Apache Shenyu可用的实例节点。
+>在集群模式下,Apache Shenyu支持部署多个Shenyu实例,随时可能有新的实例上线或下线。因此,Apache Shenyu引入了服务发现
+> OpenResty 模块来帮助客户端检测可用Shenyu实例。目前Apache Shenyu已经支持Zookeeper、Nacos、Etcd和Consul。Client或LoadBalancer
+> 可以通过这些Service注册中心获取可用的Shenyu实例。
+1. [Etcd](#Etcd开始)(支持)
+2. [Nacos](#Nacos开始)(支持)
+3. [Zookeeper](#Zookeeper开始)(支持)
+4. Consul(进行中)
+
+#### 入门
+
+* 先决条件
+1. Luarocks
+2. OpenResty
+
+#### 从源码构建
+
+首先,从GitHub clone源码。
+
+```
+git clone https://github.com/apache/shenyu-nginx
+```
+
+然后,从源代码构建并安装。
+
+```
+cd shenyu-nginx
+luarocks make rockspec/shenyu-nginx-main-0.rockspec
+```
+
+#### Etcd开始
+
+修改Nginx配置,创建并初始化Shenyu register模块,连接至目标注册中心。该模块将获取在同一个集群中注册到Etcd的
+所有Shenyu实例。它与Etcd客户端一样监视(基于长轮询)Shenyu实例列表。
+*Etcd示例:*
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.etcd")
+    register.init({
+        balancer_type = "chash",
+        etcd_base_url = "http://127.0.0.1:2379",
+    })
+}
+```
+
+1. `balancer_type`指定负载均衡模式。它支持`chash`和`round` `robin`。
+2. `etcd_base_url`指定 `Etcd` 服务器。(目前不支持身份验证)。
+
+最后,重启OpenResty。
+
+```
+openresty -s reload
+```
+
+这就是一个完整的Etcd的使用[示例](https://github.com/apache/shenyu-nginx/blob/main/example/etcd/nginx.conf) 。
+
+#### Nacos开始
+
+修改Nginx配置,创建并初始化Shenyu register模块,连接至目标注册中心。以下是Nacos的示例:
+
+**Nacos示例:**
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.nacos")
+    register.init({
+        shenyu_storage = ngx.shared.shenyu_storage,
+        balancer_type = "chash",
+        nacos_base_url = "http://127.0.0.1:8848",
+        username = "nacos",
+        password = "naocs",
+    })
+}
+```
+
+1. `balancer_type`指定负载均衡模式。它支持`chash`和`round` `robin`。
+2. `nacos_base_url`指定 `Nacos` 服务器地址。
+3. `username`指定登录 `Nacos` 的用户名。(仅在启用 Nacos auth 时才需要)
+4. `password`指定登录 `Nacos` 的密码。
+
+修改`upstream`启用动态更新shenyu实例列表。本案例将Shenyu实例列表与注册中心同步。
+
+```
+upstream shenyu {
+    server 0.0.0.1; -- bad 
+    
+    balancer_by_lua_block {
+        require("shenyu.register.nacos").pick_and_set_peer()
+    }
+}
+```
+
+最后,重启OpenResty。
+
+```
+openresty -s reload
+```
+
+这就是一个完整的Nacos的使用[example](https://github.com/apache/shenyu-nginx/blob/main/example/nacos/nginx.conf) 。
+
+#### Zookeeper开始
+
+修改Nginx配置,创建并初始化Shenyu register模块,连接目标注册中心。
+通过 zookeeper watch 事件监听Shenyu实例列表的变化。下面是 zookeeper 配置的示例。
+
+**Zookeeper示例:**
+
+```
+init_worker_by_lua_block {
+        local register = require("shenyu.register.zookeeper")
+        register.init({
+           servers = {"127.0.0.1:2181","127.0.0.1:2182"},
+           shenyu_storage = ngx.shared.shenyu_storage,
+           balancer_type = "roundrobin"
+        });
+    }
+```
+
+1. `servers` zookeeper 集群地址。
+2. `balancer_type`指定负载均衡模式。它支持chash和round robin。
+
+修改`upstream`启用动态更新Shenyu实例列表。本案例将Shenyu实例列表与注册中心同步。
+
+```
+upstream shenyu {
+        server 0.0.0.1;
+        balancer_by_lua_block {
+            require("shenyu.register.zookeeper").pick_and_set_peer()
+        }
+    }
+```
+
+最后,重启 OpenResty。
+
+```
+openresty -s reload
+```
+
+这是一个使用 Zookeeper的完整[示例](https://github.com/apache/incubator-shenyu-nginx/blob/main/example/zookeeper/nginx.conf) 。
diff --git a/package.json b/package.json
index d06f06e..15a1732 100755
--- a/package.json
+++ b/package.json
@@ -25,12 +25,14 @@
     "@svgr/webpack": "^5.5.0",
     "clsx": "^1.1.1",
     "file-loader": "^6.2.0",
+    "n": "^9.0.0",
     "prism-react-renderer": "^1.2.1",
     "react": "^17.0.1",
     "react-dom": "^17.0.1",
     "react-icons": "^4.2.0",
     "swiper": "^7.0.1",
-    "url-loader": "^4.1.1"
+    "url-loader": "^4.1.1",
+    "yarn": "^1.22.19"
   },
   "browserslist": {
     "production": [
diff --git a/versioned_docs/version-2.5.0/deployment/deployment-cluster.md b/versioned_docs/version-2.5.0/deployment/deployment-cluster.md
index a055285..4d13f5a 100644
--- a/versioned_docs/version-2.5.0/deployment/deployment-cluster.md
+++ b/versioned_docs/version-2.5.0/deployment/deployment-cluster.md
@@ -86,3 +86,160 @@
 ```
 
 * verify nginx, looking at your `ShenYu Bootstrap` log or `Nginx` log, Where will the verification request go.
+
+Apache ShenYu Nginx Module
+---
+
+This module provided SDK to watch available ShenYu instance list as upstream nodes by Service Register Center for OpenResty.
+1. [ETCD](#greeting-etcd) (Supported)
+2. [Nacos](#greeting-nacos) (Supported)
+3. [Zookeeper](#greeting-zookeeper) (Supported)
+4. Consul (TODO)
+
+In the cluster mode, Apache ShenYu supports the deployment of multiple ShenYu instances, which may have new instances joining or leaving at any time.
+Hence, Apache ShenYu introduces Service Discovery modules to help client to detect the available instances.
+Currently, Apache ShenYu Bootstrap already supports Apache Zookeeper, Nacos, Etcd, and consul. Client or LoadBalancer can get the available ShenYu instances by those Service register center.
+
+## Getting Started
+
+- Prerequisite:
+1. Luarocks
+2. OpenResty
+
+### Build from source
+
+The first, clone the source from GitHub.
+
+```
+git clone https://github.com/apache/shenyu-nginx
+```
+
+Then, build from source and install.
+
+```
+cd shenyu-nginx
+luarocks make rockspec/shenyu-nginx-main-0.rockspec
+```
+
+### Greeting ETCD
+
+Modify the Nginx configure, create and initialize the ShenYu Register to connect to the target register center.
+The module will fetch the all of ShenYu instances which are registered to Etcd in the same cluster.
+It works like Etcd client to watch(based on long polling) ShenYu instance lists.
+
+Here is an example for Etcd.
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.etcd")
+    register.init({
+        balancer_type = "chash",
+        etcd_base_url = "http://127.0.0.1:2379",
+    })
+}
+```
+
+1. `balancer_type` specify the balancer. It has supported `chash` and `round robin`.
+2. `etcd_base_url` specify the Etcd server.(Currently, authentication is not supported.)
+
+Add an `upstream block` for ShenYu and enable to update upstream servers dynamically. This case will synchronize the ShenYu instance list with register center.
+And then pick one up for handling the request.
+
+```
+upstream shenyu {
+    server 0.0.0.1; -- bad 
+    
+    balancer_by_lua_block {
+        require("shenyu.register.etcd").pick_and_set_peer()
+    }
+}
+```
+
+Finally, restart OpenResty.
+
+```
+openresty -s reload
+```
+
+Here is a completed [example](https://github.com/apache/shenyu-nginx/blob/main/example/etcd/nginx.conf) working with ETCD.
+
+### Greeting Nacos
+
+Modify the Nginx configure, create and initialize the ShenYu Register to connect to target register center.  Here is an example for Nacos.
+
+```
+init_worker_by_lua_block {
+    local register = require("shenyu.register.nacos")
+    register.init({
+        shenyu_storage = ngx.shared.shenyu_storage,
+        balancer_type = "chash",
+        nacos_base_url = "http://127.0.0.1:8848",
+        username = "nacos",
+        password = "naocs",
+    })
+}
+```
+
+1. `balancer_type` specify the balancer. It has supported `chash` and `round robin`.
+2. `nacos_base_url` specify the Nacos server address.
+3. `username` specify the username to log in Nacos. (it is only required when Nacos auth enable)
+4. `password` specify the password to log in Nacos.
+
+Modify the `upstream` to enable to update upstream servers dynamically. This case will synchronize the ShenYu instance list with register center.
+And then pick one up for handling the request.
+
+```
+upstream shenyu {
+    server 0.0.0.1; -- bad 
+    
+    balancer_by_lua_block {
+        require("shenyu.register.nacos").pick_and_set_peer()
+    }
+}
+```
+
+Finally, restart OpenResty.
+
+```
+openresty -s reload
+```
+
+Here is a completed [example](https://github.com/apache/shenyu-nginx/blob/main/example/nacos/nginx.conf) working with Nacos.
+
+## Greeting Zookeeper
+
+Modify the Nginx configure, create and initialize the ShenYu register to connect to target register center.
+Listen for changes to the node via the zookeeper watch event. Here is an example of the zookeeper configuration.
+
+```
+init_worker_by_lua_block {
+        local register = require("shenyu.register.zookeeper")
+        register.init({
+           servers = {"127.0.0.1:2181","127.0.0.1:2182"},
+           shenyu_storage = ngx.shared.shenyu_storage,
+           balancer_type = "roundrobin"
+        });
+    }
+```
+
+1. `servers` zookeeper cluster address.
+2. ``balancer_type`` specify the balancer. It has supported `chash` and `round robin`.
+
+Modify the upstream to enable to update upstream servers dynamically. This case will synchronize the ShenYu instance list with register center. And then pick one up for handling the request.
+
+```
+ upstream shenyu {
+        server 0.0.0.1;
+        balancer_by_lua_block {
+            require("shenyu.register.zookeeper").pick_and_set_peer()
+        }
+    }
+```
+
+Finally, restart OpenResty.
+
+```
+openresty -s reload
+```
+
+Here is a completed [example](https://github.com/apache/shenyu-nginx/blob/main/example/zookeeper/nginx.conf) working with Zookeeper.