45 lines
1.2 KiB
Bash
45 lines
1.2 KiB
Bash
#!/bin/bash
|
|
# add docker
|
|
# Add Docker's official GPG key:
|
|
sudo apt update
|
|
sudo apt install ca-certificates curl git -y
|
|
#sudo install -m 0755 -d /etc/apt/keyrings
|
|
#sudo curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc
|
|
#sudo chmod a+r /etc/apt/keyrings/docker.asc
|
|
|
|
# Add the repository to Apt sources:
|
|
#sudo tee /etc/apt/sources.list.d/docker.sources <<EOF
|
|
#Types: deb
|
|
#URIs: https://download.docker.com/linux/debian
|
|
#Suites: $(. /etc/os-release && echo "$VERSION_CODENAME")
|
|
#Components: stable
|
|
#Signed-By: /etc/apt/keyrings/docker.asc
|
|
#EOF
|
|
|
|
curl -fsSL https://get.docker.com -o get-docker.sh
|
|
sudo sh get-docker.sh
|
|
|
|
sudo apt update
|
|
apt dist-upgrade -y
|
|
apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin -y
|
|
|
|
sudo groupadd docker
|
|
|
|
|
|
# set manual IP address
|
|
nmcli con mod "eth0" ipv4.addresses 192.168.178.5/24
|
|
nmcli con mod "eth0" ipv4.gateway 192.168.178.1
|
|
nmcli con mod "eth0" ipv4.dns ""
|
|
nmcli con mod "eth0" ipv4.dns "192.168.178.5 8.8.8.8"
|
|
nmcli con mod "eth0" ipv4.method manual
|
|
nmcli con up "eth0"
|
|
|
|
#install dnsmasq
|
|
apt install dnsmasq net-tools -y
|
|
cp dnsmasq.conf /etc/dnsmasq.conf
|
|
|
|
# install ntp
|
|
apt install chrony -y
|
|
mkdir /etc/chrony/
|
|
cp chrony.conf /etc/chrony/chrony.conf
|