Blame SPECS/rhel-system-roles.spec

0c1b9b
%if 0%{?rhel} && ! 0%{?epel}
0c1b9b
%bcond_with ansible
0c1b9b
%else
0c1b9b
%bcond_without ansible
0c1b9b
%endif
0c1b9b
fdc326
%bcond_with collection_artifact
fdc326
fdc326
%if 0%{?fedora} || 0%{?rhel} >= 8
fdc326
%bcond_without html
fdc326
%else
fdc326
# pandoc is not supported in rhel 7 and older,
fdc326
# which is needed for converting .md to .html.
fdc326
%bcond_with html
fdc326
%endif
fdc326
190903
%if 0%{?rhel}
190903
Name: rhel-system-roles
190903
%else
190903
Name: linux-system-roles
190903
%endif
fdc326
Url: https://github.com/linux-system-roles
190903
Summary: Set of interfaces for unified system management
fdc326
Version: 1.7.3
fdc326
Release: 2%{?dist}
190903
190903
#Group: Development/Libraries
190903
License: GPLv3+ and MIT and BSD
0c1b9b
%global installbase %{_datadir}/linux-system-roles
0c1b9b
%global _pkglicensedir %{_licensedir}/%{name}
190903
%global rolealtprefix linux-system-roles.
190903
%global roleprefix %{name}.
0c1b9b
%global roleinstprefix %{nil}
0c1b9b
%global rolealtrelpath ../../linux-system-roles/
0c1b9b
%if 0%{?rhel}
0c1b9b
%global roleinstprefix %{roleprefix}
0c1b9b
%global installbase %{_datadir}/ansible/roles
0c1b9b
%global rolealtrelpath %{nil}
0c1b9b
%endif
0c1b9b
0c1b9b
%if 0%{?rhel}
0c1b9b
%global collection_namespace redhat
0c1b9b
%global collection_name rhel_system_roles
0c1b9b
%else
0c1b9b
%global collection_namespace fedora
0c1b9b
%global collection_name linux_system_roles
0c1b9b
%endif
0c1b9b
%global subrole_prefix "private_${role}_subrole_"
0c1b9b
0c1b9b
%global collection_version %{version}
0c1b9b
0c1b9b
# Helper macros originally from macros.ansible by Igor Raits <ignatenkobrain>
0c1b9b
# Not available on RHEL, so we must define those macros locally here without using ansible-galaxy
0c1b9b
0c1b9b
# Not used (yet). Could be made to point to AH in RHEL - but what about CentOS Stream?
0c1b9b
#%%{!?ansible_collection_url:%%define ansible_collection_url() https://galaxy.ansible.com/%%{collection_namespace}/%%{collection_name}}
0c1b9b
fdc326
%if 0%{?fedora} || 0%{?rhel} >= 8
0c1b9b
%{!?ansible_collection_files:%define ansible_collection_files %{_datadir}/ansible/collections/ansible_collections/%{collection_namespace}/}
fdc326
%else
fdc326
# Define undefined macro using "!?ansible_collection_files:..." does not work for rhel-7
fdc326
%if %{?ansible_collection_files:0}%{!?ansible_collection_files:1}
fdc326
%define ansible_collection_files %{_datadir}/ansible/collections/ansible_collections/%{collection_namespace}/
fdc326
%endif
fdc326
%endif
fdc326
0c1b9b
0c1b9b
%if %{with ansible}
0c1b9b
BuildRequires: ansible >= 2.9.10
0c1b9b
%endif
0c1b9b
0c1b9b
%if %{without ansible}
fdc326
# We don't have ansible-galaxy.
0c1b9b
# Simply copy everything instead of galaxy-installing the built artifact.
fdc326
%define ansible_collection_build_install() tar -cf %{_tmppath}/%{collection_namespace}-%{collection_name}-%{version}.tar.gz .; mkdir -p %{buildroot}%{ansible_collection_files}%{collection_name}; (cd %{buildroot}%{ansible_collection_files}%{collection_name}; tar -xf %{_tmppath}/%{collection_namespace}-%{collection_name}-%{version}.tar.gz)
0c1b9b
%else
fdc326
%define ansible_collection_build_install() ansible-galaxy collection build; ansible-galaxy collection install -n -p %{buildroot}%{_datadir}/ansible/collections %{collection_namespace}-%{collection_name}-%{version}.tar.gz
0c1b9b
%endif
190903
190903
# For each role, call either defcommit() or deftag(). The other macros
190903
# (%%id and %%shortid) can be then used in the same way in both cases.
190903
# This way  the rest of the spec file des not need to know whether we are
190903
# dealing with a tag or a commit.
0c1b9b
%global archiveext tar.gz
0c1b9b
# list of role names
0c1b9b
%global rolenames %nil
0c1b9b
# list of assignments that can be used to populate a bash associative array variable
0c1b9b
%global rolestodir %nil
0c1b9b
%define getarchivedir() %(p=%{basename:%{S:%{1}}}; echo ${p%%.%{archiveext}})
0c1b9b
0c1b9b
%define defcommit() %{expand:%%global ref%{1} %{2}
0c1b9b
%%global shortcommit%{1} %%(c=%%{ref%{1}}; echo ${c:0:7})
0c1b9b
%%global extractdir%{1} %%{expand:%%getarchivedir %{1}}
0c1b9b
%%{!?repo%{1}:%%global repo%{1} %%{rolename%{1}}}
fdc326
%%global archiveurl%{1} %%{?forgeorg%{1}}%%{!?forgeorg%{1}:%%{url}}/%%{repo%{1}}/archive/%%{ref%{1}}/%%{repo%{1}}-%%{ref%{1}}.tar.gz
0c1b9b
%%global rolenames %%{?rolenames} %%{rolename%{1}}
0c1b9b
%%global roletodir%{1} [%{rolename%{1}}]="%{extractdir%{1}}"
0c1b9b
%%global rolestodir %%{?rolestodir} %{roletodir%{1}}
190903
}
190903
0c1b9b
%define deftag() %{expand:%%global ref%{1} %{2}
0c1b9b
%%global extractdir%{1} %%{expand:%%getarchivedir %{1}}
0c1b9b
%%{!?repo%{1}:%%global repo%{1} %%{rolename%{1}}}
fdc326
%%global archiveurl%{1} %%{?forgeorg%{1}}%%{!?forgeorg%{1}:%%{url}}/%%{repo%{1}}/archive/%%{ref%{1}}/%%{repo%{1}}-%%{ref%{1}}.tar.gz
0c1b9b
%%global rolenames %%{?rolenames} %%{rolename%{1}}
0c1b9b
%%global roletodir%{1} [%{rolename%{1}}]="%{extractdir%{1}}"
0c1b9b
%%global rolestodir %%{?rolestodir} %%{roletodir%{1}}
190903
}
190903
fdc326
#%%defcommit 1 14314822b529520ac12964e0d2938c4bb18ab895
190903
%global rolename1 postfix
fdc326
%deftag 1 1.1.0
190903
fdc326
#%%defcommit 2 9fe6eb36772e83b53dcfb8ceb73608fd4f72eeda
190903
%global rolename2 selinux
fdc326
%deftag 2 1.3.0
190903
fdc326
#%%defcommit 3 8db8f9ed9088432bac7abf68f1b284475a3baa38
190903
%global rolename3 timesync
fdc326
%deftag 3 1.6.0
190903
fdc326
#%%defcommit 4 02fc72b482e165472624b2f68eecd2ddce1d93b1
0c1b9b
%global rolename4 kdump
fdc326
%deftag 4 1.1.0
0c1b9b
fdc326
#%%defcommit 5 b08a0b3748ee87aa3bdbcf1f0b7e41ef4971bbee
190903
%global rolename5 network
fdc326
%deftag 5 1.4.0
190903
fdc326
#%%defcommit 6 b3b456183edb7b8aa6ceff7ce667d8e22009ef6a
8b3abe
%global rolename6 storage
fdc326
%deftag 6 1.6.1
8b3abe
fdc326
#%%defcommit 7 0673d842fb32c437501e2aada2e38921da98e115
9693d8
%global rolename7 metrics
fdc326
%deftag 7 1.3.1
9693d8
fdc326
#%%defcommit 8 2b9e53233ee3a68bdb532e62f289733e436a6106
9693d8
%global rolename8 tlog
fdc326
%deftag 8 1.2.0
9693d8
fdc326
#%%defcommit 9 9373303b98e09ef38df7afc8d06e5e55812096c7
9693d8
%global rolename9 kernel_settings
fdc326
%deftag 9 1.1.0
9693d8
fdc326
#%%defcommit 10 20dd3e5520ca06dcccaa9b3f1fb428d055e0c23f
9693d8
%global rolename10 logging
fdc326
%deftag 10 1.5.1
9693d8
fdc326
#%%defcommit 11 c57d0b1f3384c525738fa26ba4bdca485e162567
9693d8
%global rolename11 nbde_server
fdc326
%deftag 11 1.1.0
9693d8
fdc326
#%%defcommit 12 bef2fad5e365712d1f40e53662490ba2550a253f
9693d8
%global rolename12 nbde_client
fdc326
%deftag 12 1.1.0
9693d8
fdc326
#%%defcommit 13 310fc53db04e8d3134524afb7a89b0477a2ffb83
9693d8
%global rolename13 certificate
fdc326
%deftag 13 1.1.0
0c1b9b
fdc326
#%%defcommit 14 b2a9857ac661fa32e66666e444b73bfdb34cdf95
0c1b9b
%global rolename14 crypto_policies
fdc326
%deftag 14 1.2.0
0c1b9b
fdc326
%global forgeorg15 https://github.com/willshersystems
0c1b9b
%global repo15 ansible-sshd
0c1b9b
%global rolename15 sshd
fdc326
%defcommit 15 1c5c48835e01adc176febf945e1fd36b7d9af7fd
fdc326
#%%deftag 15 v0.13.1
0c1b9b
fdc326
#%%defcommit 16 59b9fd7b25607d8bd33bdb082748955f2652846a
0c1b9b
%global rolename16 ssh
fdc326
%deftag 16 1.1.0
0c1b9b
fdc326
#%%defcommit 17 f901239cb91878719c9e7461760ef8d4789d626d
0c1b9b
%global rolename17 ha_cluster
fdc326
%deftag 17 1.3.0
0c1b9b
fdc326
#%%defcommit 18 5f6cb73e6753fbdbb219b7d3079f0378b2d3bdb3
fdc326
%global rolename18 vpn
fdc326
%deftag 18 1.2.0
fdc326
fdc326
%global mainid 2dd50c8a16af647e4c7a768c481335e97735958a
fdc326
Source: %{url}/auto-maintenance/archive/%{mainid}/auto-maintenance-%{mainid}.tar.gz
0c1b9b
Source1: %{archiveurl1}
0c1b9b
Source2: %{archiveurl2}
0c1b9b
Source3: %{archiveurl3}
0c1b9b
Source4: %{archiveurl4}
0c1b9b
Source5: %{archiveurl5}
0c1b9b
Source6: %{archiveurl6}
0c1b9b
Source7: %{archiveurl7}
0c1b9b
Source8: %{archiveurl8}
0c1b9b
Source9: %{archiveurl9}
0c1b9b
Source10: %{archiveurl10}
0c1b9b
Source11: %{archiveurl11}
0c1b9b
Source12: %{archiveurl12}
0c1b9b
Source13: %{archiveurl13}
0c1b9b
Source14: %{archiveurl14}
0c1b9b
Source15: %{archiveurl15}
0c1b9b
Source16: %{archiveurl16}
0c1b9b
Source17: %{archiveurl17}
fdc326
Source18: %{archiveurl18}
0c1b9b
0c1b9b
# Script to convert the collection README to Automation Hub.
0c1b9b
# Not used on Fedora.
0c1b9b
Source998: collection_readme.sh
190903
fdc326
Patch51: network-tier1-tags.diff
fdc326
Patch52: network-disable-bondtests.diff
69e14a
190903
BuildArch: noarch
190903
fdc326
%if %{with html}
fdc326
# Requirements for md2html.sh to build the documentation
fdc326
%if 0%{?fedora} || 0%{?rhel} >= 9
fdc326
BuildRequires: rubygem-kramdown-parser-gfm
fdc326
%else
190903
BuildRequires: pandoc
fdc326
BuildRequires: asciidoc
190903
BuildRequires: highlight
fdc326
%endif
fdc326
%endif
fdc326
fdc326
# Requirements for galaxy_transform.py
0c1b9b
BuildRequires: python3
fdc326
%if 0%{?fedora} || 0%{?rhel} >= 8
0c1b9b
BuildRequires: python3dist(ruamel.yaml)
190903
190903
Requires: python3-jmespath
fdc326
Requires: python3-netaddr
fdc326
%else
fdc326
BuildRequires: python3-ruamel-yaml
fdc326
fdc326
Requires: python-jmespath
fdc326
Requires: python-netaddr
fdc326
%endif
190903
190903
Obsoletes: rhel-system-roles-techpreview < 1.0-3
190903
0c1b9b
%if %{undefined __ansible_provides}
0c1b9b
Provides: ansible-collection(%{collection_namespace}.%{collection_name}) = %{collection_version}
0c1b9b
%endif
0c1b9b
# be compatible with the usual Fedora Provides:
0c1b9b
Provides: ansible-collection-%{collection_namespace}-%{collection_name} = %{version}-%{release}
0c1b9b
190903
# We need to put %%description within the if block to avoid empty
190903
# lines showing up.
190903
%if 0%{?rhel}
190903
%description
190903
Collection of Ansible roles and modules that provide a stable and
190903
consistent configuration interface for managing multiple versions
190903
of Red Hat Enterprise Linux.
190903
%else
190903
%description
190903
Collection of Ansible roles and modules that provide a stable and
190903
consistent configuration interface for managing multiple versions
190903
of Fedora, Red Hat Enterprise Linux & CentOS.
190903
%endif
190903
fdc326
%if %{with collection_artifact}
fdc326
%package collection-artifact
fdc326
Summary: Collection artifact to import to Automation Hub / Ansible Galaxy
fdc326
fdc326
%description collection-artifact
fdc326
Collection artifact for %{name}. This package contains %{collection_namespace}-%{collection_name}-%{version}.tar.gz
fdc326
%endif
fdc326
190903
%prep
fdc326
%setup -q -a1 -a2 -a3 -a4 -a5 -a6 -a7 -a8 -a9 -a10 -a11 -a12 -a13 -a14 -a15 -a16 -a17 -a18 -n %{getarchivedir 0}
0c1b9b
0c1b9b
declare -A ROLESTODIR=(%{rolestodir})
0c1b9b
for rolename in %{rolenames}; do
fdc326
    dir_from_archive="${ROLESTODIR[${rolename}]}"
