Skip to main content

Redis

Install Redis

To install Redis you first need add their repository.

curl -fsSL https://packages.redis.io/gpg | sudo gpg --dearmor -o /usr/share/keyrings/redis-archive-keyring.gpg
echo "deb [signed-by=/usr/share/keyrings/redis-archive-keyring.gpg] https://packages.redis.io/deb $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/redis.list

Now you can install Redis by simply running the following commands.

sudo apt update -y
sudo apt install -y redis-server

Also make sure to enable that redis will start on boot. You can do that by running the following command:

sudo systemctl enable --now redis-server

Setup Pelican for Redis

Use Redis as driver

You can use the following commands to use Redis as Cache, Queue and Session driver.

When asked choose redis for the driver and enter your redis data. For all other options you can simply hit Enter to use the default values.

cd /var/www/pelican

php artisan p:environment:cache
php artisan p:environment:queue
php artisan p:environment:session