More work on systemd support.
This commit is contained in:
parent
a088f95a31
commit
c24970cc3b
13
xrdp-sesman.service
Normal file
13
xrdp-sesman.service
Normal file
@ -0,0 +1,13 @@
|
||||
[Unit]
|
||||
Description=xrdp session manager
|
||||
After=syslog.target network.target
|
||||
|
||||
[Service]
|
||||
Type=forking
|
||||
PIDFile=/var/run/xrdp-sesman.pid
|
||||
EnvironmentFile=/etc/sysconfig/xrdp
|
||||
ExecStart=/usr/sbin/xrdp-sesman $SESMAN_OPTIONS
|
||||
ExecStop=/usr/sbin/xrdp-sesman $SESMAN_OPTIONS --kill
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
14
xrdp.service
Normal file
14
xrdp.service
Normal file
@ -0,0 +1,14 @@
|
||||
[Unit]
|
||||
Description=xrdp daemon
|
||||
Requires=xrdp-sesman.service
|
||||
After=syslog.target network.target xrdp-sesman.service
|
||||
|
||||
[Service]
|
||||
Type=forking
|
||||
PIDFile=/var/run/xrdp.pid
|
||||
EnvironmentFile=/etc/sysconfig/xrdp
|
||||
ExecStart=/usr/sbin/xrdp $XRDP_OPTIONS
|
||||
ExecStop=/usr/sbin/xrdp $XRDP_OPTIONS --kill
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
29
xrdp.spec
29
xrdp.spec
@ -1,5 +1,3 @@
|
||||
%{!?_initddir: %global _initddir %{_sysconfdir}/rc.d/init.d}
|
||||
|
||||
Summary: Open source remote desktop protocol (RDP) server
|
||||
Name: xrdp
|
||||
Version: 0.6.0
|
||||
@ -13,9 +11,10 @@ Patch0: xrdp-pam-auth.patch
|
||||
Patch1: xrdp-use-xinitrc-in-startwm-sh.patch
|
||||
Patch2: xrdp-pam_session.patch
|
||||
|
||||
Source1: xrdp.init
|
||||
Source2: xrdp.sysconfig
|
||||
Source3: xrdp.logrotate
|
||||
Source1: xrdp.service
|
||||
Source2: xrdp-sesman.service
|
||||
Source3: xrdp.sysconfig
|
||||
Source4: xrdp.logrotate
|
||||
|
||||
BuildRequires: pam-devel
|
||||
BuildRequires: openssl-devel
|
||||
@ -80,14 +79,15 @@ find %{buildroot} -name '*.la' -exec rm {} \;
|
||||
#install sesman pam config /etc/pam.d/xrdp-sesman
|
||||
%{__install} -Dp -m 644 instfiles/pam.d/xrdp-sesman %{buildroot}%{_sysconfdir}/pam.d/xrdp-sesman
|
||||
|
||||
#installx xrdp initscript /etc/rc.d/init.d/xrdp
|
||||
%{__install} -Dp -m 755 %{SOURCE1} %{buildroot}%{_initddir}/xrdp
|
||||
#installx xrdp systemd units
|
||||
%{__install} -Dp -m 644 %{SOURCE1} %{buildroot}/lib/systemd/system/xrdp.service
|
||||
%{__install} -Dp -m 644 %{SOURCE2} %{buildroot}/lib/systemd/system/xrdp-sesman.service
|
||||
|
||||
#install xrdp sysconfig /etc/sysconfig/xrdp
|
||||
%{__install} -Dp -m 644 %{SOURCE2} %{buildroot}%{_sysconfdir}/sysconfig/xrdp
|
||||
%{__install} -Dp -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/sysconfig/xrdp
|
||||
|
||||
#install logrotate /etc/logrotate.d/xrdp
|
||||
%{__install} -Dp -m 644 %{SOURCE3} %{buildroot}%{_sysconfdir}/logrotate.d/xrdp
|
||||
%{__install} -Dp -m 644 %{SOURCE4} %{buildroot}%{_sysconfdir}/logrotate.d/xrdp
|
||||
|
||||
#install log file /var/log/xrdp-sesman.log
|
||||
%{__mkdir} -p %{buildroot}%{_localstatedir}/log/
|
||||
@ -118,7 +118,7 @@ fi
|
||||
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
|
||||
if [ $1 -ge 1 ] ; then
|
||||
# Package upgrade, not uninstall
|
||||
/bin/systemctl try-restart apache-httpd.service >/dev/null 2>&1 || :
|
||||
/bin/systemctl try-restart xrdp.service >/dev/null 2>&1 || :
|
||||
fi
|
||||
|
||||
%triggerun -- xrdp < 0.6.0-1
|
||||
@ -142,14 +142,12 @@ fi
|
||||
%config(noreplace) %{_sysconfdir}/pam.d/xrdp-sesman
|
||||
%config(noreplace) %{_sysconfdir}/logrotate.d/xrdp
|
||||
%config(noreplace) %{_sysconfdir}/sysconfig/xrdp
|
||||
%{_initddir}/xrdp
|
||||
%{_sysconfdir}/xrdp/*.sh
|
||||
%{_sysconfdir}/xrdp/km*.ini
|
||||
%{_bindir}/xrdp-genkeymap
|
||||
%{_bindir}/xrdp-sesadmin
|
||||
%{_bindir}/xrdp-keygen
|
||||
%{_bindir}/xrdp-sesrun
|
||||
%{_bindir}/xrdp-dis
|
||||
%{_bindir}/xrdp-sestest
|
||||
%{_sbindir}/xrdp-chansrv
|
||||
%{_sbindir}/xrdp
|
||||
@ -179,9 +177,16 @@ fi
|
||||
%attr(0600,root,root) %verify(not size md5 mtime) %{_sysconfdir}/xrdp/rsakeys.ini
|
||||
|
||||
%changelog
|
||||
* Fri May 25 2012 Bojan Smojver <itamar@ispbrasil.com.br> - 0.6.0-0.1
|
||||
- more work on systemd support
|
||||
- remove xrdp-dis for now, current HEAD is broken (explicit rpaths)
|
||||
|
||||
* Wed May 23 2012 Itamar Reis Peixoto <itamar@ispbrasil.com.br> - 0.6.0-0.1
|
||||
- include patch's from Bojan Smojver bz#821569 , bz#611669
|
||||
|
||||
* Sat Feb 04 2012 Itamar Reis Peixoto <itamar@ispbrasil.com.br> - 0.5.0-0.16
|
||||
- add support for systemd
|
||||
|
||||
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.0-0.15
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user