Skip to content

Commit

Permalink
remove os_arch and use targetarch
Browse files Browse the repository at this point in the history
  • Loading branch information
binhex committed Sep 19, 2023
1 parent 5f71a30 commit 8968857
Showing 1 changed file with 2 additions and 12 deletions.
14 changes: 2 additions & 12 deletions build/root/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,8 @@ mv /tmp/scripts-master/shell/arch/docker/*.sh /usr/local/bin/
# detect image arch
####

OS_ARCH=$(cat /etc/os-release | grep -P -o -m 1 "(?=^ID\=).*" | grep -P -o -m 1 "[a-z]+$")
if [[ ! -z "${OS_ARCH}" ]]; then
if [[ "${OS_ARCH}" == "arch" ]]; then
OS_ARCH="x86-64"
else
OS_ARCH="aarch64"
fi
echo "[info] OS_ARCH defined as '${OS_ARCH}'"
else
echo "[warn] Unable to identify OS_ARCH, defaulting to 'x86-64'"
OS_ARCH="x86-64"
fi
# get target arch from Dockerfile argument
TARGETARCH="${2}"

# pacman packages
####
Expand Down

0 comments on commit 8968857

Please sign in to comment.