[chef] A weird template file


Chronological Thread 
  • From: Sam Su < >
  • To:
  • Subject: [chef] A weird template file
  • Date: Fri, 20 Sep 2013 22:48:14 +0800

Hi,

I am learning chef with some real cookbooks, here is the one of my learning cookbooks link: https://github.com/stackforge/cookbook-openstack-network

Usually I add a recipe (e.g. openstack-network::openvswitch) into a node's run list, then run and check the result at the client node.

I found that the file /etc/quantum/quantum.conf is a different result than expected in the template file quantum.conf.erb.

The weird part of the quantum.conf is shown as below, we can see the line started with rpc_backend (red text):
# =========== items for agent scheduler extension =============
# Driver to use for scheduling network to DHCP agent
network_scheduler_driver = quantum.scheduler.dhcp_agent_scheduler.ChanceScheduler
# Driver to use for scheduling router to a default L3 agent
router_scheduler_driver = quantum.scheduler.l3_agent_scheduler.ChanceScheduler
rpc_backend = quantum.openstack.common.rpc.impl_qpid

# Allow auto scheduling networks to DHCP agent. It will schedule non-hosted
...

However at the original template file quantum.conf.erb (shown at the following) I cannot find the line at the same location:
# =========== items for agent scheduler extension =============
# Driver to use for scheduling network to DHCP agent
network_scheduler_driver = <%= node["openstack"]["network"]["dhcp"]["scheduler"] %>
# Driver to use for scheduling router to a default L3 agent
router_scheduler_driver = <%= node["openstack"]["network"]["l3"]["scheduler"] %>

# Allow auto scheduling networks to DHCP agent. It will schedule non-hosted
...


I tried to search the whole cookbook with the key words "rpc_backend" or "quantum.conf.erb" but no help.

I am wondering where the line ("rpc_backend  ...") comes from in the file quantum.conf. 
It has puzzled me for several days, if someone can help me out, it will be much appreciated.


Thanks,
Sam


  • [chef] A weird template file, Sam Su, 09/20/2013

Archive powered by MHonArc 2.6.16.

§