mirror of
https://github.com/NapNeko/NapCat-Docker.git
synced 2025-12-23 01:50:05 +08:00
feat: more config
This commit is contained in:
parent
5df4dec4f9
commit
e5d9e3a179
@ -1,17 +1,21 @@
|
|||||||
{
|
{
|
||||||
"httpPort": HTTP_PORT,
|
"httpPort": HTTP_PORT,
|
||||||
|
"httpHost": "HTTP_HOST",
|
||||||
"httpPostUrls": ["HTTP_URLS"],
|
"httpPostUrls": ["HTTP_URLS"],
|
||||||
"httpSecret": "",
|
"httpSecret": "",
|
||||||
"wsPort": WS_PORT,
|
"wsPort": WS_PORT,
|
||||||
|
"wsHost": "WS_HOST",
|
||||||
"wsReverseUrls": ["WS_URLS"],
|
"wsReverseUrls": ["WS_URLS"],
|
||||||
"enableHttp": HTTP_ENABLE,
|
"enableHttp": HTTP_ENABLE,
|
||||||
"enableHttpPost": HTTP_POST_ENABLE,
|
"enableHttpPost": HTTP_POST_ENABLE,
|
||||||
"enableWs": WS_ENABLE,
|
"enableWs": WS_ENABLE,
|
||||||
"enableWsReverse": WSR_ENABLE,
|
"enableWsReverse": WSR_ENABLE,
|
||||||
|
"enableHttpHeart": HTTP_HEART_ENABLE,
|
||||||
"messagePostFormat": "MESSAGE_POST_FORMAT",
|
"messagePostFormat": "MESSAGE_POST_FORMAT",
|
||||||
"reportSelfMessage": RSM_ENABLE,
|
"reportSelfMessage": RSM_ENABLE,
|
||||||
"debug": DEBUG_ENABLE,
|
"debug": DEBUG_ENABLE,
|
||||||
"enableLocalFile2Url": F2U_ENABLE,
|
"enableLocalFile2Url": F2U_ENABLE,
|
||||||
"heartInterval": HEART,
|
"heartInterval": HEART,
|
||||||
|
"musicSignUrl": "MUSIC_SIGN_URL",
|
||||||
"token": "TOKEN"
|
"token": "TOKEN"
|
||||||
}
|
}
|
||||||
@ -95,6 +95,30 @@ if [ ! -f "$CONFIG_PATH" ]; then
|
|||||||
else
|
else
|
||||||
sed -i "s/MESSAGE_POST_FORMAT/array/" $CONFIG_PATH
|
sed -i "s/MESSAGE_POST_FORMAT/array/" $CONFIG_PATH
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$HTTP_HOST" ]; then
|
||||||
|
sed -i "s/HTTP_HOST/$HTTP_HOST/" $CONFIG_PATH
|
||||||
|
else
|
||||||
|
sed -i "s/HTTP_HOST//" $CONFIG_PATH
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$WS_HOST" ]; then
|
||||||
|
sed -i "s/WS_HOST/$WS_HOST/" $CONFIG_PATH
|
||||||
|
else
|
||||||
|
sed -i "s/WS_HOST//" $CONFIG_PATH
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$HTTP_HEART_ENABLE" ]; then
|
||||||
|
sed -i "s/HTTP_HEART_ENABLE/$HTTP_HEART_ENABLE/" $CONFIG_PATH
|
||||||
|
else
|
||||||
|
sed -i "s/HTTP_HEART_ENABLE/false/" $CONFIG_PATH
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "$MUSIC_SIGN_URL" ]; then
|
||||||
|
sed -i "s/MUSIC_SIGN_URL/$MUSIC_SIGN_URL/" $CONFIG_PATH
|
||||||
|
else
|
||||||
|
sed -i "s/MUSIC_SIGN_URL//" $CONFIG_PATH
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
export FFMPEG_PATH=/usr/bin/ffmpeg
|
export FFMPEG_PATH=/usr/bin/ffmpeg
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user