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

Missing metadata implementation in opentelekomcloud_images_image_v2. #2799

Open
opnmind opened this issue Jan 24, 2025 · 3 comments
Open

Missing metadata implementation in opentelekomcloud_images_image_v2. #2799

opnmind opened this issue Jan 24, 2025 · 3 comments
Assignees
Labels

Comments

@opnmind
Copy link

opnmind commented Jan 24, 2025

Hello,

I tried to create an image (opentelekomcloud_images_image_v2) with the needed metadata 'hw_firmware_type=uefi' and I received an error message that the metadata is not a valid argument.
In the documentation (https://registry.terraform.io/providers/opentelekomcloud/opentelekomcloud/latest/docs/resources/images_image_v2#metadata-3) the argument is mentioned but it seems not yet implemented in the code.

Please fix this and consider also to implement the metadata feature in the opentelekomcloud_ims_image_v2 part too (https://docs.otc.t-systems.com/image-management-service/api-ref/ims_apis/image/updating_image_information.html#en-us-topic-0020091567).

I wish you a great day.

@muneeb-jan
Copy link
Member

Hi @opnmind,

I went through this and noticed the following:

  1. metadata is not an argument in the docs. It is listed as attributes. However, this itself is a documentation error since we aren't returning this field. Perhaps this is a remnant from legacy code and remained unnoticed.
  2. The APIs used for opentelekomcloud_images_image_v2 (both native Openstack and IMS) itself do not support this argument.

If you still need this functionality, please contact customer support (service@open-telekom-cloud.com) and submit a feature request.

@opnmind
Copy link
Author

opnmind commented Feb 5, 2025

Hi muneeb-jan,

I'm disapointed that you can't match the wording metadata with the image properties. Also if I'm talking about the properties 'hw_firmware_type=uefi' then you could assume that without this property there is no ability to declare an uploaded image as an uefi image. This means, it will start always in bios mode. It's also impossible to use the terraform-provider-openstack because of the zvhd2 disk_format which isn't supported here.

  1. Please fix the 'buggy properties' in the gophercloud opentelekomcloud
  2. Implement this missing functionality in opentelekomcloud_images_image_v2. This is not a feature request, this argument has to be supported.
  3. If the 2nd topic works then it would be a plus if the opentelekomcloud_ims_image_v2 would also support this feature. You can decide to implement it like you have done it for the tags. Include the schema from the metadata and use it inside resource_opentelekomcloud_images_image_v2.go. At least this would be my approach.

Thanks for your help.

BTW: If you have questions, also you can contact me internally via Tino or Nils.

@anton-sidelnikov anton-sidelnikov self-assigned this Feb 6, 2025
otc-zuul bot pushed a commit that referenced this issue Feb 7, 2025
[Feat.] IMS: Add user input field hw_firmware_type

Summary of the Pull Request
resource/opentelekomcloud_images_image_v2
Users can now define the fields:

hw_firmware_type

datasource/opentelekomcloud_images_image_v2
If set during creation, users receive the above mentioned fields.
PR Checklist

 Refers to: #2799
 Tests added/passed.
 Documentation updated.
 Schema updated.
 Release notes added.

Acceptance Steps Performed
=== RUN   TestAccImagesImageV2_hwFirmwareType
--- PASS: TestAccImagesImageV2_hwFirmwareType (335.24s)
PASS
=== RUN   TestAccImagesV2ImageDataSource_basic
--- PASS: TestAccImagesV2ImageDataSource_basic (262.38s)
PASS

Reviewed-by: Anton Sidelnikov
@muneeb-jan
Copy link
Member

Hi @opnmind,

The field hw_firmware_type was added to resource as well as datasource opentelekomcloud_images_image_v2.

Refer to the resource documentation.
Please check and verify.

otc-zuul bot pushed a commit that referenced this issue Feb 17, 2025
…2830)

[Feat.] IMS: Add user input field hw_firmware_type to ims_image_v2

Summary of the Pull Request
resource/opentelekomcloud_ims_image_v2
Users can now define the fields:

hw_firmware_type

PR Checklist

 Refers to: #2799
 Tests added/passed.
 Documentation updated.
 Schema updated.
 Release notes added.

Acceptance Steps Performed
=== RUN   TestAccImsImageV2_basic
--- PASS: TestAccImsImageV2_basic (290.91s)
PASS

Reviewed-by: Artem Lifshits
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

3 participants