Select your cookie preferences

We use essential cookies and similar tools that are necessary to provide our site and services. We use performance cookies to collect anonymous statistics, so we can understand how customers use our site and make improvements. Essential cookies cannot be deactivated, but you can choose “Customize” or “Decline” to decline performance cookies.

If you agree, AWS and approved third parties will also use cookies to provide useful site features, remember your preferences, and display relevant content, including relevant advertising. To accept or decline all non-essential cookies, choose “Accept” or “Decline.” To make more detailed choices, choose “Customize.”

AWS.Compute.UserData

Focus mode
AWS.Compute.UserData - AWS Telco Network Builder

AWS TNB supports launching Amazon EC2 instances with custom user data, through the UserData node in Network Service Descriptor (NSD). For more information about custom user data, see User data and shell scripts in the Amazon EC2 User Guide.

During network instantiation, AWS TNB provides the Amazon EC2 instance registration to the cluster through a user-data script. When custom user data is also provided, AWS TNB merges both scripts and passes them on as a multimime script to Amazon EC2. The custom user-data script is run prior to the Amazon EKS registration script.

To use custom variables in the user-data script, add an exclamation mark ! after the open curly brace {. For example, to use MyVariable in the script, enter: {!MyVariable}

Note
  • AWS TNB supports user-data scripts up to 7 KB in size.

  • Because AWS TNB uses AWS CloudFormation to process and render the multimime user-data script, ensure that the script adheres to all AWS CloudFormation rules.

Syntax

tosca.nodes.AWS.Compute.UserData: properties: implementation: String content_type: String

Properties

implementation

The relative path to the user data script definition. The format must be: ./scripts/script_name.sh

Required: Yes

Type: String

content_type

Content type of the user data script.

Required: Yes

Type: String

Possible values: x-shellscript

Example

ExampleUserData: type: tosca.nodes.AWS.Compute.UserData properties: content_type: "text/x-shellscript" implementation: "./scripts/customUserData.sh"

On this page

PrivacySite termsCookie preferences
© 2025, Amazon Web Services, Inc. or its affiliates. All rights reserved.