diff --git a/support-files/bkiam/0011_bk_job_20230818-1000_iam.json b/support-files/bkiam/0011_bk_job_20230818-1000_iam.json new file mode 100644 index 0000000000..231929eca4 --- /dev/null +++ b/support-files/bkiam/0011_bk_job_20230818-1000_iam.json @@ -0,0 +1,293 @@ +{ + "system_id": "bk_job", + "operations": [ + { + "operation": "upsert_action", + "data": { + "id": "quick_execute_script", + "name": "快速执行脚本", + "name_en": "Script Execution (Quick Launch)", + "description": "使用快速执行功能进行脚本/命令执行的权限", + "description_en": "Permission of quick launch script", + "type": "", + "related_actions": [ + "access_business" + ], + "related_resource_types": [ + { + "system_id": "bk_cmdb", + "id": "host", + "selection_mode": "all", + "related_instance_selections": [ + { + "system_id": "bk_cmdb", + "id": "biz_host_instance", + "ignore_iam_path": true + }, + { + "system_id": "bk_cmdb", + "id": "biz_custom_query" + }, + { + "system_id": "bk_cmdb", + "id": "business_set_list" + } + ] + } + ], + "version": 1 + } + }, + { + "operation": "upsert_action", + "data": { + "id": "quick_transfer_file", + "name": "快速分发文件", + "name_en": "File Transfer (Quick Launch)", + "description": "使用快速执行功能进行文件分发的权限", + "description_en": "Permission of quick transfer files", + "type": "", + "related_actions": [ + "access_business" + ], + "related_resource_types": [ + { + "system_id": "bk_cmdb", + "id": "host", + "selection_mode": "all", + "related_instance_selections": [ + { + "system_id": "bk_cmdb", + "id": "biz_host_instance", + "ignore_iam_path": true + }, + { + "system_id": "bk_cmdb", + "id": "biz_custom_query" + }, + { + "system_id": "bk_cmdb", + "id": "business_set_list" + } + ] + } + ], + "version": 1 + } + }, + { + "operation": "upsert_action", + "data": { + "id": "execute_script", + "name": "脚本执行", + "name_en": "Execute script", + "description": "执行某些业务(集)下的脚本", + "description_en": "Permission of launch scripts", + "type": "", + "related_actions": [ + "access_business", + "view_script" + ], + "related_resource_types": [ + { + "system_id": "bk_job", + "id": "script", + "selection_mode": "instance", + "related_instance_selections": [ + { + "system_id": "bk_job", + "id": "script_list_of_biz", + "ignore_iam_path": true + }, + { + "system_id": "bk_job", + "id": "script_list_of_biz_set", + "ignore_iam_path": true + } + ] + }, + { + "system_id": "bk_cmdb", + "id": "host", + "selection_mode": "all", + "related_instance_selections": [ + { + "system_id": "bk_cmdb", + "id": "biz_host_instance", + "ignore_iam_path": true + }, + { + "system_id": "bk_cmdb", + "id": "biz_custom_query" + }, + { + "system_id": "bk_cmdb", + "id": "business_set_list" + } + ] + } + ], + "version": 1 + } + }, + { + "operation": "upsert_action", + "data": { + "id": "debug_job_template", + "name": "作业模板调试", + "name_en": "Debug Job Template", + "description": "作业模板的调试权限,因场景特殊性,所以与执行方案的权限区分开来", + "description_en": "Permission of debuging Job template", + "type": "", + "related_actions": [ + "access_business", + "view_job_template" + ], + "related_resource_types": [ + { + "system_id": "bk_job", + "id": "job_template", + "selection_mode": "instance", + "related_instance_selections": [ + { + "system_id": "bk_job", + "id": "job_template_list_of_biz", + "ignore_iam_path": true + }, + { + "system_id": "bk_job", + "id": "job_template_list_of_biz_set", + "ignore_iam_path": true + } + ] + }, + { + "system_id": "bk_cmdb", + "id": "host", + "selection_mode": "all", + "related_instance_selections": [ + { + "system_id": "bk_cmdb", + "id": "biz_host_instance", + "ignore_iam_path": true + }, + { + "system_id": "bk_cmdb", + "id": "biz_custom_query" + }, + { + "system_id": "bk_cmdb", + "id": "business_set_list" + } + ] + } + ], + "version": 1 + } + }, + { + "operation": "upsert_action", + "data": { + "id": "launch_job_plan", + "name": "执行方案运行", + "name_en": "Launch Job Plan", + "description": "运行作业执行方案的权限", + "description_en": "Permission of launch plan under the Job template", + "type": "", + "related_actions": [ + "access_business", + "view_job_plan" + ], + "related_resource_types": [ + { + "system_id": "bk_job", + "id": "job_plan", + "selection_mode": "instance", + "related_instance_selections": [ + { + "system_id": "bk_job", + "id": "job_plan_list_of_biz", + "ignore_iam_path": true + }, + { + "system_id": "bk_job", + "id": "job_plan_list_of_biz_set", + "ignore_iam_path": true + } + ] + }, + { + "system_id": "bk_cmdb", + "id": "host", + "selection_mode": "all", + "related_instance_selections": [ + { + "system_id": "bk_cmdb", + "id": "biz_host_instance", + "ignore_iam_path": true + }, + { + "system_id": "bk_cmdb", + "id": "biz_custom_query" + }, + { + "system_id": "bk_cmdb", + "id": "business_set_list" + } + ] + } + ], + "version": 1 + } + }, + { + "operation": "upsert_action", + "data": { + "id": "execute_public_script", + "name": "公共脚本执行", + "name_en": "Execute Public Script", + "description": "引用公共脚本在指定业务(集)的主机下执行的权限", + "description_en": "Permission of launch public script with specified host under business", + "type": "", + "related_actions": [ + "view_public_script" + ], + "related_resource_types": [ + { + "system_id": "bk_job", + "id": "public_script", + "selection_mode": "instance", + "related_instance_selections": [ + { + "system_id": "bk_job", + "id": "public_script_list", + "ignore_iam_path": true + } + ] + }, + { + "system_id": "bk_cmdb", + "id": "host", + "selection_mode": "all", + "related_instance_selections": [ + { + "system_id": "bk_cmdb", + "id": "biz_host_instance", + "ignore_iam_path": true + }, + { + "system_id": "bk_cmdb", + "id": "biz_custom_query" + }, + { + "system_id": "bk_cmdb", + "id": "business_set_list" + } + ] + } + ], + "version": 1 + } + } + ] +}