]> git.proxmox.com Git - ceph.git/blob - ceph/src/arrow/dev/benchmarking/ddl/5_00_permissions.sql
import quincy 17.2.0
[ceph.git] / ceph / src / arrow / dev / benchmarking / ddl / 5_00_permissions.sql
1 /*
2 Licensed to the Apache Software Foundation (ASF) under one
3 or more contributor license agreements. See the NOTICE file
4 distributed with this work for additional information
5 regarding copyright ownership. The ASF licenses this file
6 to you under the Apache License, Version 2.0 (the
7 "License"); you may not use this file except in compliance
8 with the License. You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12 Unless required by applicable law or agreed to in writing,
13 software distributed under the License is distributed on an
14 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 KIND, either express or implied. See the License for the
16 specific language governing permissions and limitations
17 under the License.
18 */
19 ---------------------------- ROLES ----------------------------
20 -- ARROW_WEB
21 CREATE ROLE arrow_web login password 'arrow';
22 COMMENT ON ROLE arrow_web IS 'Anonymous login user.';
23
24 -- ARROW_ADMIN
25 CREATE ROLE arrow_admin;
26 COMMENT ON ROLE arrow_admin
27 IS 'Can select, insert, update, and delete on all public tables.';
28
29 -- ARROW_ANONYMOUS
30 CREATE ROLE arrow_anonymous;
31 COMMENT ON ROLE arrow_anonymous
32 IS 'Can insert and select on all public tables.';
33
34 GRANT arrow_anonymous TO arrow_web;
35
36
37 ---------------------------- PRIVILEGES ----------------------------
38 GRANT USAGE ON SCHEMA public TO arrow_anonymous, arrow_admin;
39
40 -- ARROW_ADMIN
41 GRANT EXECUTE ON ALL FUNCTIONS IN SCHEMA public TO arrow_admin;
42 GRANT USAGE, SELECT ON ALL SEQUENCES IN SCHEMA public to arrow_admin;
43 GRANT SELECT, UPDATE, INSERT, DELETE ON ALL TABLES IN SCHEMA public
44 TO arrow_admin;
45
46 -- ARROW_ANONYMOUS
47 GRANT EXECUTE ON ALL FUNCTIONS IN SCHEMA public TO arrow_anonymous;
48 GRANT SELECT ON ALL TABLES IN SCHEMA public TO arrow_anonymous;
49 GRANT USAGE, SELECT ON ALL SEQUENCES IN SCHEMA public to arrow_anonymous;
50 GRANT INSERT ON
51 public.benchmark
52 , public.benchmark_language
53 , public.dependencies
54 , public.language_implementation_version
55 , public.benchmark_run
56 , public.benchmark_type
57 , public.cpu
58 , public.environment
59 , public.environment_view
60 , public.gpu
61 , public.machine
62 , public.machine_view
63 , public.os
64 , public.unit
65 --, public.project -- The only disallowed table is `project`.
66 , public.benchmark_run_view
67 , public.benchmark_view
68 , public.environment_view
69 , public.full_benchmark_run_view
70 , public.language_implementation_version_view
71 , public.machine_view
72 , public.unit_view
73 TO arrow_anonymous;