Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
fordecyt_2019
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Rodrigo Tapia-McClung
fordecyt_2019
Commits
b783d316
Commit
b783d316
authored
Sep 05, 2019
by
Rodrigo Tapia-McClung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update README
parent
3f2f1b0f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
+5
-3
README.md
README.md
+5
-3
No files found.
README.md
View file @
b783d316
...
...
@@ -22,15 +22,17 @@ CREATE ROLE readaccess;
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
;
-- Create a final user with password
CREATE
USER
<
user
>
WITH
PASSWORD
'<pw>'
;
GRANT
readaccess
TO
<
user
>
;
GRANT
SELECT
ON
ALL
TABLES
IN
SCHEMA
public
TO
<
user
>
;
```
-- Grant access to future tables on role and user
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO readaccess;
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO
<user>
;
Make sure to edit /etc/postgresql/10/main/pg_hba.conf line
`local all all peer`
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment