Install Docker in Raspberry Pi 4

From Chorke Wiki
Revision as of 02:21, 3 January 2021 by Shahed (talk | contribs)
Jump to navigation Jump to search
df -h
vcgencmd measure_temp
apt list --upgradable
apt upgrade

apt install openjdk-8-jdk/stable
apt install openjdk-11-jdk/stable
df -h

curl -sSL https://get.docker.com | sh
usermod -aG docker pi
docker --version
df -h

docker run hello-world
docker ps -a
docker images

apt install libffi-dev libssl-dev
apt install python3 python3-pip
apt remove python-configparser
pip3 install docker-compose
df -h

Networking

cat <<EOF > /etc/docker/daemon.json
{
    "bip"  : "10.20.13.1/24",
    "mtu"  : 1500,
    "dns"  : [
        "10.19.83.5",
        "10.19.83.1"
    ],
    "debug": true
}
EOF
cat <<EOF > /etc/docker/daemon.json
{
    "mtu"   : 1500,
    "debug" : true,
    "experimental": false,
    "default-address-pools" :[{
        "base"  : "10.20.0.0/16",
        "size"  : 24
    }]
}
EOF

References