diff --git a/tasks/heat_post_install.yml b/tasks/heat_post_install.yml index 1d4b820..4640022 100644 --- a/tasks/heat_post_install.yml +++ b/tasks/heat_post_install.yml @@ -39,9 +39,12 @@ dest: "/etc/heat/templates/AWS_RDS_DBInstance.yaml" config_overrides: "{{ heat_aws_rds_dbinstance_yaml_overrides }}" config_type: "yaml" - - src: "policy.json.j2" - dest: "/etc/heat/policy.json" - config_overrides: "{{ heat_policy_overrides }}" - config_type: "json" notify: - Restart heat services + +- name: Implement policy.json if there are overrides configured + copy: + content: "{{ heat_policy_overrides | to_nice_json }}" + dest: "/etc/heat/policy.json" + when: + - heat_policy_overrides != {} diff --git a/templates/policy.json.j2 b/templates/policy.json.j2 deleted file mode 100644 index fa57861..0000000 --- a/templates/policy.json.j2 +++ /dev/null @@ -1,15 +0,0 @@ -{ - "cloudformation:ListStacks": "rule:deny_stack_user", - "cloudformation:CreateStack": "rule:deny_stack_user", - "cloudformation:DescribeStacks": "rule:deny_stack_user", - "cloudformation:DeleteStack": "rule:deny_stack_user", - "cloudformation:UpdateStack": "rule:deny_stack_user", - "cloudformation:CancelUpdateStack": "rule:deny_stack_user", - "cloudformation:DescribeStackEvents": "rule:deny_stack_user", - "cloudformation:ValidateTemplate": "rule:deny_stack_user", - "cloudformation:GetTemplate": "rule:deny_stack_user", - "cloudformation:EstimateTemplateCost": "rule:deny_stack_user", - "cloudformation:DescribeStackResource": "", - "cloudformation:DescribeStackResources": "rule:deny_stack_user", - "cloudformation:ListStackResources": "rule:deny_stack_user", -}