Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix lsc-async unitfile and a bit more #289

Merged
merged 3 commits into from
Jun 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/install/debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ override_dh_testdir:
cp -f lib/systemd/system/lsc-sync.service debian/
cp -f lib/systemd/system/lsc-sync.timer debian/
cp -f lib/systemd/system/[email protected] debian/
cp -f lib/systemd/system/[email protected] debian/
cp -f etc/default/lsc-async debian/lsc-async.default
cp -f etc/default/lsc-sync debian/lsc-sync.default
dh_testdir
Expand All @@ -25,6 +26,7 @@ override_dh_installsystemd:
dh_installsystemd --no-start --no-enable --no-stop-on-upgrade --name=lsc-sync
dh_installsystemd --no-start --no-enable --no-stop-on-upgrade --name=lsc-sync@
dh_installsystemd --name=lsc-sync.timer
dh_installsystemd [email protected]


override_dh_install:
Expand Down
6 changes: 2 additions & 4 deletions src/install/etc/default/lsc-async
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@
#====================================================================

# JMX
LSC_JMXPORT="1099"
#LSC_JMXPORT="1099"

# JAVA
#JAVA_HOME=/usr/java/jdk/jre
#JAVA_HOME=/usr/lib/jvm/jre

LSC_CONFIG_DIR="/etc/lsc"
#LSC_SYNC_TASKS=""
LSC_ASYNC_TASKS="-a all"
#LSC_CLEAN_TASKS=""
LSC_EXTRA_ARGS=""
5 changes: 2 additions & 3 deletions src/install/etc/default/lsc-sync
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,12 @@
#====================================================================

# JMX
LSC_JMXPORT="1099"
#LSC_JMXPORT="1099"

# JAVA
#JAVA_HOME=/usr/java/jdk/jre
#JAVA_HOME=/usr/lib/jvm/jre

LSC_CONFIG_DIR="/etc/lsc"
LSC_SYNC_TASKS="-s all"
#LSC_ASYNC_TASKS=""
LSC_CLEAN_TASKS="-c all"
LSC_EXTRA_ARGS=""
2 changes: 1 addition & 1 deletion src/install/lib/systemd/system/lsc-async.service
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Description=LSC server
After=network.target

[Service]
Type=forking
Type=simple
User=lsc
Group=lsc
PIDFile=/var/run/lsc.pid
Expand Down
2 changes: 1 addition & 1 deletion src/install/lib/systemd/system/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Description=LSC server for specific instance %I
After=network.target

[Service]
Type=forking
Type=simple
User=lsc
Group=lsc
PIDFile=/var/run/lsc.pid
Expand Down
5 changes: 5 additions & 0 deletions src/install/lib/systemd/system/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[Unit]
Description=Periodically run LSC %I

[Timer]
OnCalendar= *:30:00
2 changes: 2 additions & 0 deletions src/install/lsc.spec
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ install -p -m 0644 lib/systemd/system/[email protected] %{buildroot}%{_unitdir}
install -p -m 0644 lib/systemd/system/lsc-sync.service %{buildroot}%{_unitdir}/
install -p -m 0644 lib/systemd/system/[email protected] %{buildroot}%{_unitdir}/
install -p -m 0644 lib/systemd/system/lsc-sync.timer %{buildroot}%{_unitdir}/
install -p -m 0644 lib/systemd/system/[email protected] %{buildroot}%{_unitdir}/
## man
cp -a doc/man/man1/* %{buildroot}%{_mandir}/man1/
cp -a doc/man/man5/* %{buildroot}%{_mandir}/man5/
Expand Down Expand Up @@ -171,6 +172,7 @@ getent passwd lsc > /dev/null 2>&1 || \
%{_unitdir}/lsc-sync.service
%{_unitdir}/[email protected]
%{_unitdir}/lsc-sync.timer
%{_unitdir}/[email protected]
%{_libdir}/lsc/
%attr(-,lsc,lsc) %{lsc_logdir}
%attr(-,lsc,lsc) %{_sharedstatedir}/lsc/
Expand Down
1 change: 1 addition & 0 deletions src/main/assembly/dist.xml
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@
<include>lsc-sync.service</include>
<include>[email protected]</include>
<include>lsc-sync.timer</include>
<include>[email protected]</include>
</includes>
<outputDirectory>lib/systemd/system</outputDirectory>
<fileMode>0644</fileMode>
Expand Down
Loading