smeserver-virtualbox/smeserver-virtualbox.spec-2023-03-22-06-01-51-632650500Z

112 lines
3.3 KiB
Plaintext
Raw Permalink Normal View History

%define name smeserver-virtualbox
%define version 5.2
%define release 4
%define rpmver 5.2
Summary: smserver rpm to install VirtualBox
Name: %{name}
Version: %{version}
Release: %{release}%{?dist}
Source: %{name}-%{version}.tar.gz
License: GNU GPL version 2
URL: http://mirror.de-labrusse.fr
Group: SMEserver/addon
BuildRoot: %{_tmppath}/%{name}-buildroot
Prefix: %{_prefix}
BuildArchitectures: noarch
BuildRequires: e-smith-devtools
Requires: e-smith-release >= 10.0
Requires: VirtualBox-5.2
Requires: kernel-devel
Requires: gcc
AutoReqProv: no
Patch0: smeserver-virtualbox-5.2-move_vbox_dir.patch
Patch1: smeserver-virtualbox-5.2-multiple_changes.patch
%description
smserver rpm to install VirtualBox-5.2
%changelog
* Fri Mar 10 2023 Trevor Batley <trevor@batley.id.au> 5.2-4.sme
- change log directory to /var/log/virtualbox and give correct permissions
- add password generation and storage for vboxweb runtime user (for use by phpvirtualbox)
- template /etc/default/virtualbox.conf
- add 50koozali.conf for vboxweb-service
- include migrate fragment for vbox user password
* Thu Oct 20 2022 Trevor Batley <trevor@batley.id.au> 5.2-3.sme
- remove storage of vbox password
* Wed Oct 19 2022 Trevor Batley <trevor@batley.id.au> 5.2-2.sme
- change vbox user to system user and change the home directory
* Tue Oct 11 2022 Trevor Batley <trevor@batley.id.au> 5.2-1.sme
- first import to sme10
- requires VirtualBox-5.2
- create vbox user and run vboxweb-service as vbox user
- create vbousers group and add admin,vbox as members
- add vbox & vboxusers as full sme accounts so tha they are in ldap (for ldap authentication)
- use systemd for vboxdrv
- move fix_vboxdrv_kerenel_module.sh script into /usr/lib/virtualbox and include as pre step in vboxdrv service start
* Fri Aug 07 2015 stephane de Labrusse <stephdl@de-labrusse.fr> 5.0.0-3
- vboxweb-service start now at S99
* Thu Aug 06 2015 stephane de labrusse <stephdl@de-labrusse.fr> 5.0.0-2
- require virtualbox-5.0
* Wed Mar 19 2014 stephane de labrusse <stephdl@de-labrusse.fr> 4.3.1-1
- added a script to verify if the vboxdrv module is compiled for the kernel used by the system
* Mon Dec 30 2013 JP Pialasse <tests@pialasse.com> 4.3.0-5
- changing naming of contrib for import into buildsys
* Tue Nov 05 2013 stephane de labrusse <stephdl@de-labrusse.fr> 4.3.0-4
- change name to match the virtualbox version
* Sat Oct 19 2013 stephane de labrusse <stephdl@de-labrusse.fr> 4.3.0-3
- Initial release
%prep
%setup
%patch0 -p1
%patch1 -p1
%build
perl createlinks
%install
rm -rf $RPM_BUILD_ROOT
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
rm -f %{name}-%{version}-filelist
mkdir -p $RPM_BUILD_ROOT/var/log/virtualbox
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
--dir /var/log/virtualbox 'attr(755,vbox,vboxusers)' \
--file /usr/lib/virtualbox/fix_vboxdrv_kernel_module.sh 'attr(755,root,root)' \
> %{name}-%{version}-filelist
echo "%doc COPYING" >> %{name}-%{version}-filelist
%clean
cd ..
rm -rf %{name}-%{version}
%pre
if ! id "vbox"
then
echo "Adding VBoxWeb runtime user (vbox)"
/usr/sbin/useradd -c "VBoxWeb runtime user" -m -N -s /bin/bash -g vboxusers vbox >/dev/null
fi
%preun
/sbin-e-smith/systemctl stop vboxweb-service
/sbin/e-smith/systemctl stop vboxdrv
%post
/sbin/e-smith/systemctl start vboxdrv
%postun
#uninstall
%files -f %{name}-%{version}-filelist
%defattr(-,root,root)