|
|
|
@ -1,66 +1,50 @@
|
|
|
|
|
%global __brp_check_rpaths %{nil}
|
|
|
|
|
## For Python 3 only
|
|
|
|
|
|
|
|
|
|
%bcond_with tests
|
|
|
|
|
%bcond_with docs
|
|
|
|
|
# Release Candidate
|
|
|
|
|
%global __rc_ver %{nil}
|
|
|
|
|
|
|
|
|
|
# Disable build-id symlinks
|
|
|
|
|
%define _build_id_links none
|
|
|
|
|
%undefine _missing_build_ids_terminate_build
|
|
|
|
|
%global fish_dir %{_datadir}/fish/vendor_functions.d
|
|
|
|
|
%global zsh_dir %{_datadir}/zsh/site-functions
|
|
|
|
|
|
|
|
|
|
# Disable private libraries from showing in provides
|
|
|
|
|
%global __provides_exclude_from ^.*\\.so.*$
|
|
|
|
|
%global __requires_exclude_from ^.*\\.so.*$
|
|
|
|
|
|
|
|
|
|
# Disable python bytecompile for MANY reasons
|
|
|
|
|
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
|
|
|
|
|
|
|
|
|
|
%define fish_dir %{_datadir}/fish/vendor_functions.d
|
|
|
|
|
# py3_shbang_flags is '-s' and causing issues with pip install.
|
|
|
|
|
%global py3_shebang_flags %(echo %py3_shebang_flags | sed s/s//)
|
|
|
|
|
|
|
|
|
|
Name: salt
|
|
|
|
|
Version: 3005.1
|
|
|
|
|
Release: 4%{?dist}
|
|
|
|
|
Version: 3005.1%{?__rc_ver}
|
|
|
|
|
Release: 4%{?dist}.inferit
|
|
|
|
|
Summary: A parallel remote execution system
|
|
|
|
|
Group: System Environment/Daemons
|
|
|
|
|
License: ASL 2.0
|
|
|
|
|
URL: http://saltstack.org/
|
|
|
|
|
Source0: %{name}-%{version}.tar.gz
|
|
|
|
|
Source1: build.conf
|
|
|
|
|
Source3: requirements.txt
|
|
|
|
|
Source5: %{name}-proxy@.service
|
|
|
|
|
URL: https://saltproject.io/
|
|
|
|
|
Source0: %{pypi_source}
|
|
|
|
|
Source1: %{name}-proxy@.service
|
|
|
|
|
Source2: %{name}-master
|
|
|
|
|
Source3: %{name}-syndic
|
|
|
|
|
Source4: %{name}-minion
|
|
|
|
|
Source5: %{name}-api
|
|
|
|
|
Source6: %{name}-master.service
|
|
|
|
|
Source7: %{name}-syndic.service
|
|
|
|
|
Source8: %{name}-minion.service
|
|
|
|
|
Source9: %{name}-api.service
|
|
|
|
|
Source10: README.fedora
|
|
|
|
|
Source10: README
|
|
|
|
|
Source11: %{name}-common.logrotate
|
|
|
|
|
Source12: salt.bash
|
|
|
|
|
Source13: salt.fish
|
|
|
|
|
Source14: salt_common.fish
|
|
|
|
|
Source15: salt-call.fish
|
|
|
|
|
Source16: salt-cp.fish
|
|
|
|
|
Source17: salt-key.fish
|
|
|
|
|
Source18: salt-master.fish
|
|
|
|
|
Source19: salt-minion.fish
|
|
|
|
|
Source20: salt-run.fish
|
|
|
|
|
Source21: salt-syndic.fish
|
|
|
|
|
Source22: salt
|
|
|
|
|
Source23: salt-master
|
|
|
|
|
Source24: salt-minion
|
|
|
|
|
Source25: salt-api
|
|
|
|
|
Source26: salt-cp
|
|
|
|
|
Source27: salt-key
|
|
|
|
|
Source28: salt-run
|
|
|
|
|
Source29: salt-cloud
|
|
|
|
|
Source30: salt-ssh
|
|
|
|
|
Source31: salt-syndic
|
|
|
|
|
Source32: salt-call
|
|
|
|
|
Source33: salt-proxy
|
|
|
|
|
Source34: spm
|
|
|
|
|
Source35: salt-pip
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
|
|
|
|
BuildArch: x86_64
|
|
|
|
|
Source12: %{name}.bash
|
|
|
|
|
Source13: %{name}.fish
|
|
|
|
|
Source14: %{name}_common.fish
|
|
|
|
|
Source15: %{name}-call.fish
|
|
|
|
|
Source16: %{name}-cp.fish
|
|
|
|
|
Source17: %{name}-key.fish
|
|
|
|
|
Source18: %{name}-master.fish
|
|
|
|
|
Source19: %{name}-minion.fish
|
|
|
|
|
Source20: %{name}-run.fish
|
|
|
|
|
Source21: %{name}-syndic.fish
|
|
|
|
|
|
|
|
|
|
Patch0: contextvars.patch
|
|
|
|
|
|
|
|
|
|
# Added MSVSphere support
|
|
|
|
|
Patch100: 0001-Added-MSVSphere-support.patch
|
|
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
|
|
%ifarch %{ix86} x86_64
|
|
|
|
|
Requires: dmidecode
|
|
|
|
@ -68,20 +52,12 @@ Requires: dmidecode
|
|
|
|
|
|
|
|
|
|
Requires: pciutils
|
|
|
|
|
Requires: which
|
|
|
|
|
Requires: openssl
|
|
|
|
|
|
|
|
|
|
Requires: dnf-utils
|
|
|
|
|
Requires: logrotate
|
|
|
|
|
|
|
|
|
|
%if 0%{?systemd_preun:1}
|
|
|
|
|
Requires(post): systemd-units
|
|
|
|
|
Requires(preun): systemd-units
|
|
|
|
|
Requires(postun): systemd-units
|
|
|
|
|
%endif
|
|
|
|
|
BuildRequires: systemd-rpm-macros
|
|
|
|
|
BuildRequires: python3-devel
|
|
|
|
|
|
|
|
|
|
BuildRequires: systemd-units
|
|
|
|
|
#BuildRequires: python3
|
|
|
|
|
#BuildRequires: python3-devel
|
|
|
|
|
#BuildRequires: openssl-devel
|
|
|
|
|
BuildRequires: git
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
Salt is a distributed remote execution system used to execute commands and
|
|
|
|
@ -96,9 +72,11 @@ servers, handle them quickly and through a simple and manageable interface.
|
|
|
|
|
Summary: Management component for salt, a parallel remote execution system
|
|
|
|
|
Group: System Environment/Daemons
|
|
|
|
|
Requires: %{name} = %{version}-%{release}
|
|
|
|
|
Requires: python3-systemd
|
|
|
|
|
|
|
|
|
|
%description master
|
|
|
|
|
The Salt master is the central server to which all minions connect.
|
|
|
|
|
Supports Python 3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package minion
|
|
|
|
@ -109,6 +87,7 @@ Requires: %{name} = %{version}-%{release}
|
|
|
|
|
%description minion
|
|
|
|
|
The Salt minion is the agent component of Salt. It listens for instructions
|
|
|
|
|
from the master, runs jobs, and returns results back to the master.
|
|
|
|
|
Supports Python 3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package syndic
|
|
|
|
@ -120,25 +99,30 @@ Requires: %{name}-master = %{version}-%{release}
|
|
|
|
|
The Salt syndic is a master daemon which can receive instruction from a
|
|
|
|
|
higher-level master, allowing for tiered organization of your Salt
|
|
|
|
|
infrastructure.
|
|
|
|
|
Supports Python 3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package api
|
|
|
|
|
Summary: REST API for Salt, a parallel remote execution system
|
|
|
|
|
Group: Applications/System
|
|
|
|
|
Requires: %{name}-master = %{version}-%{release}
|
|
|
|
|
Requires: python3-cherrypy >= 3.2.2
|
|
|
|
|
|
|
|
|
|
%description api
|
|
|
|
|
salt-api provides a REST interface to the Salt master.
|
|
|
|
|
Supports Python 3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package cloud
|
|
|
|
|
Summary: Cloud provisioner for Salt, a parallel remote execution system
|
|
|
|
|
Group: Applications/System
|
|
|
|
|
Requires: %{name}-master = %{version}-%{release}
|
|
|
|
|
Requires: python3-libcloud
|
|
|
|
|
|
|
|
|
|
%description cloud
|
|
|
|
|
The salt-cloud tool provisions new cloud VMs, installs salt-minion on them, and
|
|
|
|
|
adds them to the master's collection of controllable minions.
|
|
|
|
|
Supports Python 3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%package ssh
|
|
|
|
@ -149,281 +133,189 @@ Requires: %{name} = %{version}-%{release}
|
|
|
|
|
%description ssh
|
|
|
|
|
The salt-ssh tool can run remote execution functions and states without the use
|
|
|
|
|
of an agent (salt-minion) service.
|
|
|
|
|
Supports Python 3.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
tar xvf %{SOURCE0}
|
|
|
|
|
%autosetup -p1
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
mv_srcdir=$RPM_BUILD_DIR/%{name}-3005.1
|
|
|
|
|
mv_dstdir=$RPM_BUILD_DIR/%{name}-%{version}
|
|
|
|
|
if [ "${mv_srcdir}" != "${mv_dstdir}" ]; then
|
|
|
|
|
mv ${mv_srcdir} ${mv_dstdir}
|
|
|
|
|
fi
|
|
|
|
|
cd %{name}-%{version}
|
|
|
|
|
PYTHONPATH="/usr/local/lib/python3.6/site-packages/:/usr/local/lib64/python3.6/site-packages/" tiamat --log-level=debug build -c %{SOURCE1} -r %{SOURCE3}
|
|
|
|
|
find . -name __pycache__ | xargs rm -fR
|
|
|
|
|
pwd
|
|
|
|
|
ls -l
|
|
|
|
|
python3 setup.py build
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
rm -rf %{buildroot}
|
|
|
|
|
#cd $RPM_BUILD_DIR/%{name}-%{version}
|
|
|
|
|
pwd
|
|
|
|
|
ls -l
|
|
|
|
|
mkdir -p %{buildroot}/opt/saltstack/salt
|
|
|
|
|
# pip installs directory
|
|
|
|
|
mkdir -p %{buildroot}/opt/saltstack/salt/pypath/
|
|
|
|
|
cp -ra %{name}-%{version}/dist/run %{buildroot}/opt/saltstack/salt
|
|
|
|
|
python3 setup.py install --root=%{buildroot}
|
|
|
|
|
|
|
|
|
|
# Add some directories
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_var}/log/salt
|
|
|
|
|
touch %{buildroot}%{_var}/log/salt/minion
|
|
|
|
|
touch %{buildroot}%{_var}/log/salt/master
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_var}/cache/salt
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/salt
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/salt/master.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/salt/minion.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/salt/pki
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/pki/master
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/pki/minion
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/cloud.conf.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/cloud.deploy.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/cloud.maps.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/cloud.profiles.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/salt/cloud.providers.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/salt/proxy.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_bindir}
|
|
|
|
|
|
|
|
|
|
# Add helper scripts
|
|
|
|
|
install -m 0755 %{SOURCE22} %{buildroot}%{_bindir}/salt
|
|
|
|
|
install -m 0755 %{SOURCE23} %{buildroot}%{_bindir}/salt-master
|
|
|
|
|
install -m 0755 %{SOURCE24} %{buildroot}%{_bindir}/salt-minion
|
|
|
|
|
install -m 0755 %{SOURCE25} %{buildroot}%{_bindir}/salt-api
|
|
|
|
|
install -m 0755 %{SOURCE26} %{buildroot}%{_bindir}/salt-cp
|
|
|
|
|
install -m 0755 %{SOURCE27} %{buildroot}%{_bindir}/salt-key
|
|
|
|
|
install -m 0755 %{SOURCE28} %{buildroot}%{_bindir}/salt-run
|
|
|
|
|
install -m 0755 %{SOURCE29} %{buildroot}%{_bindir}/salt-cloud
|
|
|
|
|
install -m 0755 %{SOURCE30} %{buildroot}%{_bindir}/salt-ssh
|
|
|
|
|
install -m 0755 %{SOURCE31} %{buildroot}%{_bindir}/salt-syndic
|
|
|
|
|
install -m 0755 %{SOURCE32} %{buildroot}%{_bindir}/salt-call
|
|
|
|
|
install -m 0755 %{SOURCE33} %{buildroot}%{_bindir}/salt-proxy
|
|
|
|
|
install -m 0755 %{SOURCE34} %{buildroot}%{_bindir}/spm
|
|
|
|
|
install -m 0755 %{SOURCE35} %{buildroot}%{_bindir}/salt-pip
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_var}/log/%{name}
|
|
|
|
|
touch %{buildroot}%{_var}/log/%{name}/minion
|
|
|
|
|
touch %{buildroot}%{_var}/log/%{name}/master
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_var}/cache/%{name}
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/master.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/minion.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/pki
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/pki/master
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/pki/minion
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/%{name}/cloud.conf.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/%{name}/cloud.deploy.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/%{name}/cloud.maps.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/%{name}/cloud.profiles.d
|
|
|
|
|
install -d -m 0700 %{buildroot}%{_sysconfdir}/%{name}/cloud.providers.d
|
|
|
|
|
install -d -m 0755 %{buildroot}%{_sysconfdir}/%{name}/proxy.d
|
|
|
|
|
|
|
|
|
|
# Add the config files
|
|
|
|
|
install -p -m 0640 %{name}-%{version}/conf/minion %{buildroot}%{_sysconfdir}/salt/minion
|
|
|
|
|
install -p -m 0640 %{name}-%{version}/conf/master %{buildroot}%{_sysconfdir}/salt/master
|
|
|
|
|
install -p -m 0600 %{name}-%{version}/conf/cloud %{buildroot}%{_sysconfdir}/salt/cloud
|
|
|
|
|
install -p -m 0640 %{name}-%{version}/conf/roster %{buildroot}%{_sysconfdir}/salt/roster
|
|
|
|
|
install -p -m 0640 %{name}-%{version}/conf/proxy %{buildroot}%{_sysconfdir}/salt/proxy
|
|
|
|
|
install -p -m 0640 conf/minion %{buildroot}%{_sysconfdir}/%{name}/minion
|
|
|
|
|
install -p -m 0640 conf/master %{buildroot}%{_sysconfdir}/%{name}/master
|
|
|
|
|
install -p -m 0600 conf/cloud %{buildroot}%{_sysconfdir}/%{name}/cloud
|
|
|
|
|
install -p -m 0640 conf/roster %{buildroot}%{_sysconfdir}/%{name}/roster
|
|
|
|
|
install -p -m 0640 conf/proxy %{buildroot}%{_sysconfdir}/%{name}/proxy
|
|
|
|
|
|
|
|
|
|
# Add the unit files
|
|
|
|
|
mkdir -p %{buildroot}%{_unitdir}
|
|
|
|
|
install -p -m 0644 %{SOURCE5} %{buildroot}%{_unitdir}/
|
|
|
|
|
install -p -m 0644 %{SOURCE6} %{buildroot}%{_unitdir}/
|
|
|
|
|
install -p -m 0644 %{SOURCE7} %{buildroot}%{_unitdir}/
|
|
|
|
|
install -p -m 0644 %{SOURCE8} %{buildroot}%{_unitdir}/
|
|
|
|
|
install -p -m 0644 %{SOURCE9} %{buildroot}%{_unitdir}/
|
|
|
|
|
install -p -m 0644 %{SOURCE1} %{buildroot}%{_unitdir}/
|
|
|
|
|
|
|
|
|
|
# Logrotate
|
|
|
|
|
install -p %{SOURCE10} .
|
|
|
|
|
mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d/
|
|
|
|
|
install -p -m 0644 %{SOURCE11} %{buildroot}%{_sysconfdir}/logrotate.d/salt
|
|
|
|
|
install -p -m 0644 %{SOURCE11} %{buildroot}%{_sysconfdir}/logrotate.d/%{name}
|
|
|
|
|
|
|
|
|
|
# Bash completion
|
|
|
|
|
mkdir -p %{buildroot}%{_sysconfdir}/bash_completion.d/
|
|
|
|
|
install -p -m 0644 %{SOURCE12} %{buildroot}%{_sysconfdir}/bash_completion.d/salt.bash
|
|
|
|
|
install -p -m 0644 %{SOURCE12} %{buildroot}%{_sysconfdir}/bash_completion.d/%{name}.bash
|
|
|
|
|
|
|
|
|
|
# Fish completion (TBD remove -v)
|
|
|
|
|
mkdir -p %{buildroot}%{fish_dir}
|
|
|
|
|
install -p -m 0644 %{SOURCE13} %{buildroot}%{fish_dir}/salt.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE14} %{buildroot}%{fish_dir}/salt_common.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE15} %{buildroot}%{fish_dir}/salt-call.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE16} %{buildroot}%{fish_dir}/salt-cp.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE17} %{buildroot}%{fish_dir}/salt-key.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE18} %{buildroot}%{fish_dir}/salt-master.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE19} %{buildroot}%{fish_dir}/salt-minion.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE20} %{buildroot}%{fish_dir}/salt-run.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE21} %{buildroot}%{fish_dir}/salt-syndic.fish
|
|
|
|
|
|
|
|
|
|
# Man files
|
|
|
|
|
mkdir -p %{buildroot}%{_mandir}/man1
|
|
|
|
|
mkdir -p %{buildroot}%{_mandir}/man7
|
|
|
|
|
ls -alh %{name}-%{version}/*
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/spm.1 %{buildroot}%{_mandir}/man1/spm.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt.1 %{buildroot}%{_mandir}/man1/salt.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt.7 %{buildroot}%{_mandir}/man7/salt.7
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-cp.1 %{buildroot}%{_mandir}/man1/salt-cp.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-key.1 %{buildroot}%{_mandir}/man1/salt-key.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-master.1 %{buildroot}%{_mandir}/man1/salt-master.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-run.1 %{buildroot}%{_mandir}/man1/salt-run.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-call.1 %{buildroot}%{_mandir}/man1/salt-call.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-minion.1 %{buildroot}%{_mandir}/man1/salt-minion.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-proxy.1 %{buildroot}%{_mandir}/man1/salt-proxy.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-syndic.1 %{buildroot}%{_mandir}/man1/salt-syndic.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-api.1 %{buildroot}%{_mandir}/man1/salt-api.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-cloud.1 %{buildroot}%{_mandir}/man1/salt-cloud.1
|
|
|
|
|
install -p -m 0644 %{name}-%{version}/doc/man/salt-ssh.1 %{buildroot}%{_mandir}/man1/salt-ssh.1
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%clean
|
|
|
|
|
rm -rf %{buildroot}
|
|
|
|
|
install -p -m 0644 %{SOURCE13} %{buildroot}%{fish_dir}/%{name}.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE14} %{buildroot}%{fish_dir}/%{name}_common.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE15} %{buildroot}%{fish_dir}/%{name}-call.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE16} %{buildroot}%{fish_dir}/%{name}-cp.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE17} %{buildroot}%{fish_dir}/%{name}-key.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE18} %{buildroot}%{fish_dir}/%{name}-master.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE19} %{buildroot}%{fish_dir}/%{name}-minion.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE20} %{buildroot}%{fish_dir}/%{name}-run.fish
|
|
|
|
|
install -p -m 0644 %{SOURCE21} %{buildroot}%{fish_dir}/%{name}-syndic.fish
|
|
|
|
|
|
|
|
|
|
# ZSH completion
|
|
|
|
|
mkdir -p %{buildroot}%{zsh_dir}
|
|
|
|
|
install -p -m 0644 pkg/%{name}.zsh %{buildroot}%{zsh_dir}/_%{name}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files
|
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
|
%{_sysconfdir}/logrotate.d/salt
|
|
|
|
|
%{_sysconfdir}/bash_completion.d/salt.bash
|
|
|
|
|
%{_var}/cache/salt
|
|
|
|
|
%{_var}/log/salt
|
|
|
|
|
/opt/saltstack/
|
|
|
|
|
/opt/saltstack/salt
|
|
|
|
|
/opt/saltstack/salt/run
|
|
|
|
|
/opt/saltstack/salt/pypath
|
|
|
|
|
|
|
|
|
|
%doc %{_mandir}/man1/spm.1*
|
|
|
|
|
%license LICENSE
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/bash_completion.d/%{name}.bash
|
|
|
|
|
%{_var}/cache/%{name}
|
|
|
|
|
%{_var}/log/%{name}
|
|
|
|
|
%{_prefix}/lib/python3.6
|
|
|
|
|
%{_bindir}/spm
|
|
|
|
|
%{_bindir}/salt-pip
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/
|
|
|
|
|
#%config(noreplace) %{_sysconfdir}/salt/pki
|
|
|
|
|
%config(noreplace) %{fish_dir}/salt*.fish
|
|
|
|
|
%doc %{_mandir}/man1/spm.1*
|
|
|
|
|
%dir %{zsh_dir}
|
|
|
|
|
%dir %{_sysconfdir}/%{name}/
|
|
|
|
|
%dir %{_sysconfdir}/%{name}/pki/
|
|
|
|
|
%{fish_dir}/%{name}*.fish
|
|
|
|
|
%{zsh_dir}/_%{name}
|
|
|
|
|
|
|
|
|
|
%files master
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%doc %{_mandir}/man7/salt.7*
|
|
|
|
|
%doc %{_mandir}/man1/salt.1*
|
|
|
|
|
%doc %{_mandir}/man1/salt-cp.1*
|
|
|
|
|
%doc %{_mandir}/man1/salt-key.1*
|
|
|
|
|
%doc %{_mandir}/man1/salt-master.1*
|
|
|
|
|
%doc %{_mandir}/man1/salt-run.1*
|
|
|
|
|
%{_bindir}/salt
|
|
|
|
|
%{_bindir}/salt-cp
|
|
|
|
|
%{_bindir}/salt-key
|
|
|
|
|
%{_bindir}/salt-master
|
|
|
|
|
%{_bindir}/salt-run
|
|
|
|
|
%{_unitdir}/salt-master.service
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/master
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/master.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/pki/master
|
|
|
|
|
%doc %{_mandir}/man7/%{name}.7*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}.1*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-cp.1*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-key.1*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-master.1*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-run.1*
|
|
|
|
|
%{_bindir}/%{name}
|
|
|
|
|
%{_bindir}/%{name}-cp
|
|
|
|
|
%{_bindir}/%{name}-key
|
|
|
|
|
%{_bindir}/%{name}-master
|
|
|
|
|
%{_bindir}/%{name}-run
|
|
|
|
|
%{_unitdir}/%{name}-master.service
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/master
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/master.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/pki/master
|
|
|
|
|
|
|
|
|
|
%files minion
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%doc %{_mandir}/man1/salt-call.1*
|
|
|
|
|
%doc %{_mandir}/man1/salt-minion.1*
|
|
|
|
|
%doc %{_mandir}/man1/salt-proxy.1*
|
|
|
|
|
%{_bindir}/salt-minion
|
|
|
|
|
%{_bindir}/salt-call
|
|
|
|
|
%{_bindir}/salt-proxy
|
|
|
|
|
%{_unitdir}/salt-minion.service
|
|
|
|
|
%{_unitdir}/salt-proxy@.service
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/minion
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/proxy
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/minion.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/pki/minion
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-call.1*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-minion.1*
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-proxy.1*
|
|
|
|
|
%{_bindir}/%{name}-minion
|
|
|
|
|
%{_bindir}/%{name}-call
|
|
|
|
|
%{_bindir}/%{name}-proxy
|
|
|
|
|
%{_unitdir}/%{name}-minion.service
|
|
|
|
|
%{_unitdir}/%{name}-proxy@.service
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/minion
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/proxy
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/minion.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/pki/minion
|
|
|
|
|
|
|
|
|
|
%files syndic
|
|
|
|
|
%doc %{_mandir}/man1/salt-syndic.1*
|
|
|
|
|
%{_bindir}/salt-syndic
|
|
|
|
|
%{_unitdir}/salt-syndic.service
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-syndic.1*
|
|
|
|
|
%{_bindir}/%{name}-syndic
|
|
|
|
|
%{_unitdir}/%{name}-syndic.service
|
|
|
|
|
|
|
|
|
|
%files api
|
|
|
|
|
%defattr(-,root,root)
|
|
|
|
|
%doc %{_mandir}/man1/salt-api.1*
|
|
|
|
|
%{_bindir}/salt-api
|
|
|
|
|
%{_unitdir}/salt-api.service
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-api.1*
|
|
|
|
|
%{_bindir}/%{name}-api
|
|
|
|
|
%{_unitdir}/%{name}-api.service
|
|
|
|
|
|
|
|
|
|
%files cloud
|
|
|
|
|
%doc %{_mandir}/man1/salt-cloud.1*
|
|
|
|
|
%{_bindir}/salt-cloud
|
|
|
|
|
%{_sysconfdir}/salt/cloud.conf.d
|
|
|
|
|
%{_sysconfdir}/salt/cloud.deploy.d
|
|
|
|
|
%{_sysconfdir}/salt/cloud.maps.d
|
|
|
|
|
%{_sysconfdir}/salt/cloud.profiles.d
|
|
|
|
|
%{_sysconfdir}/salt/cloud.providers.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/cloud
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-cloud.1*
|
|
|
|
|
%{_bindir}/%{name}-cloud
|
|
|
|
|
%{_sysconfdir}/%{name}/cloud.conf.d
|
|
|
|
|
%{_sysconfdir}/%{name}/cloud.deploy.d
|
|
|
|
|
%{_sysconfdir}/%{name}/cloud.maps.d
|
|
|
|
|
%{_sysconfdir}/%{name}/cloud.profiles.d
|
|
|
|
|
%{_sysconfdir}/%{name}/cloud.providers.d
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/cloud
|
|
|
|
|
|
|
|
|
|
%files ssh
|
|
|
|
|
%doc %{_mandir}/man1/salt-ssh.1*
|
|
|
|
|
%{_bindir}/salt-ssh
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/salt/roster
|
|
|
|
|
%doc %{_mandir}/man1/%{name}-ssh.1*
|
|
|
|
|
%{_bindir}/%{name}-ssh
|
|
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/roster
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# assumes systemd for RHEL 7 & 8 & 9
|
|
|
|
|
%preun master
|
|
|
|
|
# RHEL 9 is giving warning msg if syndic is not installed, supress it
|
|
|
|
|
%systemd_preun salt-syndic.service > /dev/null 2>&1
|
|
|
|
|
%systemd_preun %{name}-syndic.service
|
|
|
|
|
|
|
|
|
|
%preun minion
|
|
|
|
|
%systemd_preun salt-minion.service
|
|
|
|
|
%systemd_preun %{name}-minion.service
|
|
|
|
|
|
|
|
|
|
%preun api
|
|
|
|
|
%systemd_preun salt-api.service
|
|
|
|
|
%systemd_preun %{name}-api.service
|
|
|
|
|
|
|
|
|
|
%post master
|
|
|
|
|
%systemd_post salt-master.service
|
|
|
|
|
if [ $1 -lt 2 ]; then
|
|
|
|
|
# install
|
|
|
|
|
# ensure hmac are up to date, master or minion, rest install one or the other
|
|
|
|
|
# key used is from openssl/crypto/fips/fips_standalone_hmac.c openssl 1.1.1k
|
|
|
|
|
if [ $(cat /etc/os-release | grep VERSION_ID | cut -d '=' -f 2 | sed 's/\"//g' | cut -d '.' -f 1) = "8" ]; then
|
|
|
|
|
/bin/openssl sha256 -r -hmac orboDeJITITejsirpADONivirpUkvarP /opt/saltstack/salt/run/libssl.so.1.1 | cut -d ' ' -f 1 > /opt/saltstack/salt/run/.libssl.so.1.1.hmac || :
|
|
|
|
|
/bin/openssl sha256 -r -hmac orboDeJITITejsirpADONivirpUkvarP /opt/saltstack/salt/run/libcrypto.so.1.1 | cut -d ' ' -f 1 > /opt/saltstack/salt/run/.libcrypto.so.1.1.hmac || :
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
%systemd_post %{name}-master.service
|
|
|
|
|
|
|
|
|
|
%post syndic
|
|
|
|
|
%systemd_post salt-syndic.service
|
|
|
|
|
%systemd_post %{name}-syndic.service
|
|
|
|
|
|
|
|
|
|
%post minion
|
|
|
|
|
%systemd_post salt-minion.service
|
|
|
|
|
if [ $1 -lt 2 ]; then
|
|
|
|
|
# install
|
|
|
|
|
# ensure hmac are up to date, master or minion, rest install one or the other
|
|
|
|
|
# key used is from openssl/crypto/fips/fips_standalone_hmac.c openssl 1.1.1k
|
|
|
|
|
if [ $(cat /etc/os-release | grep VERSION_ID | cut -d '=' -f 2 | sed 's/\"//g' | cut -d '.' -f 1) = "8" ]; then
|
|
|
|
|
/bin/openssl sha256 -r -hmac orboDeJITITejsirpADONivirpUkvarP /opt/saltstack/salt/run/libssl.so.1.1 | cut -d ' ' -f 1 > /opt/saltstack/salt/run/.libssl.so.1.1.hmac || :
|
|
|
|
|
/bin/openssl sha256 -r -hmac orboDeJITITejsirpADONivirpUkvarP /opt/saltstack/salt/run/libcrypto.so.1.1 | cut -d ' ' -f 1 > /opt/saltstack/salt/run/.libcrypto.so.1.1.hmac || :
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
%systemd_post %{name}-minion.service
|
|
|
|
|
|
|
|
|
|
%post api
|
|
|
|
|
%systemd_post salt-api.service
|
|
|
|
|
%systemd_post %{name}-api.service
|
|
|
|
|
|
|
|
|
|
%postun master
|
|
|
|
|
%systemd_postun_with_restart salt-master.service
|
|
|
|
|
if [ $1 -eq 0 ]; then
|
|
|
|
|
if [ $(cat /etc/os-release | grep VERSION_ID | cut -d '=' -f 2 | sed 's/\"//g' | cut -d '.' -f 1) = "8" ]; then
|
|
|
|
|
if [ -z "$(rpm -qi salt-minion | grep Name | grep salt-minion)" ]; then
|
|
|
|
|
# uninstall and no minion running
|
|
|
|
|
/bin/rm -f /opt/saltstack/salt/run/.libssl.so.1.1.hmac || :
|
|
|
|
|
/bin/rm -f /opt/saltstack/salt/run/.libcrypto.so.1.1.hmac || :
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
%systemd_postun_with_restart %{name}-master.service
|
|
|
|
|
|
|
|
|
|
%postun syndic
|
|
|
|
|
%systemd_postun_with_restart salt-syndic.service
|
|
|
|
|
%systemd_postun_with_restart %{name}-syndic.service
|
|
|
|
|
|
|
|
|
|
%postun minion
|
|
|
|
|
%systemd_postun_with_restart salt-minion.service
|
|
|
|
|
if [ $1 -eq 0 ]; then
|
|
|
|
|
if [ $(cat /etc/os-release | grep VERSION_ID | cut -d '=' -f 2 | sed 's/\"//g' | cut -d '.' -f 1) = "8" ]; then
|
|
|
|
|
if [ -z "$(rpm -qi salt-master | grep Name | grep salt-master)" ]; then
|
|
|
|
|
# uninstall and no master running
|
|
|
|
|
/bin/rm -f /opt/saltstack/salt/run/.libssl.so.1.1.hmac || :
|
|
|
|
|
/bin/rm -f /opt/saltstack/salt/run/.libcrypto.so.1.1.hmac || :
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
fi
|
|
|
|
|
%systemd_postun_with_restart %{name}-minion.service
|
|
|
|
|
|
|
|
|
|
%postun api
|
|
|
|
|
%systemd_postun_with_restart salt-api.service
|
|
|
|
|
%systemd_postun_with_restart %{name}-api.service
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Tue Apr 25 2023 Sergey Cherevko <s.cherevko@msvsphere.ru> - 3005.1-4
|
|
|
|
|
- Rebuilt for MSVSphere 9.1
|
|
|
|
|
* Tue Apr 25 2023 Sergey Cherevko <s.cherevko@msvsphere.ru> - 3005.1-4.inferit
|
|
|
|
|
- Added MSVSphere support
|
|
|
|
|
- Rebuild for MSVSphere
|
|
|
|
|
|
|
|
|
|
* Tue Nov 01 2022 SaltStack Packaging Team <packaging@saltstack.com> - 3005-2
|
|
|
|
|
- Generate HMAC files post-install in case FIPS mode used only if libraries exist
|