Skip to content

Commit

Permalink
v2ray.sh | Version 1.0.202405112023
Browse files Browse the repository at this point in the history
  • Loading branch information
hezhijie0327 committed May 11, 2024
1 parent 105154f commit 86b011c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion v2ray/v2ray.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ CURL_OPTION=""
DOWNLOAD_CONFIG="" # false, true
USE_CDN="true"

LOG_LEVEL="" # debug, info, warning, error, none"

RUNNING_MODE="" # client, server
RUNTIME_PROTOCOL="" # trojan, vless, vmess

Expand Down Expand Up @@ -62,7 +64,7 @@ function DownloadConfiguration() {
fi

if [ "${DOWNLOAD_CONFIG:-true}" == "true" ]; then
curl ${CURL_OPTION:--4 -s --connect-timeout 15} "https://${CDN_PATH}/ZJDNS/main/v2ray/${RUNNING_MODE:-server}_${RUNTIME_PROTOCOL:-vmess}.json" > "${DOCKER_PATH}/conf/config.json" && sed -i "s/demo.zhijie.online/${CUSTOM_SERVERNAME}/g;s/99235a6e-05d4-2afe-2990-5bc5cf1f5c52/${CUSTOM_UUID}/g;s/fullchain\.cer/${SSL_CERT/./\\.}/g;s/zhijie\.online\.key/${SSL_KEY/./\\.}/g" "${DOCKER_PATH}/conf/config.json"
curl ${CURL_OPTION:--4 -s --connect-timeout 15} "https://${CDN_PATH}/ZJDNS/main/v2ray/${RUNNING_MODE:-server}_${RUNTIME_PROTOCOL:-vmess}.json" > "${DOCKER_PATH}/conf/config.json" && sed -i "s/\"info\"/\"${LOG_LEVEL:-info}\"/g;s/demo.zhijie.online/${CUSTOM_SERVERNAME}/g;s/99235a6e-05d4-2afe-2990-5bc5cf1f5c52/${CUSTOM_UUID}/g;s/fullchain\.cer/${SSL_CERT/./\\.}/g;s/zhijie\.online\.key/${SSL_KEY/./\\.}/g" "${DOCKER_PATH}/conf/config.json"

if [ "${CUSTOM_IP[*]}" != "" ] && [ "${RUNNING_MODE:-server}" == "client" ]; then
JSON_STRING="" && for IP in "${CUSTOM_IP[@]}"; do
Expand Down

0 comments on commit 86b011c

Please sign in to comment.