File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,30 +17,9 @@ INSTALL_PATH="/opt/nebula-sync"
1717ENV_PATH=" /opt/nebula-sync/.env"
1818SERVICE_PATH=" /etc/systemd/system/nebula-sync.service"
1919
20- msg_info " Downloading Nebula-Sync"
21- mkdir -p " $INSTALL_PATH "
22- cd " $INSTALL_PATH "
23-
24- # Get latest release
25- LATEST_RELEASE=$( curl -fsSL https://api.github.com/repos/lovelaze/nebula-sync/releases/latest | sed -n ' s/.*"tag_name": *"\([^"]*\)".*/\1/p' )
26- ARCH=$( uname -m)
27- case " $ARCH " in
28- x86_64) ARCH=" amd64" ;;
29- aarch64) ARCH=" arm64" ;;
30- armv7l) ARCH=" armv7" ;;
31- * ) msg_error " Unsupported architecture: $ARCH " ; exit 1 ;;
32- esac
33-
34- # Download binary
35- VERSION_NO_V=" ${LATEST_RELEASE# v} "
36- BINARY_URL=" https://github.com/lovelaze/nebula-sync/releases/download/${LATEST_RELEASE} /nebula-sync_${VERSION_NO_V} _linux_${ARCH} .tar.gz"
37- curl -fSL -o nebula-sync.tar.gz " $BINARY_URL " || {
38- msg_error " Failed to download Nebula-Sync binary from ${BINARY_URL} "
39- exit 1
40- }
41- tar -xzf nebula-sync.tar.gz
42- rm nebula-sync.tar.gz
43- chmod +x nebula-sync
20+ msg_info " Installing Nebula-Sync"
21+ fetch_and_deploy_gh_release " nebula-sync" " lovelaze/nebula-sync" " prebuild" " latest" " /opt/nebula-sync" " nebula-sync_.*_linux_.*\.tar\.gz"
22+ msg_ok " Installed Nebula-Sync"
4423msg_ok " Downloaded Nebula-Sync ${LATEST_RELEASE} "
4524
4625# Gather configuration from user
You can’t perform that action at this time.
0 commit comments