Skip to content

Commit

Permalink
Use only sysusers.d and remove tmpfiles.d
Browse files Browse the repository at this point in the history
  • Loading branch information
Ricardo F committed Jul 14, 2024
1 parent 2c997bb commit 0d61af5
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 23 deletions.
3 changes: 1 addition & 2 deletions CHANGELOG
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
tuptime (5.2.4) unstable; urgency=low

* Move files from /lib to /usr/lib in DEB package
* Replace adduser with sysusers in DEB package
* Using tmpfiles.d to set DB dir in DEB package
* Replace adduser with sysusers.d in DEB package
* Update documentation
* Minnor code refactoring

Expand Down
3 changes: 1 addition & 2 deletions debian/changelog
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
tuptime (5.2.4) unstable; urgency=low

* Move files from /lib to /usr/lib in DEB package
* Replace adduser with sysusers in DEB package
* Using tmpfiles.d to set DB dir in DEB package
* Replace adduser with sysusers.d in DEB package
* Update documentation
* Minnor code refactoring

Expand Down
2 changes: 1 addition & 1 deletion debian/tuptime.install
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
src/systemd/tuptime.service usr/lib/systemd/system/
src/systemd/tuptime-sync.service usr/lib/systemd/system/
src/systemd/tuptime-sync.timer usr/lib/systemd/system/
src/systemd/tuptime-tmpfiles.conf usr/lib/tmpfiles.d/
src/systemd/sysusers.d/tuptime.conf usr/lib/sysusers.d/
src/init.d/debian/tuptime etc/init.d/
src/tuptime usr/bin/
5 changes: 0 additions & 5 deletions debian/tuptime.sysusers

This file was deleted.

6 changes: 6 additions & 0 deletions src/systemd/sysusers.d/tuptime.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
u _tuptime - "Tuptime execution user" /var/lib/tuptime

# Note:
# systemd-sysusers doesn't create home directories. Use in combination with
# StateDirectory=tuptime under [Service] in tuptime.service unit.
# https://lists.freedesktop.org/archives/systemd-devel/2018-February/040348.html
12 changes: 0 additions & 12 deletions src/systemd/tuptime.sysusers

This file was deleted.

2 changes: 1 addition & 1 deletion tuptime-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ echo ' [OK]'
echo "+ Creating Tuptime execution user '_tuptime'"
if systemd-sysusers --version > /dev/null 2>&1; then
echo " ...using systemd-sysusers"
install -m 644 "${F_TMP1}"/src/systemd/tuptime.sysusers /usr/lib/sysusers.d/tuptime.conf
install -m 644 "${F_TMP1}"/src/systemd/sysusers.d/tuptime.conf /usr/lib/sysusers.d/
((SELX)) && restorecon -vF /usr/lib/sysusers.d/tuptime.conf
systemd-sysusers /usr/lib/sysusers.d/tuptime.conf
echo ' [OK]'
Expand Down

0 comments on commit 0d61af5

Please sign in to comment.