I was following a tutorial to use PostgreSQL with a server application (both are running on the same computer). The tutorial was using SQL commands, but I used pgAdmin. I added a new user 'gitea' with "Can login?" checked and a password. I created a database 'giteadb' with the owner as 'gitea'. In the later step the tutorial says:
Allow the database user to access the database created above by adding the following authentication rule to pg_hba.conf.
For local database:
local giteadb gitea scram-sha-256
Restart PostgreSQL to apply new authentication rules
If I set "Can login" and a password for the user, why do I have to add the user to the pg_hba.conf? Editing a conf file hidden somewhere in the system and restarting a service is pain in the lower back. Is the document correct that this process of adding the new user to the conf and restarting the DB is mandatory?