For educational reasons I've decided to create my own CA. Here is what I learned.
Lets get some context first.
| DROP TABLE IF EXISTS foo; | |
| CREATE TEMPORARY TABLE foo (x FLOAT); | |
| INSERT INTO foo VALUES (1); | |
| INSERT INTO foo VALUES (2); | |
| INSERT INTO foo VALUES (3); | |
| INSERT INTO foo VALUES (4); | |
| INSERT INTO foo VALUES (100); | |
| SELECT avg(x), tmean(x, 2.0), tmean(x, 1.5) FROM foo; | 
| -- Create a group | |
| CREATE ROLE readaccess; | |
| -- Grant access to existing tables | |
| GRANT USAGE ON SCHEMA public TO readaccess; | |
| GRANT SELECT ON ALL TABLES IN SCHEMA public TO readaccess; | |
| -- Grant access to future tables | |
| ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess; | 
Here are the simple steps needed to create a deployment from your lokal GIT repository to a server based on this in-depth tutorial.
You are developing in a working-copy on your local machine, lets say on the master branch. Most of the time, people would push code to a remote server like github.com or gitlab.com and pull or export it to a production server. Or you use a service like my Deepl.io to act upon a Web-Hook that's triggered that service.