Skip to content

Commit

Permalink
README: add command to generate key on cli (#135)
Browse files Browse the repository at this point in the history
  • Loading branch information
gianluca-mascolo authored Feb 17, 2023
1 parent 2354899 commit 88289a3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,10 @@ To cache tokens on Redis you'll need to generate a `cache_encryption_key`. This
```elixir
:crypto.strong_rand_bytes(32) |> Base.encode64()
```

Alternatively you can generate it on command line (Linux/MacOSX) with:
```
dd if=/dev/random bs=1 count=32 | base64
```
> :warning: **The token needs to be 32 bytes long AND base64 encoded**, failing to do so will result in tokens not getting cached on Redis. :warning:
## Usage
Expand Down

0 comments on commit 88289a3

Please sign in to comment.