You can choose between a Desktop version or a Lite version without xorg & xfce
Note: Using these images will require a few extra steps to setup which we will also cover below.
The rpi-eeprom package will not be available in the repos so you won't able to update the RPI's firmware if that's required.
The image file will most likely be compressed (7z or zip) so be sure to unzip it.
Flash the downloaded Debian image file to a SDCard or whatever boot storage you're using with an Imaging program.
Eg: BalenaEtcher, Rasberry Pie imager, W32diskImager
To login via ssh you need to first edit two config files to enable remote root access.
Note: you'll most likely need another working Linux system to do this step as Microsoft Windows cannot access a Linux Filesystem natively.
On the RASPIROOT partition edit file "/etc/ssh/sshd_config" Uncomment and change the following entry:
#PermitRootLogin prohibit-password > PermitRootLogin yes
On the RASPIFIRM partition edit file "/sysconf.txt" Add the following entry (without quotes):
root_pw="yourpassword"
Optionally you can change the hostname here as well:
hostname="givenhostname"
Plug the bootable media into your Pi and boot to it. Now you should be able to SSH into it with this command:
ssh root@deviceip
apt update && apt list --upgradable
apt dist-upgrade -y && apt autoremove
Be sure to reboot PI if you had to install any major packages: reboot
As mentioned above the following steps only pertain to the vanilla Debian image (skip the numbered steps below if otherwise)
-
Install sudo along with some other optional utils you may need later
apt install sudo htop curl wget git build-essential dnsutils -
Create a standard User account and it to the sudo group
adduser username
usermod -aG sudo username -
Verify sudo membership
getent group sudo -
Test run sudo
su - username
sudo whoami
Run through the standard setup tool, configure the Raspberry Pie OS, and create a standard User account
sudo dpkg-reconfigure console-setup
sudo raspi-config
nano /etc/ssh/sshd_config
Change this part to like so:
PermitRootLogin no
Append the following to sshd_config:
AllowUsers username
Optionally install neofetch and edit the .bashrc file to display system info after logging in via ssh
sudo apt install neofetch
nano ~/.bashrc
Append the following code into .bashrc file to make it work:
if [[ -n $SSH_CONNECTION ]]; then clear && neofetch fi
sudo apt install apt-transport-https ca-certificates gnupg-agent software-properties-common python3-pip
sudo curl -sSL https://get.docker.com | sh
sudo curl -L "https://github.com/docker/compose/releases/download/1.25.5/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
sudo chmod +x /usr/local/bin/docker-compose
The latest version of Docker Compose is not compatible with previous versions so you should also install Compose-Switch
curl -fL https://raw.githubusercontent.com/docker/compose-switch/master/install_on_linux.sh | sudo sh
docker-compose -v
update-alternatives --display docker-compose
sudo usermod -aG docker username
Run these commands (without sudo) to verify Docker is installed and functioning correctly:
docker ps
docker run hello-world
sudo docker pull portainer/portainer-ce
sudo docker run --restart always -d -p 9000:9000 -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer-ce
http://[RASPBERRY_PI_IP_ADDRESS]:9000
If you plan on installing a Pihole docker container you're gonna need to disable the resolved service (otherwise skip)
systemctl stop systemd-resolved
systemctl disable systemd-resolved
Edit resolv.conf and remove \ replace any existing IPs with 8.8.8.8
nano /etc/resolv.conf
you need to learn Docker RIGHT NOW!! // Docker Containers 101
BLOCK EVERYTHING w/ PiHole on Docker, OpenDNS and IFTTT
How to Install Portainer on a Raspberry Pi!
Please feel free to leave any helpful comments or suggestions