Skip to content
Snippets Groups Projects
Commit 11212772 authored by Rocky Automation's avatar Rocky Automation :tv:
Browse files

import imports/r9/amazon-ssm-agent-3.2.286.0-1.el9_1.cloud

parents
No related branches found
No related merge requests found
3be076e25de376e4cde8db6042626d3be294d7322222c2a0af2285fa31fcd0c1 SOURCES/3.2.286.0.tar.gz
%global major_version 3
%global minor_version 2
%global micro_version 286
%global nano_version 0
%ifarch x86_64
%global arch_dir linux_amd64
%global arch_build build-linux
%endif
%ifarch aarch64
%global arch_dir linux_arm64
%global arch_build build-arm64
%endif
%define debug_package %{nil}
Name: amazon-ssm-agent
Version: %{major_version}.%{minor_version}.%{micro_version}.%{nano_version}
Release: 1%{?dist}
Summary: Manage EC2 Instances using the SSM APIs
ExclusiveArch: x86_64 aarch64
License: ASL 2.0
URL: https://docs.aws.amazon.com/systems-manager/latest/userguide/what-is-systems-manager.html
Source0: https://github.com/aws/%{name}/archive/refs/tags/%{version}.tar.gz
BuildRequires: systemd
BuildRequires: go >= 1.15.12
BuildRequires: make
BuildRequires: go-srpm-macros
Requires: systemd
Requires(post): systemd
Requires(postun): systemd
Requires(preun): systemd
# This is a legacy thing for EL7. Will be changed to the EL8 kernel in
# two years.
Requires: kernel >= 3.10.0
%description
AWS System Manager (SSM) is an AWS service that you can use to view and control
your infrastructure in AWS. Using the Systems Manager console, you can view
operational data from multiple AWS services and automate operational tasks
across your AWS resources.
Systems Manager helps you maintain security and compliance by scanning your
managed nodes and reporting on (or taking corrective action on) any policy
violations it detects.
More information can be found at the systems manager documentation.
%prep
%setup -q
%build
sed -ie 's|const[ \s ]*Version.*|const Version = "%{version}"|g' agent/version/version.go
make %{arch_build}
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/amazon/ssm \
$RPM_BUILD_ROOT%{_bindir} \
$RPM_BUILD_ROOT%{_localstatedir}/lib/amazon/ssm \
$RPM_BUILD_ROOT%{_localstatedir}/log/amazon/ssm \
$RPM_BUILD_ROOT%{_unitdir}
cp \
bin/%{arch_dir}/{amazon-ssm-agent,ssm-agent-worker,ssm-document-worker,ssm-session-worker,ssm-session-logger,ssm-cli} \
$RPM_BUILD_ROOT%{_bindir}/${x}
cp packaging/linux/amazon-ssm-agent.service $RPM_BUILD_ROOT%{_unitdir}
cp amazon-ssm-agent.json.template $RPM_BUILD_ROOT%{_sysconfdir}/amazon/ssm/amazon-ssm-agent.json.template
cp seelog_unix.xml $RPM_BUILD_ROOT%{_sysconfdir}/amazon/ssm/seelog.xml.template
%preun
%systemd_preun %{name}.service
%post
%systemd_post %{name}.service
%postun
%systemd_postun_with_restart %{name}.service
%files
%defattr(-,root,root,-)
%doc README.md RELEASENOTES.md NOTICE.md
%license LICENSE
%{_unitdir}/amazon-ssm-agent.service
%{_sysconfdir}/amazon/ssm/amazon-ssm-agent.json.template
%{_sysconfdir}/amazon/ssm/seelog.xml.template
%{_bindir}/amazon-ssm-agent
%{_bindir}/ssm-agent-worker
%{_bindir}/ssm-document-worker
%{_bindir}/ssm-session-worker
%{_bindir}/ssm-session-logger
%{_bindir}/ssm-cli
%dir %{_localstatedir}/lib/amazon/ssm
%dir %ghost %{_localstatedir}/log/amazon/ssm
%changelog
* Fri Dec 09 2022 Louis Abel <tucklesepk@gmail.com> - 3.2.286.0-1
- Update to latest release
* Tue Jul 19 2022 Louis Abel <tucklesepk@gmail.com> - 3.1.1634.0-1
- Update to latest release
* Fri Mar 25 2022 Louis Abel <tucklesepk@gmail.com> - 3.1.1141.0-1
- Initial release of Amazon SSM for Rocky Extras
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment