From 13041294820adf827055e0e44ea3938ab19db51b Mon Sep 17 00:00:00 2001 From: pan <1029559041@qq.com> Date: Sun, 11 Oct 2020 03:48:17 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0openresty?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- conf/nginx.conf | 5 +++++ run | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/conf/nginx.conf b/conf/nginx.conf index 1b17a2b..63c7537 100644 --- a/conf/nginx.conf +++ b/conf/nginx.conf @@ -21,5 +21,10 @@ set $target ''; '; proxy_pass $target; } + + location ~ /api{ + proxy_pass http://127.0.0.1:2233 + } } + } \ No newline at end of file diff --git a/run b/run index 8fae550..9a60dee 100644 --- a/run +++ b/run @@ -1,3 +1,3 @@ #!/bin/sh #创建运行容器 -docker run --name test -p 3000:3000 -p 2233:2233 test:1.0 +docker run --name test -p 8080:8080 test:1.0