2023-12-12 09:22:07 +00:00
|
|
|
# Disable the growpart subpackage in EPEL, as RHEL ships it on its own
|
|
|
|
%if 0%{?epel}
|
|
|
|
%bcond_with growpart
|
|
|
|
%else
|
|
|
|
%bcond_without growpart
|
|
|
|
%endif
|
|
|
|
|
2013-02-18 17:33:01 +00:00
|
|
|
Summary: Cloud image management utilities
|
|
|
|
Name: cloud-utils
|
2023-09-05 10:51:56 +00:00
|
|
|
Version: 0.33
|
2023-09-05 09:43:15 +00:00
|
|
|
Release: %autorelease
|
2023-09-05 10:50:55 +00:00
|
|
|
License: GPL-3.0-only
|
2023-09-05 10:51:56 +00:00
|
|
|
URL: https://github.com/canonical/%{name}
|
2013-02-18 17:33:01 +00:00
|
|
|
|
2023-09-05 10:51:56 +00:00
|
|
|
Source: %{url}/archive/%{version}/%{name}-%{version}.tar.gz
|
2013-02-18 17:33:01 +00:00
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
2023-09-05 10:42:57 +00:00
|
|
|
Requires: %{name}-growpart
|
2023-09-08 13:21:29 +00:00
|
|
|
Requires: %{name}-cloud-localds
|
|
|
|
Requires: %{name}-write-mime-multipart
|
|
|
|
Requires: %{name}-ec2metadata
|
|
|
|
Requires: %{name}-resize-part-image
|
|
|
|
Requires: %{name}-mount-image-callback
|
|
|
|
Requires: %{name}-vcs-run
|
2013-02-18 17:33:01 +00:00
|
|
|
|
|
|
|
%description
|
|
|
|
This package provides a useful set of utilities for managing cloud images.
|
|
|
|
|
|
|
|
The tasks associated with image bundling are often tedious and repetitive. The
|
|
|
|
cloud-utils package provides several scripts that wrap the complicated tasks
|
|
|
|
with a much simpler interface.
|
|
|
|
|
|
|
|
|
2023-12-12 09:22:07 +00:00
|
|
|
%if %{with growpart}
|
2013-06-17 13:39:27 +00:00
|
|
|
%package growpart
|
2023-09-08 13:21:29 +00:00
|
|
|
Summary: A script for growing a partition
|
2013-06-17 13:39:27 +00:00
|
|
|
|
|
|
|
Requires: gawk
|
2023-09-05 11:21:28 +00:00
|
|
|
Requires: util-linux
|
2013-06-18 06:09:55 +00:00
|
|
|
# gdisk is only required for resizing GPT partitions and depends on libicu
|
|
|
|
# (25MB). We don't make this a hard requirement to save some space in non-GPT
|
|
|
|
# systems.
|
2023-09-05 10:41:03 +00:00
|
|
|
Recommends: gdisk
|
2023-09-05 11:21:28 +00:00
|
|
|
Recommends: lvm2
|
2013-06-17 13:39:27 +00:00
|
|
|
|
|
|
|
|
|
|
|
%description growpart
|
|
|
|
This package provides the growpart script for growing a partition. It is
|
|
|
|
primarily used in cloud images in conjunction with the dracut-modules-growroot
|
|
|
|
package to grow the root partition on first boot.
|
2023-12-12 09:22:07 +00:00
|
|
|
%endif
|
2013-06-17 13:39:27 +00:00
|
|
|
|
|
|
|
|
2023-09-08 13:21:29 +00:00
|
|
|
%package cloud-localds
|
|
|
|
Summary: A script for creating a nocloud configuration disk for cloud-init
|
|
|
|
|
|
|
|
Recommends: tar
|
|
|
|
Recommends: dosfstools
|
|
|
|
Recommends: mtools
|
|
|
|
Recommends: genisoimage
|
|
|
|
Recommends: qemu-img
|
|
|
|
|
|
|
|
|
|
|
|
%description cloud-localds
|
|
|
|
This package provides the cloud-localds script, which creates a disk-image
|
|
|
|
with user-data and/or meta-data for cloud-init.
|
|
|
|
|
|
|
|
|
|
|
|
%package write-mime-multipart
|
|
|
|
Summary: A utilty for creating mime-multipart files
|
|
|
|
|
|
|
|
|
|
|
|
%description write-mime-multipart
|
|
|
|
This package provides the write-mime-multipart script, which creates
|
|
|
|
mime multipart files that can be consumed by cloud-init as user-data.
|
|
|
|
|
|
|
|
|
|
|
|
%package ec2metadata
|
|
|
|
Summary: A script to query and display EC2 AMI instance metadata
|
|
|
|
|
|
|
|
|
|
|
|
%description ec2metadata
|
|
|
|
This package provides the ec2metadata script, which can be used to query and
|
|
|
|
display EC2 instance metadata rekated to an AMI instance.
|
|
|
|
|
|
|
|
|
|
|
|
%package resize-part-image
|
|
|
|
Summary: A script for resizing cloud images
|
|
|
|
|
|
|
|
Requires: file
|
|
|
|
Requires: gzip
|
|
|
|
Requires: e2fsprogs
|
|
|
|
Requires: gawk
|
|
|
|
Requires: tar
|
|
|
|
|
|
|
|
|
|
|
|
%description resize-part-image
|
|
|
|
This package provides the resize-part-image script, which can be used to
|
|
|
|
resize a partition image and the contained filesystem to a new size.
|
|
|
|
|
|
|
|
|
|
|
|
%package mount-image-callback
|
|
|
|
Summary: A script to run commands over cloud image contents
|
|
|
|
|
|
|
|
Requires: gawk
|
|
|
|
Requires: util-linux
|
|
|
|
Recommends: qemu-img
|
|
|
|
|
|
|
|
|
|
|
|
%description mount-image-callback
|
|
|
|
This package provides the mount-image-callback script, which mounts a cloud
|
|
|
|
image to a temporary mountpoint and runs a specified command on the contents.
|
|
|
|
|
|
|
|
|
|
|
|
%package vcs-run
|
|
|
|
Summary: Script to run commands over a VCS repository contents
|
|
|
|
|
|
|
|
Recommends: breezy
|
|
|
|
Recommends: git-core
|
|
|
|
Recommends: mercurial
|
|
|
|
Recommends: wget
|
|
|
|
|
|
|
|
|
|
|
|
%description vcs-run
|
|
|
|
This package provides the vcs-run script, which fetches a code repository
|
|
|
|
into a temporary directory and runs a user-specified command in it.
|
|
|
|
|
|
|
|
|
2013-02-18 17:33:01 +00:00
|
|
|
%prep
|
2013-04-02 09:24:49 +00:00
|
|
|
%setup -q
|
2013-02-18 17:33:01 +00:00
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
2013-08-06 11:11:28 +00:00
|
|
|
# Create the target directories
|
2023-09-05 11:32:34 +00:00
|
|
|
install -d %{buildroot}%{_bindir}
|
|
|
|
install -d %{buildroot}%{_mandir}/man1
|
2013-08-06 11:11:28 +00:00
|
|
|
|
|
|
|
# Install binaries and manpages
|
2023-09-05 11:32:34 +00:00
|
|
|
install -pm 0755 bin/* %{buildroot}%{_bindir}/
|
|
|
|
install -pm 0644 man/* %{buildroot}%{_mandir}/man1/
|
2013-08-06 11:11:28 +00:00
|
|
|
|
2013-02-18 17:33:01 +00:00
|
|
|
# Exclude Ubuntu-specific tools
|
2023-09-05 10:40:07 +00:00
|
|
|
rm %{buildroot}%{_bindir}/*ubuntu*
|
2019-03-18 10:00:25 +00:00
|
|
|
|
|
|
|
# Exclude the cloud-run-instances manpage
|
2023-09-05 10:40:07 +00:00
|
|
|
rm -f %{buildroot}%{_mandir}/man1/cloud-run-instances.*
|
2019-10-24 07:34:35 +00:00
|
|
|
|
|
|
|
# Exclude euca2ools wrappers and manpages
|
2023-09-05 10:40:07 +00:00
|
|
|
rm -f %{buildroot}%{_bindir}/cloud-publish-*
|
|
|
|
rm -f %{buildroot}%{_mandir}/man1/cloud-publish-*
|
2013-02-18 17:33:01 +00:00
|
|
|
|
2023-12-12 09:22:07 +00:00
|
|
|
%if %{without growpart}
|
|
|
|
rm -f %{buildroot}%{_bindir}/growpart
|
|
|
|
rm -f %{buildroot}%{_mandir}/man1/growpart.*
|
|
|
|
%endif
|
|
|
|
|
2013-02-18 17:33:01 +00:00
|
|
|
|
|
|
|
%files
|
2014-07-11 20:40:44 +00:00
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
2023-09-08 13:21:29 +00:00
|
|
|
|
|
|
|
|
2023-12-12 09:22:07 +00:00
|
|
|
%if %{with growpart}
|
2023-09-08 13:21:29 +00:00
|
|
|
%files growpart
|
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
|
|
|
%{_bindir}/growpart
|
|
|
|
%doc %{_mandir}/man1/growpart.*
|
2023-12-12 09:22:07 +00:00
|
|
|
%endif
|
2023-09-08 13:21:29 +00:00
|
|
|
|
|
|
|
|
|
|
|
%files cloud-localds
|
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
2013-06-17 13:39:27 +00:00
|
|
|
%{_bindir}/cloud-localds
|
2023-09-08 13:21:29 +00:00
|
|
|
%doc %{_mandir}/man1/cloud-localds.*
|
|
|
|
|
|
|
|
|
|
|
|
%files write-mime-multipart
|
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
2013-06-17 13:39:27 +00:00
|
|
|
%{_bindir}/write-mime-multipart
|
2023-09-08 13:21:29 +00:00
|
|
|
%doc %{_mandir}/man1/write-mime-multipart.*
|
|
|
|
|
|
|
|
|
|
|
|
%files ec2metadata
|
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
2013-06-17 13:39:27 +00:00
|
|
|
%{_bindir}/ec2metadata
|
2023-09-08 13:21:29 +00:00
|
|
|
|
|
|
|
|
|
|
|
%files resize-part-image
|
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
2013-06-17 13:39:27 +00:00
|
|
|
%{_bindir}/resize-part-image
|
|
|
|
%doc %{_mandir}/man1/resize-part-image.*
|
|
|
|
|
|
|
|
|
2023-09-08 13:21:29 +00:00
|
|
|
%files mount-image-callback
|
2014-07-11 20:40:44 +00:00
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
2023-09-08 13:21:29 +00:00
|
|
|
%{_bindir}/mount-image-callback
|
|
|
|
|
|
|
|
|
|
|
|
%files vcs-run
|
|
|
|
%doc ChangeLog
|
|
|
|
%license LICENSE
|
|
|
|
%{_bindir}/vcs-run
|
2013-02-18 17:33:01 +00:00
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
2023-09-05 09:43:15 +00:00
|
|
|
%autochangelog
|