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

Blocks of type "efi_config" are not expected here. #144

Closed
modem7 opened this issue Jan 23, 2023 · 3 comments
Closed

Blocks of type "efi_config" are not expected here. #144

modem7 opened this issue Jan 23, 2023 · 3 comments
Labels

Comments

@modem7
Copy link

modem7 commented Jan 23, 2023

Overview of the Issue

When using the new efi_config command, getting the error "Blocks of type "efi_config" are not expected here."

I suspect this might be an ID10T issue as it's an "object" and not an "array of objects".

Reproduction Steps

  // EFI Config
  efi_config {
    efi_storage_pool = "${var.vm_storage_pool}"
    pre_enrolled_keys = true
    efi_type = "4m"
  }

Plugin and Packer version

Packer v1.8.5
Plugin v1.1.1

Simplified Packer Buildfile

https://paste.modem7.com/67mwT-qOerd

Operating system and Environment details

Ubuntu 22.04.1 x64

Log Fragments and crash.log files

packer build .
Error: Unsupported block type

  on ubuntu-server-jammy.pkr.hcl line 77:
  (source code not available)

Blocks of type "efi_config" are not expected here.
@modem7 modem7 added the bug label Jan 23, 2023
@sebastian-de
Copy link
Contributor

Your config example works for me:tm:

This is still related to #119

That's the problematic line in your config:

source "proxmox" "ubuntu-server-jammy" {

You should use proxmox-iso or proxmox-clone to specify the desired builder. If you use just proxmox, the plugin version built into Packer will be used (which doesn't have efi support, yet).

I think the following line should be removed from Packer:
https://github.com/hashicorp/packer/blob/11e71729f187bad76d28f1701cf2c56e7b912c0f/command/vendored_plugins.go#L117
I don't know why it's still there, maybe for compatibility-reasons?

@nywilken should the mentioned line be removed from Packer, or should this plugin register a proxmox builder again? This was dropped in #120

@sebastian-de
Copy link
Contributor

sebastian-de commented Jan 23, 2023

The alias was introduced when the builder was split:
hashicorp/packer#9626 (comment)
hashicorp/packer@a140c13

So I guess we should add proxmox again.

@modem7
Copy link
Author

modem7 commented Jan 23, 2023

The alias was introduced when the builder was split: hashicorp/packer#9626 (comment) hashicorp/packer@a140c13

So I guess we should add proxmox again.

Good catch!

I misunderstood the docs when I read it! All working as expected now.

Appreciate it!

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

No branches or pull requests

2 participants