From 7426286e087f898bb6679e2db665f5f612491071 Mon Sep 17 00:00:00 2001 From: Danielle Date: Mon, 11 Sep 2023 09:32:14 +0100 Subject: [PATCH] updated module import tip --- docs/vendors/terraform/module-registry.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/vendors/terraform/module-registry.md b/docs/vendors/terraform/module-registry.md index 2b760dc75..514cf376d 100644 --- a/docs/vendors/terraform/module-registry.md +++ b/docs/vendors/terraform/module-registry.md @@ -188,6 +188,9 @@ Note that in order to refer to a test case, you need to set a unique `id` to it. ## Versions +!!! tip + If you would like to import old module versions, you can use a bash script that lists the tags in the repo and then use [spacectl](https://github.com/spacelift-io/spacectl){: rel="nofollow"}: `spacectl module create-version --id --sha --version ` + Whenever tests succeed on a [tracked change](../../concepts/run/README.md#where-do-runs-come-from), a new **Version** is created based on the `module_version` in the configuration. Important thing to note is that Spacelift will not let you reuse the number of a successful version, and will require you to strictly follow semantic versioning - ie. you can't go to from `0.2.0` to `0.4.0`, skipping `0.3.0` entirely. ![](../../assets/screenshots/Versions_ยท_terraform-spacelift-example.png)