Install Redis to a Raspberry Pi3 with Pantacor Hub

Updated November 2021

Product designers can use Pantavisor and Pantacor Hub to create, deploy and manage many different types of containerized apps on your IoT devices. Pantavisor is the framework for containerized embedded Linux development. It connects embedded devices, and containerizes and modularizes both the embedded firmware and user-land. In this tutorial, we’ll show you how to install Pantavisor onto a Raspberry Pi, claim your device and then make it accessible from the Pantacor Hub dashboard. Lastly, we describe how to prepare and deploy a Redis database onto the device and then connect to it with a laptop.

Before you begin this tutorial, sign up to Pantacor Hub. It’s open source and free to use. 

Prepare your Raspberry Pi 3 device for Redis

Step 1: Flash your SD card with the RPi3 initial stable image.

Download latest stable RPi3 image:

Pantavisor Initial images

unzip the device image with:

$ unxz rpi3_initial_stable.img.xz

Flash the image into the SD card using Raspberry Pi Imager

Step 2: Boot your RPi3

Insert your SD card in your Pi and then attach the power supply.

Step 3: Sign up to Pantacor Hub

Step 4: Download and install the CLI “pvr”

Note: PVR is a command line interface (CLI) that you can use to interact with your device and Pantacor Hub. With PVR you can share your firmware and projects like a git tree. Move the PVR binary to your bin folder after download.

If you prefer to work locally on your device, and not connect to Pantacor Hub, then you can use our self-contained Pantavisor utilities, Pantabox

Install and download PVR:

Download and install PVR

To install from GitLab source:

$ go get
$ go build -o ~/bin/pvr

Note: You need “GOLANG” to be installed in your system for building pvr from gitlab source.

Step 5: Detect and claim your device in Pantacor Hub

Connect a LAN cable between your RPI3 & computer/Router.

Open your terminal & run

$ pvr device scan

Claim your device

$ pvr claim -c merely-regular-gorilla

Log into Pantacor Hub and check that the newly claimed device appears in the dashboard.

Step 6: Clone the device and use it on your laptop with the Clone URL of your device that is displayed with the device in the Pantacor Hub dashboard. 

$ pvr clone presently_learning_pelican

Now your device is ready to deploy your Redis app

Deploy the Redis container to the device:

Step 1: Add “redis” to the device and deploy

Add “redis” container app

$ pvr app add redis --from=arm32v7/redis:latest

Deploy the changes

 $ pvr add .
 $ pvr commit
 $ pvr post

Step 2: Access Redis through the shell and test it: 

redis-cli -h

You are Done!


Final Thoughts

In this tutorial, we described how to deploy a containerized version of Redis into your Pantavisor-enabled device. Pantavisor doesn’t run Docker containers natively, but it does use Docker images as a great source of root file systems for containers that are run by the Pantavisor with LXC.

Take a deeper dive into managing Pantavisor Linux with Pantabox.

We’re really excited for you to try Pantabox and Pantavisor Linux and we’d love to hear your thoughts. Try one of the guides or join us in the Pantavisor community forum.