5 lines
221 B
Bash
5 lines
221 B
Bash
#!/bin/bash
|
|
# 在 nginx.conf http 块开头添加 map 定义
|
|
sed -i '/^http {/a\\n map $http_upgrade $connection_upgrade {\n default upgrade;\n '\'''\'' close;\n }' /etc/nginx/nginx.conf
|
|
nginx -t
|