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

nomad-pack v0.1.0 #475

Open
kholqifk opened this issue Nov 27, 2023 · 1 comment
Open

nomad-pack v0.1.0 #475

kholqifk opened this issue Nov 27, 2023 · 1 comment

Comments

@kholqifk
Copy link

kholqifk commented Nov 27, 2023

When using nomad-pack default template,
I got this Error: failed to load pack: failed to decode metadata.hcl: metadata.hcl:1,5-5: Missing required argument; The argument "author" is required, but no definition was found., and 1 other diagnostic(s)
when i add author in metadata, i got this Error: template: tnps_user_service/templates/_helpers.tpl:22: function "var" not defined
image_2023-11-27_182506715

@angrycub
Copy link
Contributor

angrycub commented Dec 5, 2023

From the sound of the error messages and the file snippet you have in the issue, it would seem like you have an older version of pack trying to read a template created by version 0.1.0. The var function was introduced in the updated template syntax that comes in v0.1.0. The author metadata was removed in #317 as well.

If you need to support both syntaxes or need to generate a sample pack for the pre-0.1.0 syntax, you can use nomad-pack generate from the techpreview4 version and use it with v0.1.0 by supplying the --parser-v1 flag to the render, run, andstop commands.

If you are using a 0.1.0 versioned package and receiving these errors, please add any additional information you can about where you are fetching them from so that I can investigate further.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants