Skip to content

Instantly share code, notes, and snippets.

@juanhuttemann
Created July 10, 2017 00:40
Show Gist options
  • Save juanhuttemann/b8f6d7b97b1d68e9d7cc03f8f16fa269 to your computer and use it in GitHub Desktop.
Save juanhuttemann/b8f6d7b97b1d68e9d7cc03f8f16fa269 to your computer and use it in GitHub Desktop.
Adds Rails Secret Key to user profile as Env Variable
#!/bin/bash
OUTPUT="$(rails secret RAILS_ENV=production)"
SECRET="SECRET_KEY_BASE=${OUTPUT}"
echo $SECRET >> ~/.profile
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment