1 Star 0 Fork 5

jiangxinyu/ovirt-ansible-image-template

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
ovirt-ansible-image-template.spec 1.95 KB
一键复制 编辑 原始数据 按行查看 历史
liqiuyu 提交于 2021-12-17 14:33 . update to 1.2.2
%global rolename image-template
%global roleprefix ovirt.
%global roleprefix_legacy ovirt-
%global roleprefix_legacy_uppercase oVirt.
%global ansible_roles_dir ansible/roles
Name: ovirt-ansible-image-template
Summary: Ansible role to create virtual machine template from disk image
Version: 1.2.2
Release: 1
Source0: http://resources.ovirt.org/pub/src/%{name}/%{name}-%{version}.tar.gz
License: ASL 2.0
Group: Virtualization/Management
BuildArch: noarch
Url: http://www.ovirt.org
Requires: ansible >= 2.9.0
%description
This Ansible role provide funtionality to create virtual machine template from disk
image.
%pretrans -p <lua>
path_dash = "%{_datadir}/%{ansible_roles_dir}/%{roleprefix_legacy}%{rolename}"
path_uppercase = "%{_datadir}/%{ansible_roles_dir}/%{roleprefix_legacy_uppercase}%{rolename}"
st = posix.stat(path_dash)
if st and st.type == "directory" then
os.execute('rm -rf "'..path_dash..'"')
end
st = posix.stat(path_uppercase)
if st and st.type == "directory" then
os.execute('rm -rf "'..path_uppercase..'"')
end
%prep
%setup -c -q
%build
%install
export PKG_DATA_DIR_ORIG=%{_datadir}/%{ansible_roles_dir}/%{roleprefix}%{rolename}
export PKG_DATA_DIR=%{buildroot}$PKG_DATA_DIR_ORIG
export PKG_DOC_DIR=%{buildroot}%{_pkgdocdir}
export ROLENAME_LEGACY=%{buildroot}%{_datadir}/%{ansible_roles_dir}/%{roleprefix_legacy}%{rolename}
export ROLENAME_LEGACY_UPPERCASE=%{buildroot}%{_datadir}/%{ansible_roles_dir}/%{roleprefix_legacy_uppercase}%{rolename}
sh build.sh install
%files
%{_datadir}/%{ansible_roles_dir}/%{roleprefix}%{rolename}
%{_datadir}/%{ansible_roles_dir}/%{roleprefix_legacy}%{rolename}
%{_datadir}/%{ansible_roles_dir}/%{roleprefix_legacy_uppercase}%{rolename}
%doc README.md
%doc examples/
%license LICENSE
%changelog
* Fri Dec 17 2021 liqiuyu <liqiuyu@kylinos.cn> - 1.2.2-1
- upgrade package
* Wed Mar 04 2020 Huihui Fu <huihui.fu@cs2c.com.cn> - 1.1.12-1
- Package Initialization
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/jxy_git/ovirt-ansible-image-template.git
git@gitee.com:jxy_git/ovirt-ansible-image-template.git
jxy_git
ovirt-ansible-image-template
ovirt-ansible-image-template
master

搜索帮助