Terraform-provider-libvirt: Deb package fails to install on Ubuntu 20.04

Created on 9 Dec 2020  路  1Comment  路  Source: dmacvicar/terraform-provider-libvirt

System Information

Linux distribution

# cat /etc/os-release
NAME="Ubuntu"
VERSION="20.04.1 LTS (Focal Fossa)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.04.1 LTS"
VERSION_ID="20.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=focal
UBUNTU_CODENAME=focal

Checklist

  • [ ] Is your issue/contribution related with enabling some setting/option exposed by libvirt that the plugin does not yet support, or requires changing/extending the provider terraform schema?

    • [ ] Make sure you explain why this option is important to you, why it should be important to everyone. Describe your use-case with detail and provide examples where possible.
    • [ ] If it is a very special case, consider using the _XSLT_ support in the provider to tweak the definition instead of opening an issue
    • [ ] Maintainers do not have expertise in every libvirt setting, so please, describe the feature and how it is used. Link to the appropriate documentation
  • [x] Is it a bug or something that does not work as expected? Please make sure you fill the version information below:

Description of Issue/Question

Deb package fails to install due to missing files in the package:

Setting up libgssapi3-heimdal:amd64 (7.7.0+dfsg-1ubuntu1) ...
Setting up libldap-2.4-2:amd64 (2.4.49+dfsg-2ubuntu1.5) ...
Setting up libcurl3-gnutls:amd64 (7.68.0-1ubuntu2.2) ...
Setting up libvirt0:amd64 (6.0.0-0ubuntu8.5) ...
Setting up terraform-provider-libvirt (0.6.3+git.1604843676.67f4f2aa-4.1) ...
/bin/chown: cannot access '/usr/share/doc/terraform-provider-libvirt/README.md': No such file or directory
/bin/chown: cannot access '/usr/share/doc/terraform-provider-libvirt/LICENSE': No such file or directory
dpkg: error processing package terraform-provider-libvirt (--configure):
 installed terraform-provider-libvirt package post-installation script subprocess returned error exit status 1
Setting up liblvm2cmd2.03:amd64 (2.03.07-1ubuntu1) ...
Setting up dmeventd (2:1.02.167-1ubuntu1) ...
Setting up lvm2 (2.03.07-1ubuntu1) ...
invoke-rc.d: could not determine current runlevel
invoke-rc.d: policy-rc.d denied execution of start.
invoke-rc.d: could not determine current runlevel
invoke-rc.d: policy-rc.d denied execution of start.
Processing triggers for libc-bin (2.31-0ubuntu9.1) ...
Errors were encountered while processing:
 terraform-provider-libvirt

Steps to Reproduce Issue

  1. Run the following commands:
cat <<EOF > Dockerfile
FROM ubuntu:focal

RUN apt update && apt install -y wget

RUN wget https://download.opensuse.org/repositories/systemsmanagement:/terraform/Ubuntu_20.04/amd64/terraform-provider-libvirt_0.6.3+git.1604843676.67f4f2aa-4.1_amd64.deb

RUN apt install -y ./terraform-provider-libvirt_0.6.3+git.1604843676.67f4f2aa-4.1_amd64.deb
EOF

docker build .

Workaround

To workaround, run the following command and retry installation:

touch /usr/share/doc/terraform-provider-libvirt/README.md /usr/share/doc/terraform-provider-libvirt/LICENSE
community help wanted

Most helpful comment

spec FILE is here:

https://build.opensuse.org/package/view_file/systemsmanagement:terraform/terraform-provider-libvirt/terraform-provider-libvirt.spec?expand=1

if anyone want to help:
https://en.opensuse.org/openSUSE:Build_Service_Collaboration

https://duncan.codes/tutorials/rpm-packaging/#the-open-build-service

or any question on RPM related welcome.

But for helping on this, we just need to modify the Spec file which builds also deb pkg.

Let me know if any question or someone wants to take ownership on this issue

>All comments

spec FILE is here:

https://build.opensuse.org/package/view_file/systemsmanagement:terraform/terraform-provider-libvirt/terraform-provider-libvirt.spec?expand=1

if anyone want to help:
https://en.opensuse.org/openSUSE:Build_Service_Collaboration

https://duncan.codes/tutorials/rpm-packaging/#the-open-build-service

or any question on RPM related welcome.

But for helping on this, we just need to modify the Spec file which builds also deb pkg.

Let me know if any question or someone wants to take ownership on this issue

Was this page helpful?
0 / 5 - 0 ratings