From aeffaa790fc054833532d17514dd251403a98f77 Mon Sep 17 00:00:00 2001 From: Lucas Bajolet <105649352+lbajolet-hashicorp@users.noreply.github.com> Date: Thu, 15 Jun 2023 15:09:00 -0400 Subject: [PATCH] docs: add a paragraph on fingerprint generation (#12464) * docs: add a paragraph on fingerprint generation Since version 1.9.0+ changed the way Packer generates fingerprints for HCP Packer, we add a small paragraph to explain how it used to be generated before, and how it changed in this version. * Apply suggestions from code review --------- Co-authored-by: Wilken Rivera --- website/content/docs/hcp/index.mdx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/website/content/docs/hcp/index.mdx b/website/content/docs/hcp/index.mdx index 35f7c2fd4..b7af158ee 100644 --- a/website/content/docs/hcp/index.mdx +++ b/website/content/docs/hcp/index.mdx @@ -47,6 +47,9 @@ Refer to [`hcp_packer_registry`](/packer/docs/templates/hcl_templates/blocks/bui Packer uses a unique fingerprint for tracking the completion of builds associated to an iteration. By default a fingerprint is automatically generated by Packer during each invocation of `packer build`, unless a fingerprint is manually provided via the `HCP_PACKER_BUILD_FINGERPRINT` environment variable. +In versions before 1.9.0, this fingerprint was computed from the Git SHA of the current HEAD in which your template is stored. If you were running builds using a non Git managed template, you had to set the `HCP_PACKER_BUILD_FINGERPRINT` environment variable prior to invoking `packer build`. +Starting with Packer 1.9.0, fingerprint generation does not rely on Git at all, and instead Packer now generates a Unique Lexicographically sortable Identifier (ULID) as the fingerprint for every `packer build` invocation. + #### Fingerprints and Incomplete Iterations When you build a template with Packer, there's always a chance that it does not succeed because of a network issue, a provisioning failure, or some upstream error. When that happens, Packer will output the generated fingerprint associated with the incomplete iteration so that you can resume building that iteration using the `HCP_PACKER_BUILD_FINGERPRINT` environment variable; an iteration can be resumed until it is marked as complete. This environment variable is necessary for resuming an incomplete iteration, otherwise Packer will create a new iteration for the build.