From packer debug mode, we could verify that packer is using cinder v3 API.
openstack.image: [DEBUG] Request POST https://cinder.cloud.rc.uab.edu:8776/v3/cf6fa1e53d4c40a49f4e0e469c440359/volumes/2009abf6-0ece-4b13-8914-4295792c912f/action 500 openstack.image: [DEBUG] Response Error: {"computeFault": {"code": 500, "message": "The server has either erred or is incapable of performing the requested operation."}}
However, @ravi89 pointed out that, it might be that packer is incapable of handling v3 API so I tried update the packer version to the latest version, 1.9.4, and it worked.
In addition to the packer update, when I was testing newer version of packer, I got error:
$ packer build -debug openstackError: Unknown source type openstack on openstack/nodeimage.pkr.hcl line 23:(source code not available)known builders: [virtualbox-vm qemu amazon-ebsvolume googlecompute file nullvirtualbox-ovf virtualbox-iso azure-arm azure-chroot docker vagrantvsphere-clone azure-dtl vmware-vmx amazon-chroot amazon-ebssurrogate vmware-isoamazon-ebs vsphere-iso amazon-instance]
Apparently, packer stopped bundling community-maintained plugins, including OpenStack, since v1.9.0. So we need to install it explicitly. See packer release note