Skip to content

Instantly share code, notes, and snippets.

@mcallaway
Created March 29, 2016 15:06
Show Gist options
  • Save mcallaway/f9aa9bd9bd34af48d505 to your computer and use it in GitHub Desktop.
Save mcallaway/f9aa9bd9bd34af48d505 to your computer and use it in GitHub Desktop.
heat_template_version: 2013-05-23
resources:
server_port:
type: OS::Neutron::Port
properties:
network: "development"
fixed_ips:
- subnet: "development-subnet"
floating_ip:
type: OS::Neutron::FloatingIP
properties:
floating_network: "external"
port_id: { get_resource: server_port }
server_cluster:
type: OS::Heat::ResourceGroup
properties:
count: 1
resource_def:
type: OS::Nova::Server
properties:
# Add name and this works. Without name, a name is
# auto-generated, and user-data does not apply.
#name: "coreos-server-%index%"
flavor: "m1.small"
#image: "CoreOS-835.9.0"
#image: "cirros-0.3.4-x86_64"
# Use a snapshot with root's password set
image: "coreos-snapshot"
key_name: "csa-ostack"
config_drive: true
networks:
- port: { get_resource: server_port }
user_data_format: RAW
user_data: |
#cloud-config
users:
- name: "root"
passwd: "$1$1ZVygQax$gVKfLFBHHxoh63PMFM5kP/"
@mcallaway
Copy link
Author

Filed this:

https://bugs.launchpad.net/heat/+bug/1563402

Workaround for my case:

diff --git a/heat/engine/resources/openstack/nova/server.py b/heat/engine/resources/openstack/nova/server.py
index 6a1473b..6264b34 100644
--- a/heat/engine/resources/openstack/nova/server.py
+++ b/heat/engine/resources/openstack/nova/server.py
@@ -560,7 +560,7 @@ class Server(stack_user.StackUser, sh.SchedulerHintsMixin,

     # Server host name limit to 53 characters by due to typical default
     # linux HOST_NAME_MAX of 64, minus the .novalocal appended to the name
-    physical_resource_name_limit = 53
+    physical_resource_name_limit = 50

     default_client_name = 'nova'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment