mirror of
https://github.com/armbian/build
synced 2025-09-24 19:47:06 +07:00
Improve Docker support on Linux mint (#1899)
CI can't check, its tested, merging. Signed-off-by: Igor Pecovnik <igor.pecovnik@gmail.com>
This commit is contained in:
@@ -116,10 +116,12 @@ if [[ "$1" == docker && -f /etc/debian_version && -z "$(which docker)" ]]; then
|
|||||||
|
|
||||||
# add exception for Ubuntu Focal until Docker provides dedicated binary
|
# add exception for Ubuntu Focal until Docker provides dedicated binary
|
||||||
codename=$(lsb_release -sc)
|
codename=$(lsb_release -sc)
|
||||||
|
codeid=$(lsb_release -is | awk '{print tolower($0)}')
|
||||||
|
[[ $codeid == linuxmint && $codename == debbie ]] && codename="buster" && codeid="debian"
|
||||||
[[ $codename == focal ]] && codename="bionic"
|
[[ $codename == focal ]] && codename="bionic"
|
||||||
|
|
||||||
display_alert "Docker not installed." "Installing" "Info"
|
display_alert "Docker not installed." "Installing" "Info"
|
||||||
echo "deb [arch=amd64] https://download.docker.com/linux/$(lsb_release -is | awk '{print tolower($0)}') ${codename} edge" > /etc/apt/sources.list.d/docker.list
|
echo "deb [arch=amd64] https://download.docker.com/linux/${codeid} ${codename} edge" > /etc/apt/sources.list.d/docker.list
|
||||||
|
|
||||||
# minimal set of utilities that are needed for prep
|
# minimal set of utilities that are needed for prep
|
||||||
packages=("curl" "gnupg" "apt-transport-https")
|
packages=("curl" "gnupg" "apt-transport-https")
|
||||||
@@ -129,7 +131,7 @@ if [[ "$1" == docker && -f /etc/debian_version && -z "$(which docker)" ]]; then
|
|||||||
done
|
done
|
||||||
[[ -z $install_packages ]] && apt update;apt install -y -qq --no-install-recommends $install_packages
|
[[ -z $install_packages ]] && apt update;apt install -y -qq --no-install-recommends $install_packages
|
||||||
|
|
||||||
curl -fsSL "https://download.docker.com/linux/$(lsb_release -is | awk '{print tolower($0)}')/gpg" | apt-key add -qq - > /dev/null 2>&1
|
curl -fsSL "https://download.docker.com/linux/${codeid}/gpg" | apt-key add -qq - > /dev/null 2>&1
|
||||||
export DEBIAN_FRONTEND=noninteractive
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
apt update
|
apt update
|
||||||
apt install -y -qq --no-install-recommends docker-ce
|
apt install -y -qq --no-install-recommends docker-ce
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ fi
|
|||||||
DOCKER_FLAGS=()
|
DOCKER_FLAGS=()
|
||||||
|
|
||||||
# Running this container in privileged mode is a simple way to solve loop device access issues
|
# Running this container in privileged mode is a simple way to solve loop device access issues
|
||||||
# Required for USB FEL
|
# Required for USB FEL or when writing image directly to the block device, when CARD_DEVICE is defined
|
||||||
#DOCKER_FLAGS+=(--privileged)
|
#DOCKER_FLAGS+=(--privileged)
|
||||||
|
|
||||||
# add only required capabilities instead (though MKNOD should be already present)
|
# add only required capabilities instead (though MKNOD should be already present)
|
||||||
|
|||||||
Reference in New Issue
Block a user