GRANT ALL PRIVILEGESON heat.* TO'heat'@'localhost' \ IDENTIFIEDBY'HEAT_DBPASS'; GRANT ALL PRIVILEGESON heat.* TO'heat'@'%' \ IDENTIFIEDBY'HEAT_DBPASS'; exit
导入 admin身份凭证以执行管理员用户专有的命令:
# source admin-openrc.sh
创建 heat user:
# openstack user create heat --password heat
添加 admin role to the heat user:
# openstack role add --project service --user heat admin
创建 heat_stack_owner role:
# openstack role create heat_stack_owner
添加 heat_stack_owner role to the demo tenant and user:
# openstack role add --project demo --user demo heat_stack_owner
[Note] You must add the heat_stack_owner role to users that manage stacks.
创建 heat_stack_user role:
# openstack role create heat_stack_user
[Note] The Orchestration service automatically assigns the heat_stack_user role to users that it creates during stack deployment. By default, this role restricts API operations. To avoid conflicts, do not add this role to users with the heat_stack_owner role.
创建 heat and heat-cfn service entities:
# openstack service create--name heat \ --description "Orchestration" orchestration
# openstack service create--name heat-cfn \ --description "Orchestration" cloudformation
The Orchestration module uses templates to describe stacks. To learn about the template language, see the Template Guide in the Heat developer documentation.
Create a test template in the test-stack.yml file with the following content:
echo "heat_template_version: 2014-10-16 description: A simple server.
parameters: ImageID: type: string description: Image useto boot a server NetID: type: string description: Network IDfor the server