File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -114,9 +114,18 @@ sha256check() {
114114 NODE_FILE="&NODEJS_FILENAME; "
115115 <![CDATA[
116116 if [[ -f "/boot/config/plugins/dynamix.my.servers/${NODE_FILE}" ]]; then
117- tar --strip-components=1 -xf /boot/config/plugins/dynamix.my.servers/${NODE_FILE} -C /usr/local/;
117+ TEMP_DIR=$(mktemp -d)
118+ tar -xf /boot/config/plugins/dynamix.my.servers/${NODE_FILE} -C ${TEMP_DIR};
119+ if cp -rf "${TEMP_DIR}"/bin/* /usr/local/bin/ && \
120+ cp -rf "${TEMP_DIR}"/lib/* /usr/local/lib/ && \
121+ cp -rf "${TEMP_DIR}"/include/* /usr/local/include/ && \
122+ cp -rf "${TEMP_DIR}"/share/* /usr/local/share/ then
123+ echo "Node.js installation successful"
124+ else
125+ echo "Failed to copy Node.js files"
126+ exit 1
127+ fi
118128 fi
119-
120129 exit 0;
121130 ]]>
122131 </INLINE >
You can’t perform that action at this time.
0 commit comments