1 Star 0 Fork 4

tianlijing/ovirt-ansible-vm-infra

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
ovirt-ansible-vm-infra.spec 2.19 KB
一键复制 编辑 原始数据 按行查看 历史
tianlijing 提交于 2022-09-20 14:14 . update to 1.2.3
%global rolename vm-infra
%global roleprefix ovirt.
%global roleprefix_legacy ovirt-
%global roleprefix_legacy_uppercase oVirt.
%global ansible_roles_dir ansible/roles
Name: ovirt-ansible-vm-infra
Summary: Ansible role to create virtual machine infrastructure
Version: 1.2.3
Release: 1
Source0: http://resources.ovirt.org/pub/src/ovirt-ansible-vm-infra/ovirt-ansible-vm-infra-1.2.3.tar.gz
License: ASL 2.0
Group: Virtualization/Management
BuildArch: noarch
Url: http://www.ovirt.org
Requires: ansible >= 2.7.2
%description
This Ansible role provide funtionality to create virtual machine infrastructure.
%pretrans -p <lua>
-- Remove the legacy directory before installing the symlink. This is known issue in RPM:
-- https://fedoraproject.org/wiki/Packaging:Directory_Replacement
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
* Tue Sep 20 2022 tianlijing <tianlijing@kylinos.cn> - 1.2.3-1
- update to 1.2.3
* Fri Apr 1 2022 liqiuyu <liqiuyu@kylinos.cn> - 1.1.22-2
- Remove the dist
* Tue Mar 3 2020 changjie.fu <changjie.fu@cs2c.com.cn> - 1.1.22-1
- Package Initialization
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/tianlijing/ovirt-ansible-vm-infra.git
git@gitee.com:tianlijing/ovirt-ansible-vm-infra.git
tianlijing
ovirt-ansible-vm-infra
ovirt-ansible-vm-infra
master

搜索帮助