如何在Hue中使用Sentry建立角色,受权

参照官方文档:http://gethue.com/apache-sentry-made-easy-with-the-new-hue-security-app/#howtoapache

在sentry的admin group中加入你的hue管理员帐户的组
如何在Hue中使用Sentry建立角色,受权app

打开hue配置,进入如何在Hue中使用Sentry建立角色,受权
[libsentry]
#sentry服务所在的节点ip
hostname=sentry
#sentry服务的ipc端口
port=8038
#hue的节点上sentry-site.xml的路径(若是没有copy一份过来)
sentry_conf_dir=/etc/sentry/confide

配置内容(仅供参考)
<configuration>
<property>
    <name>sentry.service.security.mode</name>
    <value>none</value>
</property>
<property>
    <name>sentry.service.admin.group</name>
    <value>hive,impala,hue,solr,kafka,hbase,spark2,bigdataadmin</value>
</property>
<property>
    <name>sentry.service.allow.connect</name>
    <value>impala,hive,solr</value>
</property>
<property>
    <name>sentry.store.jdbc.url</name>
    <value>jdbc:derby:;databaseName=sentry_store_db;create=true</value>
</property>
<property>
    <name>sentry.store.jdbc.driver</name>
    <value>org.apache.derby.jdbc.EmbeddedDriver</value>
</property>
    </configuration>

其中sentry.service.admin.group这一项必定要和sentry服务端保持一致,必定要把你的hue管理员帐户填上,不然后面受权的页面会缺乏受权按钮,由于hue不知道你是sentry的admin用户,认为你没有权限。url

最后在hue的用户组中,添加管理员相应的用户组,其实就是和ldap中系统的用户组保持一致,好比个人用户bigdataadmin,组名就也叫bigdataadmin,这样才能够和sentry中的配置项sentry.service.admin.group对应上。spa

全部步骤都完成后,便可在hue界面进行受权了。3d

进入sentry管理页面:

如何在Hue中使用Sentry建立角色,受权

添加角色和受权

如何在Hue中使用Sentry建立角色,受权
如何在Hue中使用Sentry建立角色,受权

相关文章
相关标签/搜索