fix wx_domain
This commit is contained in:
@@ -19,6 +19,7 @@ server {
|
|||||||
set $upyun_bucket "alchemy";
|
set $upyun_bucket "alchemy";
|
||||||
set $upyun_directory "music-room";
|
set $upyun_directory "music-room";
|
||||||
set $upyun_cdn "https://upyun.alchemy-studio.cn/";
|
set $upyun_cdn "https://upyun.alchemy-studio.cn/";
|
||||||
|
set $wx_domain "wx.alchemy-studio.cn";
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
try_files $uri $uri/ /index.html;
|
try_files $uri $uri/ /index.html;
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ server {
|
|||||||
set $upyun_bucket "moicen";
|
set $upyun_bucket "moicen";
|
||||||
set $upyun_directory "music-room";
|
set $upyun_directory "music-room";
|
||||||
set $upyun_cdn "https://upyun.dev.moicen.com/";
|
set $upyun_cdn "https://upyun.dev.moicen.com/";
|
||||||
|
set $wx_domain "dev.wx.moicen.com";
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
try_files $uri $uri/ /index.html;
|
try_files $uri $uri/ /index.html;
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ server {
|
|||||||
set $upyun_bucket "moicen";
|
set $upyun_bucket "moicen";
|
||||||
set $upyun_directory "music-room";
|
set $upyun_directory "music-room";
|
||||||
set $upyun_cdn "https://upyun.dev.moicen.com/";
|
set $upyun_cdn "https://upyun.dev.moicen.com/";
|
||||||
|
set $wx_domain "dev.wx.moicen.com";
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
try_files $uri $uri/ /index.html;
|
try_files $uri $uri/ /index.html;
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ server {
|
|||||||
set $upyun_bucket "moicen";
|
set $upyun_bucket "moicen";
|
||||||
set $upyun_directory "music-room";
|
set $upyun_directory "music-room";
|
||||||
set $upyun_cdn "https://upyun.moicen.com/";
|
set $upyun_cdn "https://upyun.moicen.com/";
|
||||||
|
set $wx_domain "wx.moicen.com";
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
try_files $uri $uri/ /index.html;
|
try_files $uri $uri/ /index.html;
|
||||||
|
|||||||
@@ -16,11 +16,11 @@ local httpc = http.new()
|
|||||||
local sudoerToken = ngx.req.get_headers().HtySudoerToken
|
local sudoerToken = ngx.req.get_headers().HtySudoerToken
|
||||||
local htyhostHeader = ngx.req.get_headers().HtyHost
|
local htyhostHeader = ngx.req.get_headers().HtyHost
|
||||||
|
|
||||||
|
|
||||||
local function get_access_token()
|
local function get_access_token()
|
||||||
|
|
||||||
local htyuc = ngx.var.htyuc
|
local htyuc = ngx.var.htyuc
|
||||||
local host = ngx.var.host
|
local host = ngx.var.host
|
||||||
|
local wx_domain = ngx.var.wx_domain
|
||||||
|
|
||||||
ngx.log(ngx.INFO, "Request URL -> ", ngx.var.uri)
|
ngx.log(ngx.INFO, "Request URL -> ", ngx.var.uri)
|
||||||
ngx.log(ngx.INFO, "HTYUC -> ", htyuc)
|
ngx.log(ngx.INFO, "HTYUC -> ", htyuc)
|
||||||
@@ -37,7 +37,7 @@ local function get_access_token()
|
|||||||
ssl_verify = false, -- 设置参数 ssl_verify 为false 不校验ssl证书
|
ssl_verify = false, -- 设置参数 ssl_verify 为false 不校验ssl证书
|
||||||
method = "GET",
|
method = "GET",
|
||||||
headers = {
|
headers = {
|
||||||
["HtyHost"] = "wx.moicen.com",
|
["HtyHost"] = wx_domain,
|
||||||
["HtySudoerToken"] = sudoerToken,
|
["HtySudoerToken"] = sudoerToken,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user