A new stack can be created using a template file or with help of cURL. We will use an example template file to create a stack. Let's suppose we have a template file named single_server.template
. We will use the following command to create a stack:
ubuntu@ubuntu~$ heat stack-create Single-Server-Stack --template-file single_server.template
The output will be something similar to the one shown in the following screenshot:
The stack-create
command can also be used for validating a template file without creating an actual stack. This can be a dry run to test whether there are no errors in the template file. The following is the command used to achieve this:
ubuntu@ubuntu~$ heat stack-create Single-Server-Stack --template-file single_server.template