From 084e8c2950d4bd843ae1fcd40b39510a18e435b4 Mon Sep 17 00:00:00 2001 From: Anwar Knyane <21956329+anvarknian@users.noreply.github.com> Date: Tue, 14 Nov 2023 13:31:33 -0300 Subject: [PATCH] make the jwt generation easier :) (#697) --- docs/tutorials/tut1.rst | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/docs/tutorials/tut1.rst b/docs/tutorials/tut1.rst index 33ef764e7..634e47e3e 100644 --- a/docs/tutorials/tut1.rst +++ b/docs/tutorials/tut1.rst @@ -41,16 +41,15 @@ Let's create a password and provide it to PostgREST. Think of a nice long one, o export LC_CTYPE=C # read random bytes and keep only alphanumerics - < /dev/urandom tr -dc A-Za-z0-9 | head -c32 + echo "jwt-secret = \"$(< /dev/urandom tr -dc A-Za-z0-9 | head -c32)\"" >> tutorial.conf -Open the :code:`tutorial.conf` (created in the previous tutorial) and add a line with the password: + +check the :code:`tutorial.conf` (created in the previous tutorial) the line with the password: .. code-block:: ini # PASSWORD MUST BE AT LEAST 32 CHARS LONG - # add this line to tutorial.conf: - - jwt-secret = "" + cat tutorial.conf If the PostgREST server is still running from the previous tutorial, restart it to load the updated configuration file.