移除 子域名检测
This commit is contained in:
parent
cdb1173b0b
commit
31ccea32c1
4
main.py
4
main.py
@ -308,10 +308,6 @@ async def query_api(
|
|||||||
if '/' in domain:
|
if '/' in domain:
|
||||||
raise HTTPException(status_code=400, detail="域名不能包含路径")
|
raise HTTPException(status_code=400, detail="域名不能包含路径")
|
||||||
|
|
||||||
# 检查是否为子域名
|
|
||||||
if domain.count('.') > 1:
|
|
||||||
raise HTTPException(status_code=400, detail="不支持子域名,请使用主域名")
|
|
||||||
|
|
||||||
# 检查域名格式
|
# 检查域名格式
|
||||||
if not re.match(domain_pattern, domain):
|
if not re.match(domain_pattern, domain):
|
||||||
raise HTTPException(status_code=400, detail="域名格式不正确,请使用正确的域名格式(如 example.com)")
|
raise HTTPException(status_code=400, detail="域名格式不正确,请使用正确的域名格式(如 example.com)")
|
||||||
|
@ -31,7 +31,7 @@ spec:
|
|||||||
runtimeClassName: "nvidia"
|
runtimeClassName: "nvidia"
|
||||||
containers:
|
containers:
|
||||||
- name: icp-api
|
- name: icp-api
|
||||||
image: leafdev.top/leaf/icp-api:v0.0.1
|
image: leafdev.top/leaf/icp-api:v0.0.2
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 80
|
- containerPort: 80
|
||||||
protocol: TCP
|
protocol: TCP
|
||||||
|
Loading…
Reference in New Issue
Block a user