Skip to content

Commit bd26fd4

Browse files
authored
Merge pull request #90 from linuxfoundation/andrest50/openfga-model
Change how viewer relation is calculated for past-meeting recording/transcript/summary types
2 parents a34ef5c + 369eb07 commit bd26fd4

File tree

3 files changed

+49
-33
lines changed

3 files changed

+49
-33
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
*~
1414
.env
1515
*.env
16+
values.local.yaml
1617

1718
# Rendered templates
1819
**/templates/*.rendered

charts/lfx-platform/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ apiVersion: v2
55
name: lfx-platform
66
description: LFX Platform v2 Helm chart
77
type: application
8-
version: 0.3.16
8+
version: 0.3.17
99
icon: https://github.com/linuxfoundation/lfx-v2-helm/raw/main/img/lfx-logo-color.svg
1010
dependencies:
1111
- name: traefik

charts/lfx-platform/templates/openfga/model.yaml

Lines changed: 47 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ spec:
2020
*/}}
2121
- version:
2222
major: 7
23-
minor: 0
24-
patch: 1
23+
minor: 1
24+
patch: 0
2525
authorizationModel: |
2626
model
2727
schema 1.1
@@ -152,16 +152,14 @@ spec:
152152
define auditor: auditor from past_meeting
153153
define host: host from past_meeting
154154
define participant: invitee from past_meeting or attendee from past_meeting
155-
# The viewer relation needs to be kept up-to-date separately from the other relations
156-
# because it depends on the past meeting artifact_visibility setting. Auditors and writers
157-
# do however by default have access to view the recording.
158-
#
155+
# The following "participant access by related meeting" relations are conditional
156+
# because they depend on the past meeting artifact_visibility setting. Auditors
157+
# and writers do however by default have access to view the recording.
158+
define past_meeting_for_participant_view: [past_meeting]
159+
define past_meeting_for_attendee_view: [past_meeting]
160+
define past_meeting_for_host_view: [past_meeting]
159161
# If the artifact_visibility is public, then every user should be a viewer
160-
# If it is set to only meeting participants, then only the meeting participants
161-
# should be able to view the recording.
162-
# If it is set to only meeting hosts, then only the meeting hosts should be able
163-
# to view the recording.
164-
define viewer: [user, user:*] or writer or auditor
162+
define viewer: [user, user:*] or writer or auditor or invitee from past_meeting_for_participant_view or attendee from past_meeting_for_attendee_view or host from past_meeting_for_host_view
165163
166164
# The past_meeting_transcript type identifies a transcript of a past meeting.
167165
# Access to a transcript is limited to one of the following groups:
@@ -175,16 +173,14 @@ spec:
175173
define auditor: auditor from past_meeting
176174
define host: host from past_meeting
177175
define participant: invitee from past_meeting or attendee from past_meeting
178-
# The viewer relation needs to be kept up-to-date separately from the other relations
179-
# because it depends on the past meeting artifact_visibility setting. Auditors and writers
180-
# do however by default have access to view the transcript.
181-
#
176+
# The following "participant access by related meeting" relations are conditional
177+
# because they depend on the past meeting artifact_visibility setting. Auditors
178+
# and writers do however by default have access to view the transcript.
179+
define past_meeting_for_participant_view: [past_meeting]
180+
define past_meeting_for_attendee_view: [past_meeting]
181+
define past_meeting_for_host_view: [past_meeting]
182182
# If the artifact_visibility is public, then every user should be a viewer
183-
# If it is set to only meeting participants, then only the meeting participants
184-
# should be able to view the transcript.
185-
# If it is set to only meeting hosts, then only the meeting hosts should be able
186-
# to view the transcript.
187-
define viewer: [user, user:*] or writer or auditor
183+
define viewer: [user, user:*] or writer or auditor or invitee from past_meeting_for_participant_view or attendee from past_meeting_for_attendee_view or host from past_meeting_for_host_view
188184
189185
# The past_meeting_summary type identifies a summary of a past meeting.
190186
# Access to a summary is limited to one of the following groups:
@@ -198,16 +194,14 @@ spec:
198194
define auditor: auditor from past_meeting
199195
define host: host from past_meeting
200196
define participant: invitee from past_meeting or attendee from past_meeting
201-
# The viewer relation needs to be kept up-to-date separately from the other relations
202-
# because it depends on the past meeting artifact_visibility setting. Auditors and writers
203-
# do however by default have access to view the summary.
204-
#
197+
# The following "participant access by related meeting" relations are conditional
198+
# because they depend on the past meeting artifact_visibility setting. Auditors
199+
# and writers do however by default have access to view the summary.
200+
define past_meeting_for_participant_view: [past_meeting]
201+
define past_meeting_for_attendee_view: [past_meeting]
202+
define past_meeting_for_host_view: [past_meeting]
205203
# If the artifact_visibility is public, then every user should be a viewer
206-
# If it is set to only meeting participants, then only the meeting participants
207-
# should be able to view the summary.
208-
# If it is set to only meeting hosts, then only the meeting hosts should be able
209-
# to view the summary.
210-
define viewer: [user, user:*] or writer or auditor
204+
define viewer: [user, user:*] or writer or auditor or invitee from past_meeting_for_participant_view or attendee from past_meeting_for_attendee_view or host from past_meeting_for_host_view
211205
212206
# The following v1 meeting types support read-only, indexer-only data
213207
# being synced from LFX v1. At this time, they are *distinct types*
@@ -253,7 +247,14 @@ spec:
253247
define auditor: auditor from past_meeting
254248
define host: host from past_meeting
255249
define participant: invitee from past_meeting or attendee from past_meeting
256-
define viewer: [user, user:*] or writer or auditor
250+
# The following "participant access by related meeting" relations are conditional
251+
# because they depend on the past meeting artifact_visibility setting. Auditors
252+
# and writers do however by default have access to view the recording.
253+
define past_meeting_for_participant_view: [v1_past_meeting]
254+
define past_meeting_for_attendee_view: [v1_past_meeting]
255+
define past_meeting_for_host_view: [v1_past_meeting]
256+
# If the artifact_visibility is public, then every user should be a viewer
257+
define viewer: [user:*] or writer or auditor or invitee from past_meeting_for_participant_view or attendee from past_meeting_for_attendee_view or host from past_meeting_for_host_view
257258
258259
# *All relations are as described in `past_meeting_transcript`, unless
259260
# otherwise noted.*
@@ -264,7 +265,14 @@ spec:
264265
define auditor: auditor from past_meeting
265266
define host: host from past_meeting
266267
define participant: invitee from past_meeting or attendee from past_meeting
267-
define viewer: [user, user:*] or writer or auditor
268+
# The following "participant access by related meeting" relations are conditional
269+
# because they depend on the past meeting artifact_visibility setting. Auditors
270+
# and writers do however by default have access to view the transcript.
271+
define past_meeting_for_participant_view: [v1_past_meeting]
272+
define past_meeting_for_attendee_view: [v1_past_meeting]
273+
define past_meeting_for_host_view: [v1_past_meeting]
274+
# If the artifact_visibility is public, then every user should be a viewer
275+
define viewer: [user:*] or writer or auditor or invitee from past_meeting_for_participant_view or attendee from past_meeting_for_attendee_view or host from past_meeting_for_host_view
268276
269277
type v1_past_meeting_summary
270278
relations
@@ -273,5 +281,12 @@ spec:
273281
define auditor: auditor from past_meeting
274282
define host: host from past_meeting
275283
define participant: invitee from past_meeting or attendee from past_meeting
276-
define viewer: [user, user:*] or writer or auditor
284+
# The following "participant access by related meeting" relations are conditional
285+
# because they depend on the past meeting artifact_visibility setting. Auditors
286+
# and writers do however by default have access to view the summary.
287+
define past_meeting_for_participant_view: [v1_past_meeting]
288+
define past_meeting_for_attendee_view: [v1_past_meeting]
289+
define past_meeting_for_host_view: [v1_past_meeting]
290+
# If the artifact_visibility is public, then every user should be a viewer
291+
define viewer: [user:*] or writer or auditor or invitee from past_meeting_for_participant_view or attendee from past_meeting_for_attendee_view or host from past_meeting_for_host_view
277292
{{- end }}

0 commit comments

Comments
 (0)