0b0869a4 by lihua

先去掉自定义appkey

1 parent 3233b39b
......@@ -11,4 +11,4 @@ RUN chown -R nginx:nginx /usr/share/nginx/html
EXPOSE 29900
#CMD:指定容器启动时要运行的命令
CMD ["nginx", "-g", "daemon off;"]
CMD envsubst '${API_BASE_URL}' < /etc/nginx/conf.d/default.conf.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'
#CMD envsubst '${API_BASE_URL}' < /etc/nginx/conf.d/default.conf.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'
......
......@@ -37,12 +37,12 @@ server {
}
# 专门处理 config.json 的 location
location = /config.json {
# 启用 sub_filter 并指定 MIME 类型为 application/json
sub_filter '{{{API_BASE_URL}}}' '${API_BASE_URL}';
sub_filter_once off;
sub_filter_types application/json; # 关键:允许替换 JSON 类型
}
# location = /config.json {
# # 启用 sub_filter 并指定 MIME 类型为 application/json
# sub_filter '{{{API_BASE_URL}}}' '${API_BASE_URL}';
# sub_filter_once off;
# sub_filter_types application/json; # 关键:允许替换 JSON 类型
# }
error_page 500 502 503 504 /50x.html;
location = /50x.html {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!