fdc326
    if [ ! -d "$dir_from_archive" ]; then
fdc326
        # ansible-sshd uses tags like vX.Y.Z
fdc326
        # using the github archive/ link with a tag like this strips
fdc326
        # the leading v from the tag used to construct the directory
fdc326
        # name in the archive
fdc326
        if [[ "$dir_from_archive" =~ %{repo15}-v([0-9]+[.][0-9]+.*) ]]; then
fdc326
            dir_from_archive="%{repo15}-${BASH_REMATCH[1]}"
fdc326
        fi
fdc326
    fi
fdc326
    mv "$dir_from_archive" ${rolename}
0c1b9b
done
0c1b9b
fdc326
cd %{rolename2}/tests
fdc326
# this test causes avcs we want to ignore
fdc326
sed -r -i -e '/hosts: all/a\
fdc326
  tags:\
fdc326
    - tests::avc' tests_selinux_disabled.yml
fdc326
cd ../..
fdc326
0c1b9b
cd %{rolename5}
0c1b9b
%patch51 -p1
190903
%patch52 -p1
0c1b9b
cd ..
0c1b9b
cd %{rolename15}
fdc326
sed -r -i -e "s/ansible-sshd/linux-system-roles.sshd/" tests/*.yml examples/*.yml
fdc326
sed -r -i -e "s/ willshersystems.sshd/ linux-system-roles.sshd/" tests/*.yml examples/*.yml README.md
fdc326
sed -r -i -e "s/min_ansible_version: 2.8/min_ansible_version: 2.9/" meta/main.yml
69e14a
cd ..
190903
0c1b9b
# Replacing "linux-system-roles.rolename" with "rhel-system-roles.rolename" in each role
9693d8
%if "%{roleprefix}" != "linux-system-roles."
0c1b9b
for rolename in %{rolenames}; do
0c1b9b
    find $rolename -type f -exec \
9693d8
         sed "s/linux-system-roles[.]${rolename}\\>/%{roleprefix}${rolename}/g" -i {} \;
9693d8
done
9693d8
%endif
9693d8
0c1b9b
# Removing symlinks in tests/roles
0c1b9b
for rolename in %{rolenames}; do
0c1b9b
    if [ -d ${rolename}/tests/roles ]; then
0c1b9b
        find ${rolename}/tests/roles -type l -exec rm {} \;
0c1b9b
        if [ -d ${rolename}/tests/roles/linux-system-roles.${rolename} ]; then
0c1b9b
            rm -r ${rolename}/tests/roles/linux-system-roles.${rolename}
0c1b9b
        fi
0c1b9b
    fi
0c1b9b
done
0c1b9b
rm %{rolename5}/tests/modules
0c1b9b
rm %{rolename5}/tests/module_utils
0c1b9b
rm %{rolename5}/tests/playbooks/roles
fdc326
# Drop network/{scripts/print_all_options.py,tests/ensure_provider_tests.py}
fdc326
# from rpm. These 2 files fail in brp-python-bytecompile due to f-strings
fdc326
# when python2 is default python.
fdc326
rm %{rolename5}/scripts/print_all_options.py
fdc326
rm %{rolename5}/tests/ensure_provider_tests.py
fdc326
# Drop storage tests/scripts
fdc326
rm -rf %{rolename6}/tests/scripts
0c1b9b
0c1b9b
# transform ambiguous #!/usr/bin/env python shebangs to python3 to stop brp-mangle-shebangs complaining
0c1b9b
find -type f -executable -name '*.py' -exec \
0c1b9b
     sed -i -r -e '1s@^(#! */usr/bin/env python)(\s|$)@#\13\2@' '{}' +
