Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Chroot Builder] "vm" template function is not defined error #399

Open
JenGoldstrich opened this issue Apr 2, 2024 · 1 comment
Open
Labels
bug builder/chroot issues related to the chroot builder upstream-bug

Comments

@JenGoldstrich
Copy link
Contributor

This is a followup issue to: #87, the 'vm' template function defined in the chroot docs here does not work in the source block of the chroot builder, as far as I can tell this function has not worked for several years, in #87 this was causing an issue where in the builder here we try to use the interpolate library with the VM function which was failing, by moving where we register the function to after the Decode function we were able to fix the issues with the temporary values in #87 but the vm function is still unusable inside of a user template.

@lbajolet-hashicorp
Copy link
Contributor

For context: the Decode function comes from the plugin SDK, and that issue of custom functions being unable to use for interpolation in the configs is present on all plugins (assuming they do define their own before calling Decode on the configuration), and has been since hashicorp/packer#9622, included in Packer 1.6.1 and onwards.

@JenGoldstrich JenGoldstrich changed the title [Chroot Builder] "vm" template function is not not defined error when using it [Chroot Builder] "vm" template function is not defined error when using it Apr 10, 2024
@JenGoldstrich JenGoldstrich changed the title [Chroot Builder] "vm" template function is not defined error when using it [Chroot Builder] "vm" template function is not defined error Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug builder/chroot issues related to the chroot builder upstream-bug
Projects
None yet
Development

No branches or pull requests

2 participants