Pihole on Docker

This is a good example for Pihole.


HypriotOS for Pi

With effort of HypriotOS, docker-machine and docker-compose  and swarm mode are easy to set up. After the installation, default network will be started and wifi connection is an option. For my case, cluster will be set up within wifi network. Therfore, wifi will be configure manually.


Docker & Swarm

There is some limitation for the system. After the installation of distributions, you are required to verify it.

Update existing system: sudo apt-get update

Upgrade existing system: sudo apt-get upgrade -y

Download script from curl -fsSL -o

Get permission to run: sudo chmod 755

Run the script to add repo and install docker: ./

Verify your distribution: uname -a

For the Pi Zero and PiZero W (armv61), repo for armhf and armv6 are recommended. It is recommended to install docker with those scripts.

After the installation of docker, you are required to add a user (i.e. pi or other username) in the group docker and then carry out a test(hello-world).

Add user into docker group: sudo usermod -aG docker (username)

either use a command(except armv6): docker run hello-world

or use a command(for armv6): docker run hypriot/armhf-hello-world

From the link, you can installed docker as a cluster with Pis. Docker and swarm can be deployed with Pis. In general, two major roles are required in your swarm. Manager is the docker engine which running in the management function to assign tasks to the nodes with load balancing. Worker is the docker engine which is responsible for the completion of tasks. During the operation, the tasks in nodes are monitored by manager. Visualizer can be run a web server in port 8080 or other port as a service in swarm as a GUI to report the status. If you would like to run wordpress and mysql inside docker, you may try this.


Home Automation System

This is a home automation system with raspberry pi. Power control system is designed with four relays which are controlled by GPIO pins of Pi. Originally, Raspberry Pi 3 B was used. Due to the errors message of under voltage and unstable of the system, Pi 3B was replaced by Pi Zero W. In order to control it via web, a web server is set up with apache2 and php7.4 is installed. Status of 4 relays are monitored and manually control via web and schedule jobs are set up with crontab -e. Status of on/off system is displayed in the UI of web. Whole system is installed in a enclosed switch box and 4 power sockets with switch are used. The power supply with 5V and 12V from a DVD was reused and installed inside the box. Therefore, 5V is used by Pi Zero W and 12V is used by relays. Pin 2(+5V), Pin 6(Ground of Power Pi), Pins 31,33,35 & 37(Relays control pins – GPIO6,13,19,26), Pin 39 (Ground of Relays).

Home Automation System – UI
Transistor controlled relay via GPIO pin
Under-voltage detected in the logs of Pi 3B

Hello world!大家好!

Welcome to Noteasy2! 歡迎來訪樂意時!