summaryrefslogtreecommitdiffstats
path: root/firstboot
diff options
context:
space:
mode:
authorJenkins <jenkins@review.openstack.org>2015-09-08 13:03:38 +0000
committerGerrit Code Review <review@openstack.org>2015-09-08 13:03:38 +0000
commit9a8e384a145b48ef9d7f58da13bc828bbc79941d (patch)
treea9e4985a90f389cb58b4873b3a436a0d71f0159d /firstboot
parent63fde6c98b4b46ddb9168e2ee3d571390f6979ad (diff)
parentd578cf1ac057643428eba77c3c0a0d31b9db6ad3 (diff)
Merge "Add NodeAdminUserData interface for "heat-admin" user"
Diffstat (limited to 'firstboot')
-rw-r--r--firstboot/userdata_heat_admin.yaml29
1 files changed, 29 insertions, 0 deletions
diff --git a/firstboot/userdata_heat_admin.yaml b/firstboot/userdata_heat_admin.yaml
new file mode 100644
index 00000000..73481c63
--- /dev/null
+++ b/firstboot/userdata_heat_admin.yaml
@@ -0,0 +1,29 @@
+heat_template_version: 2014-10-16
+
+parameters:
+ # Can be overriden via parameter_defaults in the environment
+ node_admin_username:
+ type: string
+ default: heat-admin
+
+description: >
+ Uses cloud-init to create an additional user with a known name, in addition
+ to the distro-default user created by the cloud-init default.
+
+resources:
+ userdata:
+ type: OS::Heat::MultipartMime
+ properties:
+ parts:
+ - config: {get_resource: user_config}
+
+ # Note this requires cloud-init >= 0.7.2 ref bug #1100920
+ user_config:
+ type: OS::Heat::CloudConfig
+ properties:
+ cloud_config:
+ user: {get_param: node_admin_username}
+
+outputs:
+ OS::stack_id:
+ value: {get_resource: userdata}