Tutorials for this topic
Install PostgreSQL on Ubuntu/Debian, create a database user and database, local access, and basic hardening for your applications.
Install Redis on Ubuntu/Debian, start the service, test with redis-cli, and apply minimal settings for cache, sessions, and queues.