File tree Expand file tree Collapse file tree 3 files changed +57
-0
lines changed
Expand file tree Collapse file tree 3 files changed +57
-0
lines changed Original file line number Diff line number Diff line change @@ -105,6 +105,7 @@ COPY --from=download-binaries \
105105 /usr/bin/blueos_startup_update.py \
106106 /usr/bin/blueos-recorder \
107107 /usr/bin/bridges \
108+ /usr/bin/disktest \
108109 /usr/bin/linux2rest \
109110 /usr/bin/machineid-cli \
110111 /usr/bin/mavlink2rest \
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+
3+ set -e
4+
5+ PROJECT_NAME=" disktest"
6+ REPOSITORY_ORG=" patrickelectric"
7+ REPOSITORY_NAME=" disktest"
8+ VERSION=" 1.16.0"
9+
10+ echo " Installing project $PROJECT_NAME version $VERSION "
11+
12+ # Step 1: Prepare the download URL
13+
14+ ARCH=" $( uname -m) "
15+ case " $ARCH " in
16+ x86_64 | amd64)
17+ BUILD_NAME=" x86_64-unknown-linux-gnu"
18+ ;;
19+ armv7l | armhf)
20+ BUILD_NAME=" armv7-unknown-linux-gnueabihf"
21+ ;;
22+ aarch64 | arm64)
23+ BUILD_NAME=" aarch64-unknown-linux-gnu"
24+ ;;
25+ * )
26+ echo " Architecture: $ARCH is unsupported, please create a new issue on https://github.com/${REPOSITORY_ORG} /${REPOSITORY_NAME} /issues"
27+ exit 1
28+ ;;
29+ esac
30+ ARTIFACT_NAME=" ${PROJECT_NAME} -${BUILD_NAME} "
31+ REMOTE_URL=" https://github.com/${REPOSITORY_ORG} /${REPOSITORY_NAME} /releases/download/${VERSION} /${ARTIFACT_NAME} "
32+ echo " Remote URL is $REMOTE_URL "
33+
34+ # Step 2: Prepare the installation and tools paths
35+
36+ if [ -n " $VIRTUAL_ENV " ]; then
37+ BIN_DIR=" $VIRTUAL_ENV /bin"
38+ else
39+ BIN_DIR=" /usr/bin"
40+ fi
41+ mkdir -p " $BIN_DIR "
42+
43+ BINARY_PATH=" $BIN_DIR /$PROJECT_NAME "
44+ echo " Installing to $BINARY_PATH "
45+
46+ # Step 3: Download and install
47+
48+ wget -q " $REMOTE_URL " -O " $BINARY_PATH "
49+
50+
51+ chmod +x " $BINARY_PATH "
52+
53+ echo " Installed binary type: $( file " $BINARY_PATH " ) "
54+
55+ echo " Finished installing $PROJECT_NAME "
Original file line number Diff line number Diff line change 88TOOLS=(
99 blueos_startup_update
1010 bridges
11+ disktest
1112 linux2rest
1213 machineid
1314 mavlink2rest
You can’t perform that action at this time.
0 commit comments