mirror of
https://gitee.com/iresty/apisix.git
synced 2024-12-15 17:31:45 +08:00
3a709c790c
home folder.
13 lines
329 B
Bash
Executable File
13 lines
329 B
Bash
Executable File
#!/bin/sh
|
|
|
|
lua_version=`lua -e "print(_VERSION)" | grep -o -E "(5.[0-9])"`
|
|
|
|
if [ $lua_version = "5.1" ];then
|
|
echo "current Lua version is 5.1, skip to update conf/nginx.conf"
|
|
exit
|
|
fi
|
|
|
|
sed s"?lua/5.1?lua/$lua_version?" conf/nginx.conf > conf/nginx.conf.tmp
|
|
mv conf/nginx.conf.tmp conf/nginx.conf
|
|
echo "updated nginx.conf"
|