Create and manage add-on definitions
This page describes how to create, edit, and delete HCP Waypoint add-on definitions. Platform engineers often perform these tasks. Refer to Add-ons for additional information.
Overview
The following steps describe the procedure for creating add-on definitions:
- For each add-on you want to create, define a no-code module in HCP Terraform that specifies a common infrastructure pattern.
- Use the HCP Waypoint UI to create the add-on.
After creating an add-on, application developers can begin installing it to add additional capabilities to their applications.
Prerequisites
- An HCP account with HCP Waypoint enabled. Refer to HCP Account for information about creating an account.
- An HCP Terraform organization with Plus tier. HCP Terraform must be Plus tier to use HCP Terraform no-code modules and the private module registry.
Create a no-code module
To create an add-on definition, you first need to create a no-code module that captures the common infrastructure pattern. Refer to Designing No-Code Ready Modules for instructions on how to create no-code modules.
You can reference the following variables in the module as HCP Waypoint defines the values when the application developer uses the add-on.
waypoint_add_on
: References the name of the add-on.waypoint_add_on_definition
: References the name of the add-on definition used to create the add-on.waypoint_application
: References the name of the application for which the add-on is being installed onto by the app developer.
Refer to Input Variables for instructions on how to define variables in Terraform.
You may need to create global variable sets within your HCP Terraform organization so your no-code modules can authenticate and interact with your cloud provider.
You can use the variable to label infrastructure resources in the no-code module so you can associate them with the HCP Waypoint application.
Create an add-on definition
After creating the no-code module, complete the following steps in the HCP Waypoint UI:
- From the HCP Waypoint overview, go to the Add-ons menu.
- Click Create an Add-on.
- Specify a unique identifier for the add-on definition in the Name field. The name can be up to 24 characters.
- Add a short description for the definition in the Summary field. This field can be up to 110 characters. HCP Waypoint presents the description when users install an add-on.
- Choose a no-code module to use as the source for the template from the Terraform no-code module drop-down menu. No-code modules published in your organization's private registry appear in the menu.
- Enter a value for the input variables.
- Optionally, enable the Enable this value to be defined when the addon is created option for each variable you want to choose a value for when you install the add-on. Refer to HCP Waypoint variables reference for more information.
- Choose a HCP Terraform Project.
- Click Next.
- Add a full-length description of the definition in the Description field. This field can be up to 500 characters. HCP Waypoint presents the description when users install an add-on.
- Specify instructions for application developers on how to use the template in the Developer instructions field. HCP Waypoint exposes the following variables so you can reference them in the developer instructions. This field supports Markdown.
{{ .ApplicationName }}
: Populates the name of the developer's application.{{ .TfcOrgName }}
: Populates the name of the HCP Terraform organization.{{ .AddOnName }}
: Populates the name of the add-on.
- Specify arbitrary metadata as labels to associate with your add-on definition in the Labels field.
- Click Publish.
Edit an add-on definition
Modifying an add-on does not affect existing installations or supporting infrastructure created by the add-on. These changes only apply to new add-on installations.
To edit an add-on definition, complete the following steps:
- In the HCP Waypoint UI, go to the Add-ons menu.
- Click on the add-on definition you want to modify.
- Update the desired fields.
- Click Save.
Delete an add-on definition
Deleting an add-on does not delete the supporting infrastructure that was created with Terraform by the add-on. To do so, you must uninstall the add-on from a application or delete the Terraform resources and the HCP Terraform workspace associated with the HCP Waypoint add-on. Refer to Destruction and Deletion for instructions.
To delete an add-on definition, complete the following steps:
- From the HCP Waypoint overview, go to the Templates menu.
- Select the add-on definition you want to delete.
- Click Delete Add-on.
- Enter "DELETE" and click Delete.
Next steps
To learn more about what you can do with HCP Waypoint after you created an add-on definition, refer to the following topics: