Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:deadpoint
lsc
lsc.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File lsc.spec of Package lsc
# # spec file for package lsc-core # # Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. # Copyright (c) 2009 - 2012 LSC Project # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # %define lsc_logdir %{_localstatedir}/log/lsc %define lsc_libdir %{_prefix}/lib/lsc %define lsc_user lsc %define lsc_group lsc %define nagios_dir /usr/lib/nagios # only needed for < 1310 %{!?_tmpfilesdir:%global _tmpfilesdir /usr/lib/tmpfiles.d} %{?!_initddir:%define _initddir %_initrddir} Name: lsc Version: 2.1.3 Release: 0 Summary: LDAP Synchronization Connector License: BSD-2-Clause Group: Applications/System Url: http://lsc-project.org Source: http://tools.lsc-project.org/attachments/download/746/%{name}-core-%{version}-dist.tar.gz Requires: java Requires: jpackage-utils Requires: cron # soft requirements to package doesn't own any dirs BuildRequires: nagios BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: noarch Provides: ldap-synchronization-connector %if 0%{?suse_version} >= 1210 BuildRequires: systemd %{?systemd_requires} %define has_systemd 1 %endif PreReq: %fillup_prereq PreReq: %insserv_prereq %description Ldap Synchronization Connector synchronize data from any data source including databases, LDAP directories or files by reading, transforming and comparing these data between the source and the target referentials. These connectors can then be used to continuously synchronize a data source to a directory, for a one shot import or just to compare differences by outputting CSV or LDIF format reports. LSC offers a powerful transformation engine, based on a scripting language, to easily manipulate data on the fly. Various identity management functions are included for directory-specific compatibility — most notably Active Directory (changing passwords, account status, last logon, etc ...). %package -n monitoring-plugins-lsc Summary: Check LSC Group: System/Monitoring Requires: lsc Requires: nagios %description -n monitoring-plugins-lsc These plugins check LSC task status and trough log file status. %prep %setup -q -n %{name}-%{version} %build %install %if 0%{?suse_version} == 1110 export NO_BRP_CHECK_BYTECODE_VERSION=true %endif # Create directories mkdir -p %{buildroot}%{_bindir} mkdir -p %{buildroot}%{_sbindir} mkdir -p %{buildroot}%{lsc_libdir}/%{name} mkdir -p %{buildroot}%{_sysconfdir}/%{name} mkdir -p %{buildroot}%{_sysconfdir}/%{name}/sql-map-config.d mkdir -p %{buildroot}%{_sysconfdir}/cron.d mkdir -p %{buildroot}%{_sysconfdir}/init.d mkdir -p %{buildroot}%{_sysconfdir}/default mkdir -p %{buildroot}%{_datadir}/doc/lsc/bin mkdir -p %{buildroot}%{lsc_logdir} mkdir -p %{buildroot}%{_localstatedir}/lib/lsc/nagios mkdir -p %{buildroot}%{_mandir}/{man1,man5} mkdir -p %{buildroot}%{nagios_dir}/plugins # Copy files ## bin cp -a bin/lsc %{buildroot}%{_bindir} cp -a bin/lsc-agent %{buildroot}%{_bindir} cp -a bin/hsqldb %{buildroot}%{_bindir} ## config cp -a etc/logback.xml %{buildroot}%{_sysconfdir}/%{name} cp -a etc/lsc.xml-sample %{buildroot}%{_sysconfdir}/%{name}/lsc.xml cp -a etc/sql-map-config.xml-sample %{buildroot}%{_sysconfdir}/%{name}/sql-map-config.xml cp -a etc/sql-map-config.d/InetOrgPerson.xml-sample %{buildroot}%{_sysconfdir}/%{name}/sql-map-config.d/InetOrgPerson.xml ## lib cp -a lib/* %{buildroot}%{lsc_libdir}/%{name} ## cron cp -a etc/cron.d/lsc.cron %{buildroot}%{_sysconfdir}/cron.d/%{name} ## init sed -i 's/Default-Start: 2 3 4 5/Default-Start: 2 3 5/' etc/init.d/lsc cp -a etc/init.d/lsc %{buildroot}%{_initddir}/%{name} cp -a etc/default/lsc %{buildroot}%{_sysconfdir}/default/%{name} %if %{has_systemd} ln -sf service %{buildroot}%{_sbindir}/rc%{name} %else ln -s %{_initrddir}/%{name} %{buildroot}%{_sbindir}/rc%{name} %endif ## nagios cp -a bin/check_lsc* %{buildroot}%{nagios_dir}/plugins cp doc/man/man1/* %{buildroot}%{_mandir}/man1 cp doc/man/man5/* %{buildroot}%{_mandir}/man5 # Reconfigure files ## logback sed -i 's:/tmp/lsc/log:%{lsc_logdir}:' %{buildroot}%{_sysconfdir}/%{name}/logback.xml ## cron sed -i 's: root : %{lsc_user} :' %{buildroot}%{_sysconfdir}/cron.d/%{name} sed -i 's:#LSC_BIN#:%{_bindir}/lsc:g' %{buildroot}%{_sysconfdir}/cron.d/%{name} sed -i 's:^30:#30:' %{buildroot}%{_sysconfdir}/cron.d/%{name} ## bin sed -i 's:^CFG_DIR.*:CFG_DIR="%{_sysconfdir}/lsc":' %{buildroot}%{_bindir}/lsc %{buildroot}%{_bindir}/lsc-agent %{buildroot}%{_bindir}/hsqldb sed -i 's:^LIB_DIR.*:LIB_DIR="%{lsc_libdir}/lsc":' %{buildroot}%{_bindir}/lsc %{buildroot}%{_bindir}/lsc-agent %{buildroot}%{_bindir}/hsqldb sed -i 's:^LOG_DIR.*:LOG_DIR="%{lsc_logdir}":' %{buildroot}%{_bindir}/lsc %{buildroot}%{_bindir}/lsc-agent %{buildroot}%{_bindir}/hsqldb sed -i 's:^VAR_DIR.*:VAR_DIR="%{_localstatedir}/lsc":' %{buildroot}%{_bindir}/hsqldb ## init sed -i 's:^LSC_BIN.*:LSC_BIN="%{_bindir}/lsc":' %{buildroot}%{_sysconfdir}/default/%{name} sed -i 's:^LSC_CFG_DIR.*:LSC_CFG_DIR="%{_sysconfdir}/lsc":' %{buildroot}%{_sysconfdir}/default/%{name} sed -i 's:^LSC_USER.*:LSC_USER="lsc":' %{buildroot}%{_sysconfdir}/default/%{name} sed -i 's:^LSC_GROUP.*:LSC_GROUP="lsc":' %{buildroot}%{_sysconfdir}/default/%{name} sed -i 's:^LSC_PID_FILE.*:LSC_PID_FILE="%{_localstatedir}/run/lsc.pid":' %{buildroot}%{_sysconfdir}/default/%{name} %pre groupadd -r %{lsc_group} >/dev/null 2>/dev/null || : useradd -r -g %{lsc_group} -d %{_localstatedir}/lib/%{name} -s /sbin/nologin \ -c "LSC User" %{lsc_user} 2>/dev/null ||: %preun %stop_on_removal %{name} %post %postun %restart_on_update %{name} %insserv_cleanup %files %defattr(-, root, root, 0755) %doc sample LICENSE.txt README.txt %config(noreplace) %{_sysconfdir}/%{name}/ %config(noreplace) %{_sysconfdir}/cron.d/%{name} %config(noreplace) %{_sysconfdir}/default/%{name} %{_bindir}/lsc %{_bindir}/lsc-agent %{_bindir}/hsqldb %{_sbindir}/rclsc %{_initddir}/lsc %{lsc_libdir} %attr(-,%{lsc_user},%{lsc_group}) %{lsc_logdir} %attr(-,%{lsc_user},%{lsc_group}) %{_localstatedir}/lib/%{name} %{_mandir}/man1/lsc* %{_mandir}/man5/lsc* %files -n monitoring-plugins-lsc %defattr(-, root, root, 0755) %{nagios_dir}/plugins/check_lsc* %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor