Merge "Use OS::Heat::DeployedServer"
This commit is contained in:
commit
7246700889
@ -1,22 +0,0 @@
|
|||||||
heat_template_version: 2014-10-16
|
|
||||||
parameters:
|
|
||||||
user_data_format:
|
|
||||||
type: string
|
|
||||||
default: SOFTWARE_CONFIG
|
|
||||||
|
|
||||||
resources:
|
|
||||||
# We just need something which returns a unique ID, but we can't
|
|
||||||
# use RandomString because RefId returns the value, not the physical
|
|
||||||
# resource ID, SoftwareConfig should work as it returns a UUID
|
|
||||||
deployed-server-config:
|
|
||||||
type: OS::Heat::SoftwareConfig
|
|
||||||
|
|
||||||
outputs:
|
|
||||||
# FIXME(shardy) this is needed because TemplateResource returns an
|
|
||||||
# ARN not a UUID, which overflows the Deployment server_id column..
|
|
||||||
user_data_format:
|
|
||||||
value: SOFTWARE_CONFIG
|
|
||||||
OS::stack_id:
|
|
||||||
value: {get_resource: deployed-server-config}
|
|
||||||
|
|
||||||
|
|
@ -21,7 +21,7 @@ parameters:
|
|||||||
default: ''
|
default: ''
|
||||||
name:
|
name:
|
||||||
type: string
|
type: string
|
||||||
default: ''
|
default: 'deployed-server'
|
||||||
image_update_policy:
|
image_update_policy:
|
||||||
type: string
|
type: string
|
||||||
default: ''
|
default: ''
|
||||||
@ -40,20 +40,18 @@ parameters:
|
|||||||
default: {}
|
default: {}
|
||||||
|
|
||||||
resources:
|
resources:
|
||||||
# We just need something which returns a unique ID, but we can't
|
|
||||||
# use RandomString because RefId returns the value, not the physical
|
|
||||||
# resource ID, SoftwareConfig should work as it returns a UUID
|
|
||||||
deployed-server:
|
deployed-server:
|
||||||
type: OS::TripleO::DeployedServerConfig
|
type: OS::Heat::DeployedServer
|
||||||
properties:
|
properties:
|
||||||
user_data_format: SOFTWARE_CONFIG
|
name: {get_param: name}
|
||||||
|
software_config_transport: {get_param: software_config_transport}
|
||||||
|
|
||||||
InstanceIdConfig:
|
InstanceIdConfig:
|
||||||
type: OS::Heat::StructuredConfig
|
type: OS::Heat::StructuredConfig
|
||||||
properties:
|
properties:
|
||||||
group: apply-config
|
group: apply-config
|
||||||
config:
|
config:
|
||||||
instance-id: {get_attr: [deployed-server, "OS::stack_id"]}
|
instance-id: {get_resource: deployed-server}
|
||||||
|
|
||||||
InstanceIdDeployment:
|
InstanceIdDeployment:
|
||||||
type: OS::Heat::StructuredDeployment
|
type: OS::Heat::StructuredDeployment
|
||||||
@ -88,10 +86,8 @@ resources:
|
|||||||
Hostname: {get_attr: [HostsEntryDeployment, hostname]}
|
Hostname: {get_attr: [HostsEntryDeployment, hostname]}
|
||||||
|
|
||||||
outputs:
|
outputs:
|
||||||
# FIXME(shardy) this is needed because TemplateResource returns an
|
|
||||||
# ARN not a UUID, which overflows the Deployment server_id column..
|
|
||||||
OS::stack_id:
|
OS::stack_id:
|
||||||
value: {get_attr: [deployed-server, "OS::stack_id"]}
|
value: {get_resource: deployed-server}
|
||||||
networks:
|
networks:
|
||||||
value:
|
value:
|
||||||
ctlplane:
|
ctlplane:
|
||||||
|
@ -79,24 +79,19 @@ for role in $OVERCLOUD_ROLES; do
|
|||||||
server_stack=$(openstack stack resource show $stack $server_resource_name -c physical_resource_id -f value)
|
server_stack=$(openstack stack resource show $stack $server_resource_name -c physical_resource_id -f value)
|
||||||
done
|
done
|
||||||
|
|
||||||
deployed_server_stack=$(openstack stack resource show $server_stack deployed-server -c physical_resource_id -f value)
|
deployed_server_metadata_url=$(openstack stack resource metadata $server_stack deployed-server | jq -r '.["os-collect-config"].request.metadata_url')
|
||||||
|
|
||||||
echo "======================"
|
echo "======================"
|
||||||
echo "$role$i os-collect-config.conf configuration:"
|
echo "$role$i os-collect-config.conf configuration:"
|
||||||
|
|
||||||
config="
|
config="
|
||||||
[DEFAULT]
|
[DEFAULT]
|
||||||
collectors=heat
|
collectors=request
|
||||||
command=os-refresh-config
|
command=os-refresh-config
|
||||||
polling_interval=30
|
polling_interval=30
|
||||||
|
|
||||||
[heat]
|
[request]
|
||||||
user_id=$admin_user_id
|
metadata_url=$deployed_server_metadata_url"
|
||||||
password=$OS_PASSWORD
|
|
||||||
auth_url=$OS_AUTH_URL
|
|
||||||
project_id=$admin_project_id
|
|
||||||
stack_id=$deployed_server_stack
|
|
||||||
resource_name=deployed-server-config"
|
|
||||||
|
|
||||||
echo "$config"
|
echo "$config"
|
||||||
echo "======================"
|
echo "======================"
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
resource_registry:
|
resource_registry:
|
||||||
OS::TripleO::Server: ../deployed-server/deployed-server.yaml
|
OS::TripleO::Server: ../deployed-server/deployed-server.yaml
|
||||||
OS::TripleO::DeployedServerConfig: ../deployed-server/deployed-server-config.yaml
|
|
||||||
OS::TripleO::DeployedServer::ControlPlanePort: ../deployed-server/ctlplane-port.yaml
|
OS::TripleO::DeployedServer::ControlPlanePort: ../deployed-server/ctlplane-port.yaml
|
||||||
|
Loading…
Reference in New Issue
Block a user