You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have been building the glance image without using Cinder block storage volume and that works fine. However, building the a packer Openstack image using block storage volume errored out with HTTP 403 Forbidden: Access was denied to this resource.: Attribute 'os_glance_failed_import' is reserved.
I have also did a manual test by:
Create a bootable volume in Openstack using the external image.
Run cinder upload-to-image.
The glance image is successful created.
cinder upload-to-image uses the same API endpoint as Packer Openstack plugin
$ packer build no1-u2004-plain.pkr.hcl
openstack.ubuntu-20.04-plain: output will be in this color.
==> openstack.ubuntu-20.04-plain: Loading flavor: small
openstack.ubuntu-20.04-plain: Verified flavor. ID: 3afdf992-b8a3-41ff-8bf7-c2003ec93822
==> openstack.ubuntu-20.04-plain: Creating temporary RSA SSH key for instance...
==> openstack.ubuntu-20.04-plain: Creating temporary keypair: packer_6617b261-5ac5-5a6c-3377-9f024c66fa6e ...
==> openstack.ubuntu-20.04-plain: Created temporary keypair: packer_6617b261-5ac5-5a6c-3377-9f024c66fa6e
==> openstack.ubuntu-20.04-plain: Creating image using external source image with name packer_6617b261-f0b0-e9b8-72ef-b047343b09bd
==> openstack.ubuntu-20.04-plain: Using disk format qcow2
==> openstack.ubuntu-20.04-plain: Created image with ID ecaa1141-310a-492a-8c10-858d5aeb1599
==> openstack.ubuntu-20.04-plain: Importing External Source Image from URL https://cloud-images.ubuntu.com/focal/current/focal-server-cloudimg-amd64.img
openstack.ubuntu-20.04-plain: Image not Active, retrying in 10 seconds
openstack.ubuntu-20.04-plain: Image not Active, retrying in 10 seconds
==> openstack.ubuntu-20.04-plain: Creating volume...
==> openstack.ubuntu-20.04-plain: Waiting for volume packer_6617b261-84d9-da68-ce53-25d674bb7fde (volume id: 5f42fd30-23cb-4956-95ab-ae885c66ca24) to become available...
openstack.ubuntu-20.04-plain: Volume ID: 5f42fd30-23cb-4956-95ab-ae885c66ca24
==> openstack.ubuntu-20.04-plain: Launching server...
==> openstack.ubuntu-20.04-plain: Launching server...
openstack.ubuntu-20.04-plain: Server ID: 83b4e3ae-a02e-47cb-bf98-06bc6ff3f0a3
==> openstack.ubuntu-20.04-plain: Waiting for server to become ready...
openstack.ubuntu-20.04-plain: Floating IP not required
==> openstack.ubuntu-20.04-plain: Using SSH communicator to connect: 10.0.1.58
==> openstack.ubuntu-20.04-plain: Waiting for SSH to become available...
==> openstack.ubuntu-20.04-plain: Connected to SSH!
==> openstack.ubuntu-20.04-plain: Trying to remove ephemeral keys from authorized_keys files
==> openstack.ubuntu-20.04-plain: Stopping server: 83b4e3ae-a02e-47cb-bf98-06bc6ff3f0a3 ...
openstack.ubuntu-20.04-plain: Waiting for server to stop: 83b4e3ae-a02e-47cb-bf98-06bc6ff3f0a3 ...
==> openstack.ubuntu-20.04-plain: Terminating the source server: 83b4e3ae-a02e-47cb-bf98-06bc6ff3f0a3 ...
==> openstack.ubuntu-20.04-plain: Creating the image: Ubuntu 20.04 LTS Server amd64-20240411
==> openstack.ubuntu-20.04-plain: Error creating image: Bad request with: [POST http://api.openstack.cloud:8776/v3/0a3ec33c5c634ae58ed420ff1daa222e/volumes/5f42fd30-23cb-4956-95ab-ae885c66ca24/action], error message: {"badRequest": {"code": 400, "message": "HTTP 403 Forbidden: Access was denied to this resource.: Attribute 'os_glance_failed_import' is reserved."}}
==> openstack.ubuntu-20.04-plain: Provisioning step had errors: Running the cleanup provisioner, if present...
==> openstack.ubuntu-20.04-plain: Terminating the source server: 83b4e3ae-a02e-47cb-bf98-06bc6ff3f0a3 ...
==> openstack.ubuntu-20.04-plain: Error terminating server, may still be around: Resource not found
==> openstack.ubuntu-20.04-plain: Deleting volume: 5f42fd30-23cb-4956-95ab-ae885c66ca24 ...
==> openstack.ubuntu-20.04-plain: Deleting temporary external source image: packer_6617b261-f0b0-e9b8-72ef-b047343b09bd ...
==> openstack.ubuntu-20.04-plain: Deleting temporary keypair: packer_6617b261-5ac5-5a6c-3377-9f024c66fa6e ...
Build 'openstack.ubuntu-20.04-plain' errored after 1 minute 31 seconds: Error creating image: Bad request with: [POST http://api.openstack.cloud:8776/v3/0a3ec33c5c634ae58ed420ff1daa222e/volumes/5f42fd30-23cb-4956-95ab-ae885c66ca24/action], error message: {"badRequest": {"code": 400, "message": "HTTP 403 Forbidden: Access was denied to this resource.: Attribute 'os_glance_failed_import' is reserved."}}
The text was updated successfully, but these errors were encountered:
I have been building the glance image without using Cinder block storage volume and that works fine. However, building the a packer Openstack image using block storage volume errored out with
HTTP 403 Forbidden: Access was denied to this resource.: Attribute 'os_glance_failed_import' is reserved.
I have also did a manual test by:
cinder upload-to-image
.cinder upload-to-image
uses the same API endpoint as Packer Openstack pluginWe are running Openstack Yoga. I suspect this is due to the really old version of
gophercloud
that this plugin uses:https://github.com/hashicorp/packer-plugin-openstack/blob/main/go.mod#L7
The current stable
gophercloud
release is already at v1.1.0 and on track to release v2.0.0.Reproduction Steps
Steps to reproduce this issue:
Plugin and Packer version
Simplified Packer Buildfile
Log Fragments and crash.log files
The text was updated successfully, but these errors were encountered: