diff --git a/acme.sh/cert_utils.sh b/acme.sh/cert_utils.sh index 41e69a751..db52ef508 100755 --- a/acme.sh/cert_utils.sh +++ b/acme.sh/cert_utils.sh @@ -1,7 +1,7 @@ restricted_tlds=("af" "by" "cu" "er" "gn" "ir" "kp" "lr" "ru" "ss" "su" "sy" "zw" "amazonaws.com","azurewebsites.net","cloudapp.net") shopt -s expand_aliases -source lib/acme.sh.env +source ./lib/acme.sh.env # Function to check if a domain is restricted is_ok_domain_zerossl() { @@ -14,7 +14,7 @@ is_ok_domain_zerossl() { return 0 # Domain is not restricted } function get_cert() { - cd /opt/hiddify-manager/acme.sh + cd /opt/hiddify-manager/acme.sh/ source ./lib/acme.sh.env # ./lib/acme.sh --register-account -m my@example.com @@ -79,7 +79,7 @@ function has_valid_cert() { } function get_self_signed_cert() { - cd /opt/hiddify-manager/acme.sh + cd /opt/hiddify-manager/acme.sh/ d=$1 if [ ${#d} -gt 64 ]; then echo "Domain length exceeds 64 characters. Truncating to the first 64 characters." diff --git a/acme.sh/install.sh b/acme.sh/install.sh index 143a5e1d1..06e4661fb 100755 --- a/acme.sh/install.sh +++ b/acme.sh/install.sh @@ -14,6 +14,6 @@ fi mkdir -p ../ssl/ ./lib/acme.sh --uninstall-cronjob shopt -s expand_aliases -source lib/acme.sh.env +source ./lib/acme.sh.env acme.sh --register-account -m my@example.com systemctl reload hiddify-haproxy diff --git a/haproxy/run.sh b/haproxy/run.sh index e72f3ebbb..fb929a2b9 100755 --- a/haproxy/run.sh +++ b/haproxy/run.sh @@ -8,8 +8,9 @@ domains=$(cat ../current.json | jq -r '.domains[] | select(.mode | IN("direct", "cdn", "worker", "relay", "auto_cdn_ip", "old_xtls_direct", "sub_link_only", "fake")) | .domain') # we need at least one ssl certificate to be able to run haproxy for d in $domains; do - bash ../acme.sh/generate_self_signed_cert.sh $d + bash ../acme.sh/generate_self_signed_cert.sh $d done -systemctl reload hiddify-haproxy +# systemctl reload hiddify-haproxy +systemctl restart hiddify-haproxy.service systemctl start hiddify-haproxy diff --git a/hiddify-panel/src b/hiddify-panel/src index 088f7da39..943952906 160000 --- a/hiddify-panel/src +++ b/hiddify-panel/src @@ -1 +1 @@ -Subproject commit 088f7da397d9c8a432d9412cf50a473885880e4b +Subproject commit 94395290627d3ee4e98855fca09bf201640f94c1 diff --git a/nginx/run.sh b/nginx/run.sh index 06e940ffa..452dde0bd 100755 --- a/nginx/run.sh +++ b/nginx/run.sh @@ -1,4 +1,4 @@ #!/bin/bash -systemctl reload hiddify-nginx +systemctl restart hiddify-nginx systemctl start hiddify-nginx diff --git a/release b/release new file mode 100755 index 000000000..6fa6b33f3 --- /dev/null +++ b/release @@ -0,0 +1,20 @@ +#!/bin/bash + +which gitchangelog +if [[ "$?" != 0 ]];then + pip3 install gitchangelog pystache +fi +previous_tag=$(git describe --tags $(git rev-list --tags --max-count=1)) +echo "previous version was $previous_tag" +read -p "Version? (provide the next x.y.z semver) : " TAG +[[ $TAG = v* ]] && echo "incorrect tag" && exit 1 +echo "${TAG}" > VERSION +git tag v${TAG} +gitchangelog > HISTORY.md +git tag -d v${TAG} +git add VERSION HISTORY.md +git commit -m "release: version ${TAG} 🚀" +echo "creating git tag : v${TAG}" +git tag v${TAG} +git push -u origin HEAD --tags +echo "Github Actions will detect the new tag and release the new version."