0c1b9b
190903
%build
fdc326
%if %{with html}
fdc326
readmes=""
fdc326
for role in %{rolenames}; do
fdc326
    readmes="${readmes} $role/README.md"
fdc326
done
fdc326
sh md2html.sh $readmes
fdc326
%endif
0c1b9b
0c1b9b
mkdir .collections
0c1b9b
%if 0%{?rhel}
0c1b9b
# Convert the upstream collection readme to the downstream one
0c1b9b
%{SOURCE998} lsr_role2collection/collection_readme.md
0c1b9b
%endif
0c1b9b
./galaxy_transform.py "%{collection_namespace}" "%{collection_name}" "%{collection_version}" "Red Hat Enterprise Linux System Roles Ansible Collection" > galaxy.yml.tmp
0c1b9b
mv galaxy.yml.tmp galaxy.yml
0c1b9b
0c1b9b
for role in %{rolenames}; do
0c1b9b
    python3 lsr_role2collection.py --role "$role" --src-path "$role" \
0c1b9b
        --src-owner %{name} --subrole-prefix %{subrole_prefix} --dest-path .collections \
0c1b9b
        --readme lsr_role2collection/collection_readme.md \
0c1b9b
        --namespace %{collection_namespace} --collection %{collection_name}
0c1b9b
done
0c1b9b
fdc326
# copy requirements.txt and bindep.txt from auto-maintenance/lsr_role2collection
fdc326
if [ -f lsr_role2collection/collection_requirements.txt ]; then
fdc326
    cp lsr_role2collection/collection_requirements.txt \
fdc326
       .collections/ansible_collections/%{collection_namespace}/%{collection_name}/requirements.txt
fdc326
fi
fdc326
if [ -f lsr_role2collection/collection_bindep.txt ]; then
fdc326
    cp lsr_role2collection/collection_bindep.txt \
fdc326
       .collections/ansible_collections/%{collection_namespace}/%{collection_name}/bindep.txt
fdc326
fi
fdc326
0c1b9b
rm -f .collections/ansible_collections/%{collection_namespace}/%{collection_name}/tests/sanity/ignore-2.9.txt
0c1b9b
# Merge .sanity-ansible-ignore-2.9-ROLENAME.txt into tests/sanity/ignore-2.9.txt
0c1b9b
mkdir -p .collections/ansible_collections/%{collection_namespace}/%{collection_name}/tests/sanity
0c1b9b
for role in %{rolenames}; do
0c1b9b
    if [ -f .collections/ansible_collections/%{collection_namespace}/%{collection_name}/.sanity-ansible-ignore-2.9-"$role".txt ];
0c1b9b
    then
0c1b9b
      cat .collections/ansible_collections/%{collection_namespace}/%{collection_name}/.sanity-ansible-ignore-2.9-"$role".txt \
0c1b9b
        >> .collections/ansible_collections/%{collection_namespace}/%{collection_name}/tests/sanity/ignore-2.9.txt
0c1b9b
      rm -f .collections/ansible_collections/%{collection_namespace}/%{collection_name}/.sanity-ansible-ignore-*-"$role".txt
0c1b9b
    fi
0c1b9b
done
0c1b9b
0c1b9b
# removing dot files/dirs
0c1b9b
rm -r .collections/ansible_collections/%{collection_namespace}/%{collection_name}/.[A-Za-z]*
0c1b9b
0c1b9b
cp -p galaxy.yml lsr_role2collection/.ansible-lint \
0c1b9b
    .collections/ansible_collections/%{collection_namespace}/%{collection_name}
0c1b9b
fdc326
# Remove table of contents from logging README.md
fdc326
# It is not needed for html and AH/Galaxy
fdc326
sed -i -e 's/^\(## Table of Contents\)/## Background\n\1/' \
fdc326
  .collections/ansible_collections/%{collection_namespace}/%{collection_name}/roles/logging/README.md
fdc326
sed -i -e '/^## Table of Contents/,/^## Background/d' \
fdc326
  .collections/ansible_collections/%{collection_namespace}/%{collection_name}/roles/logging/README.md
fdc326
fdc326
# Remove internal links from readme files
fdc326
# They are not rendered properly on AH.
fdc326
for role in %{rolenames}; do
fdc326
    sed -r -i -e 's/\[([^[]+)\]\(#[^)]+\)/\1/g' \
fdc326
    .collections/ansible_collections/%{collection_namespace}/%{collection_name}/roles/$role/README.md
fdc326
done
190903
190903
%install
0c1b9b
mkdir -p $RPM_BUILD_ROOT%{installbase}
190903
mkdir -p $RPM_BUILD_ROOT%{_datadir}/ansible/roles
190903
fdc326
for role in %{rolenames}; do
fdc326
    cp -pR "$role" "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role"
fdc326
done
190903
190903
%if 0%{?rolealtprefix:1}
fdc326
for role in %{rolenames}; do
fdc326
    ln -s    "%{rolealtrelpath}%{roleinstprefix}$role"   "$RPM_BUILD_ROOT%{_datadir}/ansible/roles/%{rolealtprefix}$role"
fdc326
done
190903
%endif
190903
0c1b9b
mkdir -p $RPM_BUILD_ROOT%{_pkglicensedir}
fdc326
rm $RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}network/examples/roles
fdc326
for role in %{rolenames}; do
fdc326
    mkdir -p "$RPM_BUILD_ROOT%{_pkgdocdir}/$role"
fdc326
    cp -p "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/README.md" \
fdc326
       "$RPM_BUILD_ROOT%{_pkgdocdir}/$role"
fdc326
%if %{with html}
fdc326
    cp -p "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/README.html" \
fdc326
       "$RPM_BUILD_ROOT%{_pkgdocdir}/$role"
fdc326
%endif
fdc326
    if [ -f "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/COPYING" ]; then
fdc326
        cp -p "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/COPYING" \
fdc326
           "$RPM_BUILD_ROOT%{_pkglicensedir}/$role.COPYING"
fdc326
    fi
fdc326
    if [ -f "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/LICENSE" ]; then
fdc326
        cp -p "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/LICENSE" \
fdc326
           "$RPM_BUILD_ROOT%{_pkglicensedir}/$role.LICENSE"
fdc326
    fi
fdc326
    if [ -d "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/examples" ]; then
fdc326
        for file in "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/examples/"*.yml ; do
fdc326
            basename=$(basename "$file" .yml)
fdc326
            newname="$basename"
fdc326
            if [[ "$newname" != example-* ]]; then
fdc326
                newname="example-$newname"
fdc326
            fi
fdc326
            if [[ "$newname" != *-playbook ]]; then
fdc326
                newname="${newname}-playbook"
fdc326
            fi
fdc326
            cp "$file" "$RPM_BUILD_ROOT%{_pkgdocdir}/$role/${newname}.yml"
fdc326
            rm "$file"
fdc326
        done
fdc326
        if [ -f "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/examples/inventory" ]; then
fdc326
            cp "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/examples/inventory" \
fdc326
               "$RPM_BUILD_ROOT%{_pkgdocdir}/$role/example-inventory"
fdc326
            rm "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/examples/inventory"
fdc326
        fi
fdc326
        # special case for network
fdc326
        # this will error if the directory is unexpectedly empty
fdc326
        rmdir "$RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}$role/examples"
fdc326
    fi
fdc326
done
0c1b9b
0c1b9b
rm $RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}*/semaphore
0c1b9b
rm -r $RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}*/molecule
8b3abe
0c1b9b
rm -r $RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}*/.[A-Za-z]*
0c1b9b
rm $RPM_BUILD_ROOT%{installbase}/%{roleinstprefix}*/tests/.git*
0d64f8
fdc326
# NOTE: sshd/examples/example-root-login.yml is
0c1b9b
# referenced in the configuring-openssh-servers-using-the-sshd-system-role documentation module
0c1b9b
# must be updated if changing the file path
fdc326
fdc326
pushd .collections/ansible_collections/%{collection_namespace}/%{collection_name}/
fdc326
%ansible_collection_build_install
fdc326
popd
0c1b9b
0c1b9b
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/collection
0c1b9b
mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/collection/roles
0c1b9b
0c1b9b
cp -p %{buildroot}%{ansible_collection_files}%{collection_name}/README.md \
fdc326
   $RPM_BUILD_ROOT%{_pkgdocdir}/collection
0c1b9b
0c1b9b
for rolename in %{rolenames}; do
0c1b9b
  if [ -f %{buildroot}%{ansible_collection_files}%{collection_name}/roles/${rolename}/README.md ]; then
0c1b9b
    mkdir -p $RPM_BUILD_ROOT%{_pkgdocdir}/collection/roles/${rolename}
0c1b9b
    cp -p %{buildroot}%{ansible_collection_files}%{collection_name}/roles/${rolename}/README.md \
0c1b9b
        $RPM_BUILD_ROOT%{_pkgdocdir}/collection/roles/${rolename}
0c1b9b
  fi
0c1b9b
done
0c1b9b
fdc326
%if %{with html}
fdc326
# converting README.md to README.html for collection in $RPM_BUILD_ROOT%{_pkgdocdir}/collection
fdc326
readmes="$RPM_BUILD_ROOT%{_pkgdocdir}/collection/README.md"
fdc326
for role in %{rolenames}; do
fdc326
    readmes="${readmes} $RPM_BUILD_ROOT%{_pkgdocdir}/collection/roles/${role}/README.md"
fdc326
done
fdc326
sh md2html.sh $readmes
fdc326
%endif
9693d8
fdc326
%if %{with collection_artifact}
fdc326
# Copy collection artifact to /usr/share/ansible/collections/ for collection-artifact
fdc326
pushd .collections/ansible_collections/%{collection_namespace}/%{collection_name}/
fdc326
if [ -f %{collection_namespace}-%{collection_name}-%{version}.tar.gz ]; then
fdc326
    mv %{collection_namespace}-%{collection_name}-%{version}.tar.gz \
fdc326
       $RPM_BUILD_ROOT%{_datadir}/ansible/collections/
fdc326
fi
fdc326
popd
fdc326
%endif
fdc326
fdc326
# generate the %files section in the file files_section.txt
fdc326
format_item_for_files() {
fdc326
    # $1 is directory or file name in buildroot
fdc326
    # $2 - if true, and item is a directory, use %dir
fdc326
    local item
fdc326
    local files_item
fdc326
    item="$1"
fdc326
    files_item=${item##"%{buildroot}"}
fdc326
    if [ -L "$item" ]; then
fdc326
        echo "$files_item"
fdc326
    elif [ -d "$item" ]; then
fdc326
        if [[ "$item" == */doc* ]]; then
fdc326
            echo "%doc $files_item"
fdc326
        elif [ "${2:-false}" = true ]; then
fdc326
            echo "%dir $files_item"
fdc326
        else
fdc326
            echo "$files_item"
fdc326
        fi
fdc326
    elif [[ "$item" == */README.md ]] || [[ "$item" == */README.html ]]; then
fdc326
        if [[ "$item" == */private_* ]]; then
fdc326
            # mark as regular file, not %doc
fdc326
            echo "$files_item"
fdc326
        else
fdc326
            echo "%doc $files_item"
fdc326
        fi
fdc326
    elif [[ "$item" != */COPYING* ]] && [[ "$item" != */LICENSE* ]]; then
fdc326
        # Avoid dynamically using the license macro since the license macro
fdc326
        # is replaced with the value of License directive in the older rpmbuild.
fdc326
        echo "$files_item"
fdc326
    fi
fdc326
}
fdc326
fdc326
files_section=files_section.txt
fdc326
rm -f $files_section
fdc326
touch $files_section
0c1b9b
%if %{without ansible}
fdc326
echo '%dir %{_datadir}/ansible' >> $files_section
fdc326
echo '%dir %{_datadir}/ansible/roles' >> $files_section
0c1b9b
%endif
0c1b9b
%if "%{installbase}" != "%{_datadir}/ansible/roles"
fdc326
echo '%dir %{installbase}' >> $files_section
0c1b9b
%endif
fdc326
echo '%dir %{ansible_collection_files}' >> $files_section
fdc326
echo '%dir %{ansible_collection_files}%{collection_name}' >> $files_section
fdc326
find %{buildroot}%{ansible_collection_files}%{collection_name} -mindepth 1 -maxdepth 1 | \
fdc326
    while read item; do
fdc326
        if [[ "$item" == */roles ]]; then
fdc326
            format_item_for_files "$item" true >> $files_section
fdc326
            find "$item" -mindepth 1 -maxdepth 1 | while read roles_dir; do
fdc326
                format_item_for_files "$roles_dir" true >> $files_section
fdc326
                find "$roles_dir" -mindepth 1 -maxdepth 1 | while read roles_item; do
fdc326
                    format_item_for_files "$roles_item" >> $files_section
fdc326
                done
fdc326
            done
fdc326
        else
fdc326
            format_item_for_files "$item" >> $files_section
fdc326
        fi
fdc326
    done
fdc326
fdc326
find %{buildroot}%{installbase} -mindepth 1 -maxdepth 1 | \
fdc326
    while read item; do
fdc326
        if [ -d "$item" ]; then
fdc326
            format_item_for_files "$item" true >> $files_section
fdc326
            find "$item" -mindepth 1 -maxdepth 1 | while read roles_item; do
fdc326
                format_item_for_files "$roles_item" >> $files_section
fdc326
            done
fdc326
        else
fdc326
            format_item_for_files "$item" >> $files_section
fdc326
        fi
fdc326
    done
fdc326
if [ "%{installbase}" != "%{_datadir}/ansible/roles" ]; then
fdc326
    find %{buildroot}%{_datadir}/ansible/roles -mindepth 1 -maxdepth 1 | \
fdc326
        while read item; do
fdc326
            if [ -d "$item" ]; then
fdc326
                format_item_for_files "$item" true >> $files_section
fdc326
                find "$item" -mindepth 1 -maxdepth 1 | while read roles_item; do
fdc326
                    format_item_for_files "$roles_item" >> $files_section
fdc326
                done
fdc326
            else
fdc326
                format_item_for_files "$item" >> $files_section
fdc326
            fi
fdc326
        done
fdc326
fi
fdc326
# cat files_section.txt
fdc326
# done with files_section.txt generation
fdc326
fdc326
fdc326
%files -f files_section.txt
0c1b9b
%{_pkgdocdir}/*/README.md
fdc326
%if %{with html}
0c1b9b
%{_pkgdocdir}/*/README.html
fdc326
%endif
fdc326
%{_pkgdocdir}/*/example-*
0c1b9b
%{_pkgdocdir}/collection/roles/*/README.md
fdc326
%if %{with html}
0c1b9b
%{_pkgdocdir}/collection/roles/*/README.html
fdc326
%endif
0c1b9b
%license %{_pkglicensedir}/*
fdc326
%license %{installbase}/*/COPYING*
fdc326
%license %{installbase}/*/LICENSE*
fdc326
%license %{ansible_collection_files}/%{collection_name}/COPYING*
fdc326
%license %{ansible_collection_files}/%{collection_name}/LICENSE*
fdc326
%if 0%{?rhel} < 8
fdc326
# Needs to list excluded files in this hardcoded style since when
fdc326
# format_item_for_files is executed, brp-python-bytecompile is not
fdc326
# executed yet.
fdc326
%exclude %{installbase}/*/*.py?
fdc326
%exclude %{installbase}/*/*/*.py?
fdc326
%exclude %{installbase}/*/*/*/*.py?
fdc326
%exclude %{installbase}/*/*/*/*/*.py?
fdc326
%exclude %{ansible_collection_files}/%{collection_name}/*/*/*.py?
fdc326
%exclude %{ansible_collection_files}/%{collection_name}/*/*/*/*.py?
fdc326
%exclude %{ansible_collection_files}/%{collection_name}/*/*/*/*/*.py?
fdc326
%endif
fdc326
fdc326
%if %{with collection_artifact}
fdc326
%files collection-artifact
fdc326
%{_datadir}/ansible/collections/%{collection_namespace}-%{collection_name}-%{version}.tar.gz
fdc326
%endif
190903
190903
%changelog
fdc326
* Thu Aug 26 2021 Rich Megginson <rmeggins@redhat.com> - 1.7.3-2
fdc326
- selinux - tag tests_selinux_disabled.yml with tests::avc
fdc326
  Resolves rhbz#1996315 (EL9)
fdc326
  Resolves rhbz#1996317 (EL8)
fdc326
fdc326
* Thu Aug 26 2021 Rich Megginson <rmeggins@redhat.com> - 1.7.3-1
fdc326
- storage - revert the dm-vdo workaround fix for vdo testing
fdc326
  Resolves rhbz#1978488 (EL9)
fdc326
  Resolves rhbz#1991141 (EL8)
fdc326
fdc326
* Tue Aug 24 2021 Rich Megginson <rmeggins@redhat.com> - 1.7.2-1
fdc326
- logging - Update the certificates copy tasks
fdc326
  Resolves rhbz#1996777 (EL9)
fdc326
  Resolves rhbz#1994580 (EL8)
fdc326
fdc326
* Mon Aug 16 2021 Rich Megginson <rmeggins@redhat.com> - 1.7.1-1
fdc326
- metrics - the bpftrace role does not properly configure bpftrace agent
fdc326
  Resolves rhbz#1994180 (EL9)
fdc326
  Resolves rhbz#1993240 (EL8)
fdc326
fdc326
* Thu Aug 12 2021 Rich Megginson <rmeggins@redhat.com> - 1.7.0-1
fdc326
- drop support for Ansible 2.8 - min_ansible_version is now 2.9
fdc326
  Resolves rhbz#1989197 (EL9)
fdc326
  Resolves rhbz#1989199 (EL8)
fdc326
- sshd - fix rhel6 support - failed to validate: error:Missing Match criteria for all Bad Match condition
fdc326
  Resolves rhbz#1991598 (EL9)
fdc326
  Resolves rhbz#1990947 (EL8)
fdc326
fdc326
* Fri Aug 06 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.7-1
fdc326
- storage - tests_create_lvmvdo_then_remove fails - Module dm-vdo not found
fdc326
  Resolves rhbz#1991141 (EL8)
fdc326
  Resolves rhbz#1991062 (EL9)
fdc326
- storage - Get syntax errors in tests_lvm_errors.yml
fdc326
  Resolves rhbz#1990793 (EL8)
fdc326
  Resolves rhbz#1991142 (EL9)
fdc326
fdc326
* Fri Aug 06 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.6-1
fdc326
- logging, certificate - Instead of the archive module, use "tar" command for backup.
fdc326
  Resolves rhbz#1984182 (EL9)
fdc326
  Resolves rhbz#1987096 (EL8)
fdc326
- logging - Add a support for list value to server_host in the elasticsearch output
fdc326
  Resolves rhbz#1986460 (EL9)
fdc326
  Resolves rhbz#1986463 (EL8)
fdc326
- logging - tests_relp.yml; Can't detect any of the required Python libraries cryptography (>= 1.2.3) or PyOpenSSL (>= 0.6)
fdc326
  Resolves rhbz#1989962 (EL9)
fdc326
  Resolves rhbz#1990142 (EL8)
fdc326
fdc326
* Fri Aug 06 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.5-1
fdc326
- kernel_settings - Disable bootloader testing on EL9
fdc326
  Resolves rhbz#1991017
fdc326
fdc326
* Tue Aug 03 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.4-1
fdc326
- sshd - support for rhel9 managed hosts
fdc326
  Resolves rhbz#1989221 (EL9)
fdc326
  Resolves rhbz#1989638 (EL8)
fdc326
fdc326
* Tue Aug 03 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.3-1
fdc326
- storage - tag tests that use NVME and SCSI
fdc326
  Resolves rhbz#1989211 (EL9)
fdc326
  Resolves rhbz#1989638 (EL8)
fdc326
fdc326
* Fri Jul 30 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.2-1
fdc326
- metrics - Grafana dashboard not working after metrics role run unless services manually restarted
fdc326
  Resolves rhbz#1984150 (EL9)
fdc326
  Resolves rhbz#1978357 (EL8)
fdc326
fdc326
* Thu Jul 29 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.1-1
fdc326
- network - tests_provider_nm.yml fails with an error: Failure in test 'I can manage a veth interface with NM after I managed it with initscripts.
fdc326
  Resolves rhbz#1935919
fdc326
- network - _initscripts tests fail because "No package network-scripts available."
fdc326
  Resolves rhbz#1935916
fdc326
- network - Test tests_bond_initscripts.yml failed to create interface
fdc326
  Resolves rhbz#1980870
fdc326
- storage - covscan error - DEADCODE - vdopool if create_vdo else parent
fdc326
  Resolves rhbz#1985571 (EL9)
fdc326
  Resolves rhbz#1985572 (EL8)
fdc326
- network - network: tests_bond_initscripts.yml leaves behind unusable resolv.conf in CI
fdc326
  Resolves rhbz#1915017
fdc326
fdc326
* Wed Jul 28 2021 Rich Megginson <rmeggins@redhat.com> - 1.6.0-1
fdc326
- network - Skip tests on RHEL9 that use hostapd
fdc326
  Resolves rhbz#1945348
fdc326
- network - Fix the bond test on DHCP
fdc326
  Resolves rhbz#1918252
fdc326
- storage - Add support for percentage-based volume sizes
fdc326
  Resolves rhbz#1984583 (EL9)
fdc326
  Resolves rhbz#1894642 (EL8)
fdc326
- storage -storage_test_actual_size != storage_test_requested_size observed with tests_lvm_auto_size_cap.yml
fdc326
  Resolves rhbz#1986284 (EL8)
fdc326
fdc326
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.5.1-1
fdc326
- Error: device becoming unmanaged and pytest not reproducible in tests_integration_pytest.yl
fdc326
  Resolves rhbz#1985382 (EL9)
fdc326
  Resolves rhbz#1932699 (EL8)
fdc326
- EPEL yum repository configuration for tests
fdc326
  Rebasing to latest picks up this fix - see rhel7 bz1980439
fdc326
- connections: workaround DeprecationWarning for NM.SettingEthtool.set_feature()
fdc326
  Rebasing to latest picks up this fix
fdc326
fdc326
* Thu Jul 15 2021 Rich Megginson <rmeggins@redhat.com> - 1.5.0-1
fdc326
- ha_cluster - add pacemaker cluster properties configuration
fdc326
  Resolves rhbz#1982913 (EL8)
fdc326
  Resolves rhbz#1982906 (EL9)
fdc326
fdc326
* Thu Jul 15 2021 Rich Megginson <rmeggins@redhat.com> - 1.4.3-1
fdc326
- crypto_policies - rename 'policy modules' to 'subpolicies'
fdc326
  Resolves rhbz#1982896 (EL9)
fdc326
  Resolves rhbz#1982897 (EL8)
fdc326
fdc326
* Thu Jul 15 2021 Rich Megginson <rmeggins@redhat.com> - 1.4.2-1
fdc326
- storage - relabel doesn't support - Fixed volume relabeling
fdc326
  Resolves rhbz#1876315 (EL8)
fdc326
  Resolves rhbz#1982841 (EL9)
fdc326
fdc326
* Fri Jul  9 2021 Rich Megginson <rmeggins@redhat.com> - 1.4.1-1
fdc326
- network - Re-running the network system role results in "changed: true" when nothing has actually changed
fdc326
  Resolves rhbz#1943384
fdc326
- network - Test tests_bond_initscripts.yml failed to create interface
fdc326
  Resolves rhbz#1918210
fdc326
fdc326
* Thu Jul  8 2021 Rich Megginson <rmeggins@redhat.com> - 1.4.0-1
fdc326
- storage - LVMVDO support
fdc326
  Resolves rhbz#1882475
fdc326
  Resolves rhbz#1978488
fdc326
fdc326
* Wed Jun 23 2021 Rich Megginson <rmeggins@redhat.com> - 1.3.0-1
fdc326
- ha_cluster - add pacemaker resources configuration
fdc326
  Resolves rhbz#1963283
fdc326
- ha_cluster - code cleanup
fdc326
  Resolves rhbz#1970666
fdc326
- Postfix RHEL system role README.md missing variables under the "Role Variables" section
fdc326
  Resolves rhbz#1961858
fdc326
- logging README.html examples are rendered incorrectly
fdc326
  Resolves rhbz#1962374
fdc326
- make postfix role idempotent - round 2
fdc326
  Resolves rhbz#1960375
fdc326
- selinux task for semanage says Fedora in name but also runs on RHEL/CentOS 8
fdc326
  Resolves rhbz#1966681
fdc326
- metrics role task to enable logging for targeted hosts not working
fdc326
  Resolves rhbz#1967335
fdc326
- network - Add 'auto_gateway' option
fdc326
  Resolves rhbz#1897565
fdc326
- network - Only show stderr_lines by default
fdc326
  Resolves rhbz#1970666
fdc326
- storage - LVMVDO support
fdc326
  Resolves rhbz#1882475
fdc326
- storage - fix several linter issues
fdc326
  Resolves rhbz#1970666
fdc326
- ssh - Fix variable precedence when invoked through roles
fdc326
  Resolves rhbz#1966711
fdc326
- ssh - Update configuration options list for OpenSSH 8.6
fdc326
  Resolves rhbz#1970666
fdc326
- sshd - Fix variable precedence when invoked through roles
fdc326
  Resolves rhbz#1966711
fdc326
- sshd - Update configuration options list for OpenSSH 8.6
fdc326
  Resolves rhbz#1970666
fdc326
- sshd - support for appending a snippet to configuration file
fdc326
  Resolves rhbz#1970642
fdc326
- timesync - add NTS support
fdc326
  Resolves rhbz#1970664
fdc326
- timesync - rebase to latest
fdc326
  Resolves rhbz#1970666
fdc326
- nbde_client - rebase to latest
fdc326
  Resolves rhbz#1970666
fdc326
fdc326
* Thu Jun 17 2021 Sergei Petrosian <spetrosi@redhat.com> - 1.2.3-3
fdc326
- Make the ansible_collection_files macro defined in Fedora automatically and
fdc326
  in RHEL manually consistent - having slash at the end to clean double-slashes
fdc326
fdc326
* Wed Jun 16 2021 Sergei Petrosian <spetrosi@redhat.com> - 1.2.3-2
fdc326
- Remove slash (/) from the end of URLs to improve code readability
fdc326
fdc326
* Wed Jun 16 2021 Noriko Hosoi <nhosoi@redhat.com> - 1.2.3-1
fdc326
- Add EL 9 support for timesync and network
fdc326
  Resolves rhbz#1952887
fdc326
fdc326
* Tue Jun 15 2021 Rich Megginson <rmeggins@redhat.com> - 1.2.2-3
fdc326
- Fix HTML rendering of internal links when using pandoc/asciidoc
fdc326
- Uses pandoc gfm instead of markdown_github
fdc326
  Resolves rhbz#1962976
fdc326
fdc326
* Fri Jun 11 2021 Noriko Hosoi <nhosoi@redhat.com> - 1.2.2-2
fdc326
- Make spec file available for older versions of OSes.
fdc326
- Drop python3-six dependency which was used by lsr_role2collection.py.
fdc326
- Drop html files from rpm if the version has no markdown parser.
fdc326
- Drop unnecessary python scripts which include python3 only code, e.g.,
fdc326
  f-strings.
fdc326
- auto_maintenance - ability to convert "- ROLENAME" to "- FQCN" in the doc files such as README
fdc326
- auto_maintenance - lsr_role2collection.py - Adding encoding="utf-8" to open.
fdc326
  Resolves rhbz#1957876
fdc326
fdc326
* Wed Jun  9 2021 Rich Megginson <rmeggins@redhat.com> - 1.2.2-1
fdc326
- fix kdump tests_ssh for basic smoke test
fdc326
  Resolves rhbz#1957876
fdc326
- ha_cluster - cannot read preshared key in binary format
fdc326
  Resolves rhbz#1952620
fdc326
- Add hybrid_e2e option to PTP domain
fdc326
  Resolves rhbz#1957849
fdc326
fdc326
* Fri May 21 2021 Noriko Hosoi <nhosoi@redhat.com> - 1.2.1-1
fdc326
- fix logging README.html examples' rendering problems
fdc326
  Resolves rhbz#1962374
fdc326
- fix broken internal links in README.md files
fdc326
  Resolves rhbz#1962976
fdc326
fdc326
* Mon May 17 2021 Sergei Petrosian <spetrosi@redhat.com> - 1.2.0-2
fdc326
- Add BuildRequires: rubygem-kramdown for Fedora and RHEL >= 9
fdc326
fdc326
* Fri May 14 2021 Rich Megginson <rmeggins@redhat.com> - 1.2.0-1
fdc326
- rebase roles to latest upstream
fdc326
  Resolves rhbz#1957876
fdc326
- use FQRN in postfix README
fdc326
  Resolves rhbz#1958963
fdc326
- use relayhost in postfix README
fdc326
  Resolves rhbz#1866544
fdc326
- network - Add support for ETHTOOL Ring option
fdc326
  Resolves rhbz#1959649
fdc326
- storage: calltrace observed when set type: partition for storage_pools
fdc326
  Resolves rhbz#1854187
fdc326
fdc326
* Thu May 13 2021 Noriko Hosoi <nhosoi@redhat.com> - 1.1.0-2
fdc326
- Dependencies in the collection packaging
fdc326
  Resolves rhbz#1954747
fdc326
fdc326
* Wed Apr 14 2021 Rich Megginson <rmeggins@redhat.com> - 1.1.0-1
fdc326
- rebase timesync role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- timesync - add timesync_chrony_custom_settings variable for free-form
fdc326
  local configs
fdc326
  Resolves rhbz#1938023
fdc326
- do not use ignore_errors in timesync role
fdc326
  Resolves rhbz#1938014
fdc326
- support for timesync_max_distance to configure maxdistance/maxdist parameter
fdc326
  Resolves rhbz#1938016
fdc326
- support for ntp xleave, filter, and hw timestamping
fdc326
  Resolves rhbz#1938020
fdc326
- rebase selinux role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- should not reload the SELinux policy if its not changed
fdc326
  Resolves rhbz#1757869
fdc326
- Ability to install custom SELinux module via Ansible
fdc326
  Resolves rhbz#1848683
fdc326
- rebase storage role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- rebase network role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- support for ipv6_disabled to disable ipv6 for address
fdc326
  Resolves rhbz#1939711
fdc326
- rebase postfix role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- rebase metrics role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- rebase sshd role to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- rebase remaining roles to latest upstream
fdc326
  Resolves rhbz#1937938
fdc326
- Generate %%files dynamically
fdc326
- add vpn role
fdc326
  Resolves rhbz#1943679
fdc326
fdc326
* Tue Apr 13 2021 Noriko Hosoi <nhosoi@redhat.com> - 1.0.1-2
fdc326
- Adding the -collection-artifact subpackage, enabled using
fdc326
  "--with collection_artifact". It is used for importing to
fdc326
  ansible galaxy/automation hub.
fdc326
- README.html files (main README for the collection and README
fdc326
  for each role) are not located in /usr/share/ansible/collections,
fdc326
  but just put in /usr/share/doc/linux-system-roles/collection in rpm.
fdc326
- The README.html files are not included in the collection artifact.
fdc326
- Fixing "sshd role README.md examples use incorrect role name".
fdc326
0c1b9b
* Wed Mar 17 2021 Noriko Hosoi <nhosoi@redhat.com> - 1.0.1-1
0c1b9b
- Fix description field in galaxy.yml
0c1b9b
- Remove "Technology Preview" from Collection README
0c1b9b
- Merging individual ignore file and add it to the package
0c1b9b
- Add a note to each module Doc to indicate it is private
0c1b9b
- Add patches for network and storage role ansible-test fixes
0c1b9b
  Resolves rhbz#1935451
0c1b9b
- Simplify doc tags in %%files, corrects a forgotten doc tag for ha_cluster
0c1b9b
- Suppress one ansible-lint warning in ha_cluster
0c1b9b
0c1b9b
* Tue Feb 23 2021 Fernando Fernandez Mancera <ferferna@redhat.com> - 1.0.0-32
0c1b9b
- Add patch for the inclusive language leftover on network-role README.md,
0c1b9b
  Resolves rhbz#1931931
0c1b9b
0c1b9b
* Mon Feb 22 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0.0-31
0c1b9b
- Rebase certificate role to pick up a test fix, Resolves rhbz#1931568
0c1b9b
- Rebase logging role to fix default private key path,
0c1b9b
  upstream PR #218
0c1b9b
0c1b9b
* Mon Feb 22 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0.0-30
0c1b9b
- Correct merge botch in previous (ssh/README.md is a doc file)
0c1b9b
- Update galaxy.yml even on Fedora, auto-maintenance may not have
0c1b9b
  a consistent version number
0c1b9b
- Update collection doc transformation to match a modified text
0c1b9b
  and include the Tech Preview note again
0c1b9b
0c1b9b
* Thu Feb 18 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0.0-29
0c1b9b
- Change internal role prefix to more descriptive private_${role}_subrole_
0c1b9b
- Sync spec improvements from Fedora and introduce helper macros
0c1b9b
  No functional change except for license files location
0c1b9b
- Disable mssql metrics test on non-x86_64 where the packages
0c1b9b
  are not available. Upstream PR #73
0c1b9b
0c1b9b
* Wed Feb 17 2021 Rich Megginson <rmeggins@redhat.com> - 1.0.0-28
0c1b9b
- Add patch for sshd https://github.com/willshersystems/ansible-sshd/pull/155
0c1b9b
  for ansible 2.8/jinja 2.7 support for sshd role
0c1b9b
- Rebase certificate, kernel_settings, nbde_client for jinja27
0c1b9b
- Rebase the logging role, Resolves rhbz#1927943
0c1b9b
- Rebase storage role, Resolves rhbz#1894651 - interpreatation of
0c1b9b
  omitted parameters
0c1b9b
- Apply storage PR #201 to dispense with the need of listing all disks
0c1b9b
  in existing pools, Resolves rhbz1894676
0c1b9b
- Apply storage PR #199 to allow reducing the requested volume sizes
0c1b9b
  if needed to fit, Resolves rhbz1894647
0c1b9b
- Rebase the network role, Resolves rhbz1893959, rhbz1893957
0c1b9b
- Add the ssh client role, Resolves rhbz1893712
0c1b9b
- Minor issue in selinux - no variable named present
0c1b9b
  Resolves rhbz1926947
0c1b9b
- Prefix internal roles with private_, resolves rhbz#1927417
0c1b9b
- Add the ha_cluster role, Resolves rhbz#1893743
0c1b9b
0c1b9b
* Thu Feb 11 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0.0-27
0c1b9b
- Rebase the logging role, Resolves rhbz#1889484
0c1b9b
- Fixes to collection docs and galaxy metadata from nhosoi
0c1b9b
- Apply network PR #350 Resolves rhbz#1927392
0c1b9b
0c1b9b
* Wed Feb  3 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0.0-26
0c1b9b
- Rebase the metrics role, Resolves rhbz#1895188, rhbz#1893908
0c1b9b
0c1b9b
* Tue Jan 26 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0.0-25
0c1b9b
- Apply storage PR #153 to fix a problem with partition name on NVMe devices
0c1b9b
  Resolves: rhbz1865990
0c1b9b
- Remove symlinks to roles under tests
0c1b9b
- Cleanup of role directories - remove files starting with . in roles' root
0c1b9b
  directories and Git files under tests. Resolves rhbz#1650550
0c1b9b
- Add collection support, make Version semver compatible: 1.0 -> 1.0.0
0c1b9b
  Resolves rhbz#1893906
0c1b9b
- Autogenerate Automation-Hub README.md if building for RHEL
0c1b9b
- Renumber sources, Source is now auto-maintenance since it is the root
0c1b9b
  of the source tree, kdump becomes Source4 (4 was originally firewall)
0c1b9b
- Introduce bcond_with/without ansible, work on Fedora, RHEL and EPEL
0c1b9b
- Rebase certificate role to include collection-related workarounds,
0c1b9b
  no change in behavior intended
0c1b9b
- Rebase network role, includes collection-related workarounds
0c1b9b
- Revert an invasive network change to enable EPEL (PR #335) and implement
0c1b9b
  a minimal version
0c1b9b
0c1b9b
* Fri Jan 15 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0-24
0c1b9b
- Apply PR #63 for kdump to fix a problem in test introduced by rebase
0c1b9b
0c1b9b
* Fri Jan  8 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0-23
0c1b9b
- Add {crypto_policies,sshd}/README.md to docfiles, thanks jjelen
0c1b9b
- Fix role name in selinux patch
0c1b9b
- Add sshd role example and README fix
0c1b9b
- Fix role name in sshd role tests and docs
0c1b9b
- Backport network role PR #298 to fix problems often triggered by the CI
0c1b9b
  "error: down connection failed while waiting", Resolves rhbz#1817242
0c1b9b
- Disable bond test in downstream CI, it started to break DNS in RHEL 8.4.
0c1b9b
  Related rhbz#1915017
0c1b9b
0c1b9b
* Thu Jan  7 2021 Pavel Cahyna <pcahyna@redhat.com> - 1.0-22
0c1b9b
- Rebase kdump, certificate, storage, selinux, nbde_client/server,
0c1b9b
  kernel_settings in preparation for collections
0c1b9b
  Includes upstream PR #168 for storage to prevent toggling encryption
0c1b9b
  in safe mode, as it is a destructive operation. Resolves rhbz#1881524
0c1b9b
- Introduce & use simpler macros for Sources management,
0c1b9b
  similar to %%forgemeta
0c1b9b
  https://docs.fedoraproject.org/en-US/packaging-guidelines/SourceURL/
0c1b9b
- Use a script to perform prefix transformation for all roles to reduce
0c1b9b
  the number of patches
0c1b9b
- Rebase tlog to add exclude_{users,groups} support, Resolves rhbz#1895472
0c1b9b
- Add crypto_policies role, Resolves rhbz#1893699
0c1b9b
- Add sshd role, Resolves rhbz#1893696
9693d8
9693d8
* Mon Aug 24 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-19
9693d8
- Rebase network role to latest upstream, resolves rhbz#1800627
9693d8
  Drop a downstream patch with a test workaround that is not needed anymore.
9693d8
- Fix script for role prefix transformation
9693d8
- Rebase metrics role to pick up test changes, PR #19
9693d8
- Rebase kernel_settings role to latest upstream, resolves rhbz#1851557
9693d8
9693d8
* Mon Aug 24 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-18
9693d8
- Rebase storage role to latest upstream, resolves rhbz#1848254, rhbz#1851654,
9693d8
  rhbz#1862867
9693d8
- Rebase nbde_client role to latest upstream, resolves rhbz#1851654
9693d8
- Rebase logging role to latest upstream, resolves rhbz#1851654, rhbz#1861318
9693d8
- Rebase metrics role to latest upstream, resolves rhbz#1869390, rhbz#1869389,
9693d8
  rhbz#1868378
9693d8
9693d8
* Fri Aug 21 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-17
9693d8
- Rebase certificate role to latest upstream, resolves rhbz#1859547
9693d8
9693d8
* Mon Aug 10 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-16
9693d8
- Rebase logging role to latest upstream, resolves rhbz#1854546, rhbz#1861318,
9693d8
  rhbz#1860896, adds test for rhbz#1850790
9693d8
- Rebase metrics role to latest upstream, resolves rhbz#1855544, rhbz#1855539,
9693d8
  rhbz#1848763
9693d8
- Fix whitespace in postfix role patch
9693d8
9693d8
* Fri Jul 31 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-15
9693d8
- Rebase storage role to latest upstream, resolves rhbz#1854191, rhbz#1848250,
9693d8
  rhbz#1850790 (including test)
9693d8
- Rebase nbde_client role to latest upstream, adds test for rhbz#1850790
9693d8
- Rebase certificate role to latest upstream, adds test for rhbz#1850790
9693d8
- Rebase nbde_server role to latest upstream, resolves rhbz#1850790
9693d8
  (including test)
9693d8
- Rebase tlog role to latest upstream, resolves rhbz#1855424
9693d8
- Rebase kernel_settings role to rev b8bc86b, resolves rhbz#1850790
9693d8
- Add EL 8 to supported versions in postfix and kdump role metadata,
9693d8
  resolves rhbz#1861661
9693d8
9693d8
* Mon Jul 20 2020 Rich Megginson <rmeggins@redhat.com> - 1.0-14
9693d8
- Rebase certificate role to latest upstream, resolves rhbz#1858840
9693d8
9693d8
* Fri Jul 17 2020 Rich Megginson <rmeggins@redhat.com> - 1.0-13
9693d8
- Rebase certificate role to latest upstream, resolves rhbz#1858316, rhbz#1848745
9693d8
9693d8
* Mon Jun 29 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-12
9693d8
- Rebase network role to latest upstream, resolves rhbz#1822777, rhbz#1848472
9693d8
- Rebase logging role to latest upstream, resolves rhbz#1850790,
9693d8
  rhbz#1851804, rhbz#1848762
9693d8
- Rebase certificate role to latest upstream, resolves rhbz#1848742,
9693d8
  rhbz#1850790
9693d8
- Rebase nbde_client role to latest upstream, resolves rhbz#1848766,
9693d8
  rhbz#1850790
9693d8
9693d8
* Mon Jun 15 2020 Pavel Cahyna <pcahyna@redhat.com> - 1.0-11
9693d8
- Rebase network role to latest upstream
9693d8
- Remove all the soon-unnecessary tier1 tags in test
9693d8
- Add a workaround for rhbz#1800627 in test
9693d8
- Modify patches to remove tier1 tags
9693d8
- Add metrics, tlog, logging, kernel_settings roles
9693d8
- Add nbde_client, nbde_server, certificate roles
9693d8
- Rebase storage role to latest upstream: adds support for mdraid, LUKS,
9693d8
  swap manangement
9693d8
47f324
* Mon Oct 21 2019 Pavel Cahyna <pcahyna@redhat.com> - 1.0-10
47f324
- Add the storage_safe_mode option, true by default, to prevent accidental
47f324
  data removal: rhbz#1763242, issue #42, PR #43 and #51.
47f324
8b3abe
* Thu Aug 15 2019 Pavel Cahyna <pcahyna@redhat.com> - 1.0-9
8b3abe
- Add the storage role
8b3abe
8b3abe
* Thu Jun 13 2019 Pavel Cahyna <pcahyna@redhat.com> - 1.0-7
8b3abe
- Update tests for the network role
8b3abe
- Fix typo in a test for the timesync role
8b3abe
- Tag tests suitable for Tier1 testing
8b3abe
- Rebase the network role to add support for device features (PR#115,
8b3abe
  rhbz#1696703) and atomic changes (PR#119, rhbz#1695161)
8b3abe
- network: apply upstream PR#121: allow modifying interface attributes
8b3abe
  without disrupting services (rhbz#1695157)
8b3abe
0d64f8
* Wed May 29 2019 Pavel Cahyna <pcahyna@redhat.com> - 1.0-6
0d64f8
- Rebase the selinux role, fixes typo in tests, uncovered by Ansible 2.7,
0d64f8
  (rhbz#1677743) and lists all input variables in defaults
0d64f8
  to make Satellite aware of them (rhbz#1674004, PR#43)
0d64f8
- Rebase the kdump role to fix check mode problems: rhbz#1685904
0d64f8
- Rebase the timesync role: fixes check mode problems (rhbz#1685904)
0d64f8
  and lists all input variables in defaults (rhbz#1674004)
0d64f8
- Rebase the network role: keeps the interface up for state: up
0d64f8
  if persistent_state is absent and solves problems with defining
0d64f8
  VLAN and MACVLAN interface types (issue #19) (rhbz#1685902)
0d64f8
190903
* Sat Jan 12 2019 Pavel Cahyna <pcahyna@redhat.com> - 1.0-5
190903
- spec file improvement: Unify the source macros with deftag() and defcommit()
190903
- Update to upstream released versions and drop unnecessary patches.
190903
- Unify the spec file with Fedora (no functional changes intended).
190903
- Misc spec file comments fixes (by Mike DePaulo)
190903
- Fix rpmlint error by escaping a previous changelog entry with a macro (by Mike DePaulo)
190903
- Comply with Fedora guidelines by always using "cp -p" in %%install (by Mike DePaulo)
190903
- Rebase network role - doc improvements, Fedora 29 and Ansible 2.7 support
190903
- Regenerate network role patch to apply without offset
190903
- Rebase kdump role to fix a forgotten edit, rhbz#1645633
190903
- Update timesync examples: add var prefix (rhbz#1642152), correct role prefix
190903
- Add Obsoletes for the -techpreview subpackage
190903
- Add warnings to role READMEs and other doc updates, rhbz#1616018
190903
- network: split the state setting into state and persistent_state, rhbz#1616014
190903
- depend on python-jmespath as Ansible will not ship it, rhbz#1660559
190903
190903
* Tue Aug 14 2018 Pavel Cahyna <pcahyna@redhat.com> - 1.0-4
190903
- Format the READMEs as html, by vdolezal, with changes to use highlight
190903
  (source-highlight does not understand YAML)
190903
190903
* Thu Aug  9 2018 Pavel Cahyna <pcahyna@redhat.com> - 1.0-3
190903
- Rebase the network role to the last revision (d866422).
190903
  Many improvements to tests, introduces autodetection of the current provider
190903
  and defaults to using profile name as interface name.
190903
- Rebase the selinux, timesync and kdump roles to their 1.0rc1 versions.
190903
  Many changes to the role interfaces to make them more consistent
190903
  and conforming to Ansible best practices.
190903
- Update the description.
190903
190903
* Fri May 11 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-4
190903
- Fix complaints about /usr/bin/python during RPM build by making the affected scripts non-exec
190903
- Fix merge botch
190903
190903
* Mon Mar 19 2018 Troy Dawson <tdawson@redhat.com> - 0.6-3.1
0c1b9b
- Use -a (after cd) instead of -b (before cd) in %%setup
190903
190903
* Wed Mar 14 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-3
190903
- Minor corrections of the previous change by Till Maas.
190903
190903
* Fri Mar  9 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-2
190903
- Document network role options: static routes, ethernet, dns
190903
  Upstream PR#36, bz1550128, documents bz1487747 and bz1478576
190903
190903
* Tue Jan 30 2018 Pavel Cahyna <pcahyna@redhat.com> - 0.6-1
190903
- Drop hard dependency on ansible (#1525655), patch from Yaakov Selkowitz
190903
- Update the network role to version 0.4, solves bz#1487747, bz#1478576
190903
190903
* Tue Dec 19 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.5-3
190903
- kdump: fix the wrong conditional for ssh checking and improve test (PR#10)
190903
190903
* Tue Nov 07 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.5-2
190903
- kdump: add ssh support. upstream PR#9, rhbz1478707
190903
190903
* Tue Oct 03 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.5-1
190903
- SELinux: fix policy reload when SELinux is disabled on CentOS/RHEL 6
190903
  (bz#1493574)
190903
- network: update to b856c7481bf5274d419f71fb62029ea0044b3ec1 :
190903
  makes the network role idempotent (bz#1476053) and fixes manual
190903
  network provider selection (bz#1485074).
190903
190903
* Mon Aug 28 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.4-1
190903
- network: update to b9b6f0a7969e400d8d6ba0ac97f69593aa1e8fa5:
190903
  ensure that state:absent followed by state:up works (bz#1478910), and change
190903
  the example IP adresses to the IANA-assigned ones.
190903
- SELinux: fix the case when SELinux is disabled (bz#1479546).
190903
190903
* Tue Aug 8 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.3-2
190903
- We can't change directories to symlinks (rpm bug #447156) so keep the old
190903
  names and create the new names as symlinks.
190903
190903
* Tue Aug 8 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.3-1
190903
- Change the prefix to linux-system-roles., keeping compatibility
190903
  symlinks.
190903
- Update the network role to dace7654feb7b5629ded0734c598e087c2713265:
190903
  adds InfiniBand support and other fixes.
190903
- Drop a patch included upstream.
190903
190903
* Mon Jun 26 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.2-2
190903
- Leave a copy of README and COPYING in every role's directory, as suggested by T. Bowling.
190903
- Move the network example inventory to the documentation directory together.
190903
  with the example playbooks and delete the now empty "examples" directory.
190903
- Use proper reserved (by RFC 7042) MAC addresses in the network examples.
190903
190903
* Tue Jun 6 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.2-1
190903
- Update the networking role to version 0.2 (#1459203)
190903
- Version every role and the package separately. They live in separate repos
190903
  and upstream release tags are not coordinated.
190903
190903
* Mon May 22 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.1-2
190903
- Prefix the roles in examples and documentation with rhel-system-roles.
190903
190903
* Thu May 18 2017 Pavel Cahyna <pcahyna@redhat.com> - 0.1-1
190903
- Update to 0.1 (first upstream release).
190903
- Remove the tuned role, it is not ready yet.
190903
- Move the example playbooks to /usr/share/doc/rhel-system-roles/$SUBSYSTEM
190903
  directly to get rid of an extra directory.
190903
- Depend on ansible.
190903
190903
* Thu May 4 2017  Pavel Cahyna <pcahyna@redhat.com> - 0-0.1.20170504
190903
- Initial release.
190903
- kdump r. fe8bb81966b60fa8979f3816a12b0c7120d71140
190903
- postfix r. 43eec5668425d295dce3801216c19b1916df1f9b
190903
- selinux r. 1e4a21f929455e5e76dda0b12867abaa63795ae7
190903
- timesync r. 33a1a8c349de10d6281ed83d4c791e9177d7a141
190903
- tuned r. 2e8bb068b9815bc84287e9b6dc6177295ffdf38b
190903
- network r. 03ff040df78a14409a0d89eba1235b8f3e50a750
190903