Rename pass_deploy_info to heartbeat
by default, Ironic's API routing now exposes only 'lookup' and 'heartbeat' vendor passthru methods of drivers as public routes [0]. Rename the vendor passtru method 'pass_deploy_info' of fuel-agent driver to 'heartbeat' to make it accessable w/o authentication by callback script. In the Ocata cycle, this also will be removed and fuel-agent driver must switch to the root 'heartbeat' API (/v1/heartbeat/node-uuid>). [0] https://github.com/openstack/ironic/blob/master/ironic/api/config.py#L37 Change-Id: Ie1dbd8a8aac62034beba88ecd206a8e7712514e2
This commit is contained in:
parent
ecd7a67ee0
commit
cb77827303
|
@ -50,7 +50,7 @@ from ironic.drivers.modules import image_cache
|
|||
agent_opts = [
|
||||
cfg.StrOpt('pxe_config_template',
|
||||
default=os.path.join(os.path.dirname(__file__),
|
||||
'fuel_config.template'),
|
||||
'fuel_config.template'),
|
||||
help='Template file for PXE configuration.'),
|
||||
cfg.StrOpt('deploy_kernel',
|
||||
help='UUID (from Glance) of the default deployment kernel.'),
|
||||
|
@ -492,7 +492,7 @@ class FuelAgentVendor(base.VendorInterface):
|
|||
|
||||
@base.passthru(['POST'])
|
||||
@task_manager.require_exclusive_lock
|
||||
def pass_deploy_info(self, task, **kwargs):
|
||||
def heartbeat(self, task, **kwargs):
|
||||
"""Continues the deployment of baremetal node."""
|
||||
|
||||
node = task.node
|
||||
|
|
|
@ -69,8 +69,8 @@ def main():
|
|||
"error_message": "no errors"}
|
||||
|
||||
passthru = '%(api-url)s/v1/nodes/%(deployment_id)s/vendor_passthru' \
|
||||
'/pass_deploy_info' % {'api-url': api_url,
|
||||
'deployment_id': deployment_id}
|
||||
'/heartbeat' % {'api-url': api_url,
|
||||
'deployment_id': deployment_id}
|
||||
try:
|
||||
resp = requests.post(passthru, data=json.dumps(data),
|
||||
headers={'Content-Type': 'application/json',
|
||||
|
|
Loading…
Reference in New Issue