forked from pool/conman
Accepting request 500809 from home:jjolly:hpc
The conman service now starts up as the conman:conman user/group OBS-URL: https://build.opensuse.org/request/show/500809 OBS-URL: https://build.opensuse.org/package/show/network:cluster/conman?expand=0&rev=8
This commit is contained in:
parent
2fca354d9f
commit
01e90b5362
22
conman-suse-fix-expect-scripts.patch
Normal file
22
conman-suse-fix-expect-scripts.patch
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
Index: conman-0.2.7/lib/exec/ssh.exp
|
||||||
|
===================================================================
|
||||||
|
--- conman-0.2.7.orig/lib/exec/ssh.exp
|
||||||
|
+++ conman-0.2.7/lib/exec/ssh.exp
|
||||||
|
@@ -168,7 +168,7 @@ expect {
|
||||||
|
}
|
||||||
|
exp_continue -continue_timer
|
||||||
|
}
|
||||||
|
- -re "^$user@.* password: \$" {
|
||||||
|
+ -re "^.assword: \$" {
|
||||||
|
if {$authenticated == 0} {
|
||||||
|
send "$pswd\r"
|
||||||
|
incr authenticated
|
||||||
|
@@ -178,7 +178,7 @@ expect {
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
- -re "(:|#|%|\\\$) \$" {
|
||||||
|
+ -re "(:|#|%|>|\\\$) \$" {
|
||||||
|
;
|
||||||
|
}
|
||||||
|
-re "\[^\r]*\r+\n" {
|
@ -1,3 +1,13 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Sat Jun 3 01:50:39 UTC 2017 - jjolly@suse.com
|
||||||
|
|
||||||
|
- conman service configured to start as conman:conman user
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Jun 2 23:01:00 UTC 2017 - jjolly@suse.com
|
||||||
|
|
||||||
|
- Fixed ssh expect script for SUSE-specific output.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Mon May 8 10:51:34 UTC 2017 - eich@suse.com
|
Mon May 8 10:51:34 UTC 2017 - eich@suse.com
|
||||||
|
|
||||||
|
@ -4,6 +4,8 @@ After=network.target
|
|||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=forking
|
Type=forking
|
||||||
|
User=conman
|
||||||
|
Group=conman
|
||||||
ExecStart=/usr/sbin/conmand -c /etc/conman.conf
|
ExecStart=/usr/sbin/conmand -c /etc/conman.conf
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
|
36
conman.spec
36
conman.spec
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package conman
|
# spec file for package conman
|
||||||
#
|
#
|
||||||
# Copyright (c) 2016 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -13,6 +13,9 @@
|
|||||||
# published by the Open Source Initiative.
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||||
|
#
|
||||||
|
|
||||||
|
|
||||||
#
|
#
|
||||||
%if 0%{?suse_version} > 1140
|
%if 0%{?suse_version} > 1140
|
||||||
%define have_systemd 1
|
%define have_systemd 1
|
||||||
@ -21,14 +24,22 @@
|
|||||||
%endif
|
%endif
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
%if 0%{?have_systemd}
|
||||||
|
%define conman_g %name
|
||||||
|
%define conman_u %name
|
||||||
|
%else
|
||||||
|
%define conman_g root
|
||||||
|
%define conman_u daemon
|
||||||
|
%endif
|
||||||
|
|
||||||
Name: conman
|
Name: conman
|
||||||
Version: 0.2.7
|
Version: 0.2.7
|
||||||
Release: 0
|
Release: 0
|
||||||
|
|
||||||
Summary: The Console Manager
|
Summary: The Console Manager
|
||||||
Group: System/Console
|
|
||||||
License: GPL-3.0+
|
License: GPL-3.0+
|
||||||
URL: http://dun.github.io/conman/
|
Group: System/Console
|
||||||
|
Url: http://dun.github.io/conman/
|
||||||
|
|
||||||
Requires: expect
|
Requires: expect
|
||||||
Requires: logrotate
|
Requires: logrotate
|
||||||
@ -40,8 +51,17 @@ BuildRequires: freeipmi-devel
|
|||||||
Source0: https://github.com/dun/conman/releases/download/%{name}-%{version}/%{name}-%{version}.tar.bz2
|
Source0: https://github.com/dun/conman/releases/download/%{name}-%{version}/%{name}-%{version}.tar.bz2
|
||||||
%if 0%{?have_systemd}
|
%if 0%{?have_systemd}
|
||||||
Source1: %{name}.service
|
Source1: %{name}.service
|
||||||
|
|
||||||
|
Provides: group(conman)
|
||||||
|
Provides: user(conman)
|
||||||
|
|
||||||
|
BuildRequires: systemd
|
||||||
|
BuildRequires: systemd-rpm-macros
|
||||||
|
%{?systemd_requires}
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
|
Patch1: conman-suse-fix-expect-scripts.patch
|
||||||
|
|
||||||
# 8/15/14 karl.w.schulz@intel.com - include prereq
|
# 8/15/14 karl.w.schulz@intel.com - include prereq
|
||||||
%if 0%{?sles_version} || 0%{?suse_version}
|
%if 0%{?sles_version} || 0%{?suse_version}
|
||||||
PreReq: %{fillup_prereq}
|
PreReq: %{fillup_prereq}
|
||||||
@ -64,6 +84,7 @@ Its features include:
|
|||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{name}-%{version}
|
%setup -q -n %{name}-%{version}
|
||||||
|
%patch1 -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%configure --with-tcp-wrappers \
|
%configure --with-tcp-wrappers \
|
||||||
@ -120,6 +141,11 @@ fi
|
|||||||
%if 0%{?have_systemd}
|
%if 0%{?have_systemd}
|
||||||
%service_add_pre conman.service
|
%service_add_pre conman.service
|
||||||
%endif
|
%endif
|
||||||
|
%define conman_home "%_localstatedir%_rundir/conman"
|
||||||
|
%define conman_descr "Connection Manager service"
|
||||||
|
getent group %conman_g >/dev/null || groupadd -r %conman_g
|
||||||
|
getent passwd %conman_u >/dev/null || useradd -r -g %conman_g -d %conman_home -s /bin/false -c %conman_descr %conman_u
|
||||||
|
exit 0
|
||||||
|
|
||||||
%preun
|
%preun
|
||||||
%if 0%{?have_systemd}
|
%if 0%{?have_systemd}
|
||||||
@ -151,7 +177,7 @@ fi
|
|||||||
%doc NEWS
|
%doc NEWS
|
||||||
%doc README
|
%doc README
|
||||||
%doc THANKS
|
%doc THANKS
|
||||||
%config(noreplace) %{_sysconfdir}/conman.conf
|
%config(noreplace) %attr(-,%conman_u,%conman_g) %{_sysconfdir}/conman.conf
|
||||||
%config(noreplace) %{_sysconfdir}/logrotate.d/conman
|
%config(noreplace) %{_sysconfdir}/logrotate.d/conman
|
||||||
%{_localstatedir}/adm/fillup-templates/sysconfig.conman
|
%{_localstatedir}/adm/fillup-templates/sysconfig.conman
|
||||||
%{_bindir}/*
|
%{_bindir}/*
|
||||||
@ -163,3 +189,5 @@ fi
|
|||||||
%{_sysconfdir}/init.d/*
|
%{_sysconfdir}/init.d/*
|
||||||
%endif
|
%endif
|
||||||
%{_mandir}/*/*
|
%{_mandir}/*/*
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
Loading…
Reference in New Issue
Block a user