Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix to support ARM based systems #13

Merged
merged 3 commits into from
Jul 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/cli-basic-with-nvm.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build CLI Basic With NPM
name: Build CLI Basic With NVM
on:
push:
paths:
Expand Down
18 changes: 17 additions & 1 deletion cli/basic-with-nvm/install_zowe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ npm config set @zowe:registry https://zowe.jfrog.io/zowe/api/npm/npm-local-relea
rm -rf ~/.zowe/plugins
npm install -g @zowe/cli@${PKG_TAG}

plugins=( @zowe/zos-ftp-for-zowe-cli@${PKG_TAG} @zowe/cics-for-zowe-cli@${PKG_TAG} @zowe/db2-for-zowe-cli@${PKG_TAG} @zowe/ims-for-zowe-cli@${PKG_TAG} @zowe/mq-for-zowe-cli@${PKG_TAG})
plugins=( @zowe/zos-ftp-for-zowe-cli@${PKG_TAG} @zowe/cics-for-zowe-cli@${PKG_TAG} @zowe/ims-for-zowe-cli@${PKG_TAG} @zowe/mq-for-zowe-cli@${PKG_TAG})
noarm_plugins=( @zowe/db2-for-zowe-cli@${PKG_TAG} )

for i in "${plugins[@]}"; do
if [ ! -z "${ALLOW_PLUGIN_INSTALL_FAIL}" ]; then
Expand All @@ -37,4 +38,19 @@ for i in "${plugins[@]}"; do
fi
done

if uname -m | grep -q 'arm\|aarch'; then
echo "Unable to install the following plug-ins due to CPU architecture:"
for i in "${noarm_plugins[@]}"; do
echo $i
done
else
for i in "${noarm_plugins[@]}"; do
if [ ! -z "${ALLOW_PLUGIN_INSTALL_FAIL}" ]; then
zowe plugins install $i || true
else
zowe plugins install $i || exit 1
fi
done
fi

exit 0
18 changes: 17 additions & 1 deletion cli/basic/install_zowe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ npm config set @zowe:registry https://zowe.jfrog.io/zowe/api/npm/npm-local-relea
rm -rf ~/.zowe/plugins
npm install -g @zowe/cli@${PKG_TAG}

plugins=( @zowe/zos-ftp-for-zowe-cli@${PKG_TAG} @zowe/cics-for-zowe-cli@${PKG_TAG} @zowe/db2-for-zowe-cli@${PKG_TAG} @zowe/ims-for-zowe-cli@${PKG_TAG} @zowe/mq-for-zowe-cli@${PKG_TAG})
plugins=( @zowe/zos-ftp-for-zowe-cli@${PKG_TAG} @zowe/cics-for-zowe-cli@${PKG_TAG} @zowe/ims-for-zowe-cli@${PKG_TAG} @zowe/mq-for-zowe-cli@${PKG_TAG})
noarm_plugins=( @zowe/db2-for-zowe-cli@${PKG_TAG} )

for i in "${plugins[@]}"; do
if [ ! -z "${ALLOW_PLUGIN_INSTALL_FAIL}" ]; then
Expand All @@ -32,4 +33,19 @@ for i in "${plugins[@]}"; do
fi
done

if uname -m | grep -q 'arm\|aarch'; then
echo "Unable to install the following plug-ins due to CPU architecture:"
for i in "${noarm_plugins[@]}"; do
echo $i
done
else
for i in "${noarm_plugins[@]}"; do
if [ ! -z "${ALLOW_PLUGIN_INSTALL_FAIL}" ]; then
zowe plugins install $i || true
else
zowe plugins install $i || exit 1
fi
done
fi

exit 0
18 changes: 17 additions & 1 deletion cli/jenkins-agent/install_zowe.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ npm config set @zowe:registry https://zowe.jfrog.io/zowe/api/npm/npm-local-relea
rm -rf ~/.zowe/plugins
npm install -g @zowe/cli@${PKG_TAG}

plugins=( @zowe/zos-ftp-for-zowe-cli@${PKG_TAG} @zowe/cics-for-zowe-cli@${PKG_TAG} @zowe/db2-for-zowe-cli@${PKG_TAG} @zowe/ims-for-zowe-cli@${PKG_TAG} @zowe/mq-for-zowe-cli@${PKG_TAG})
plugins=( @zowe/zos-ftp-for-zowe-cli@${PKG_TAG} @zowe/cics-for-zowe-cli@${PKG_TAG} @zowe/ims-for-zowe-cli@${PKG_TAG} @zowe/mq-for-zowe-cli@${PKG_TAG})
noarm_plugins=( @zowe/db2-for-zowe-cli@${PKG_TAG} )

for i in "${plugins[@]}"; do
if [ ! -z "${ALLOW_PLUGIN_INSTALL_FAIL}" ]; then
Expand All @@ -37,4 +38,19 @@ for i in "${plugins[@]}"; do
fi
done

if uname -m | grep -q 'arm\|aarch'; then
echo "Unable to install the following plug-ins due to CPU architecture:"
for i in "${noarm_plugins[@]}"; do
echo $i
done
else
for i in "${noarm_plugins[@]}"; do
if [ ! -z "${ALLOW_PLUGIN_INSTALL_FAIL}" ]; then
zowe plugins install $i || true
else
zowe plugins install $i || exit 1
fi
done
fi

exit 0
2 changes: 1 addition & 1 deletion cli/minimal/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ RUN apt-get update && apt-get install -y curl build-essential python3 && curl -f
# Install Zowe CLI
RUN npm install -g @zowe/cli@${ZOWE_VERSION} --ignore-scripts
USER zowe
RUN zowe plugins install @zowe/cics-for-zowe-cli@${ZOWE_VERSION} @zowe/db2-for-zowe-cli@${ZOWE_VERSION} @zowe/ims-for-zowe-cli@${ZOWE_VERSION} @zowe/mq-for-zowe-cli@${ZOWE_VERSION} @zowe/zos-ftp-for-zowe-cli@${ZOWE_VERSION}
RUN zowe plugins install @zowe/cics-for-zowe-cli@${ZOWE_VERSION} @zowe/ims-for-zowe-cli@${ZOWE_VERSION} @zowe/mq-for-zowe-cli@${ZOWE_VERSION} @zowe/zos-ftp-for-zowe-cli@${ZOWE_VERSION} && if uname -m | grep -q 'arm\|aarch'; then echo "Unable to install the DB2 Plug-in due to CPU architecture"; else zowe plugins install @zowe/db2-for-zowe-cli@${ZOWE_VERSION}; fi
RUN mkdir -p ~/.zowe/settings && echo '{"overrides":{"CredentialManager":false}}' > ~/.zowe/settings/imperative.json

# Uncomment to enable daemon mode by default
Expand Down