I\'m trying out the PHP micro Framework Lumen (from Laravel).
One of my first steps was to look into the .env.example file and make a copy of it to have my
.env.example
An easy solution is just running PHP code from the terminal (without using tinker, because that is not available with Lumen):
tinker
php -r "require 'vendor/autoload.php'; echo str_random(32).PHP_EOL;"
It uses Laravel's Str::random() function that makes use of the secure random_bytes() function.
Str::random()
random_bytes()