You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "Andrew Stahlman (JIRA)" <ji...@apache.org> on 2019/02/01 20:57:00 UTC
[jira] [Commented] (AIRFLOW-2694) Allow parsing access control in
DAG file
[ https://issues.apache.org/jira/browse/AIRFLOW-2694?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16758660#comment-16758660 ]
Andrew Stahlman commented on AIRFLOW-2694:
------------------------------------------
[~TaoFeng] one suggestion on the interface - instead of:
{code:java}
dag = DAG('mydag', access_control={`role`: [ 'custom_role1'], `perm`: `can_dag_read` }, ...)
{code}
how about either: (roles -> permissions)
{code:java}
dag = DAG('mydag', access_control={'custom_role1': ['can_dag_read'],
'custom_role2': ['can_dag_edit'],
}, ...)
{code}
or, the inverse (permissions -> roles)
{code:java}
dag = DAG('mydag', access_control={'can_dag_read': ['custom_role1'],
'can_dag_edit': ['custom_role2'],
}, ...)
{code}
> Allow parsing access control in DAG file
> ----------------------------------------
>
> Key: AIRFLOW-2694
> URL: https://issues.apache.org/jira/browse/AIRFLOW-2694
> Project: Apache Airflow
> Issue Type: New Feature
> Reporter: Tao Feng
> Assignee: Tao Feng
> Priority: Major
>
> After AIRFLOW-2267 is checkedin, modify DAG parsing logic to allow user passing permission logic through DAG file like the following example:
>
> dag = DAG('mydag', access_control=\{`role`: [ 'custom_role1'], `perm`: `can_dag_read` }, ...)
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)