Skip to content

Commit

Permalink
Add spec for runsc
Browse files Browse the repository at this point in the history
  • Loading branch information
andyone committed Jun 6, 2024
1 parent a94dd5d commit 48a53e8
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions specs/runsc.spec
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Source1: https://storage.googleapis.com/gvisor/releases/release/%{version
Source10: https://storage.googleapis.com/gvisor/releases/release/%{version}/x86_64/runsc.sha512
Source11: https://storage.googleapis.com/gvisor/releases/release/%{version}/x86_64/containerd-shim-runsc-v1.sha512

Requires: docker-ce systemd kernel > 4.14.77

BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

Expand Down Expand Up @@ -46,6 +47,22 @@ install -pDm 755 %{SOURCE1} \
%clean
rm -rf %{buildroot}

%post
if [[ $1 -eq 1 ]] ; then
%{_bindir}/runsc install &>/dev/null || :
systemctl reload docker &>/dev/null || :
fi

%preun
if [[ $1 -eq 0 ]] ; then
systemctl reload docker &>/dev/null || :
fi

%postun
if [[ $1 -ge 1 ]] ; then
systemctl daemon-reload &>/dev/null || :
fi

################################################################################

%files
Expand Down

0 comments on commit 48a53e8

Please sign in to comment.