Changes including the fix of #1038416

Francesco P. Lovergine frankie at debian.org
Thu Jun 22 08:53:19 BST 2023


Just to clarify and fix some ideas, I did a series of trials for upgrades and new installations of proftpd.
The devil is in details with systemd and I noticed some interesting issues:

- In bookworm apparently all worked fine at install time, because the daemon was
   activated correctly before the socket, for unknown reason. Maybe it is due 
   to ordering in running new services in systemd.
   All go to the hell at next reboot. That's justify us for this rough oversight :-)
   Read after me: always perform a reboot to understand if shit happens.

- Even in bullseye (goosh!) the proftpd was not stopped at remove time, that's because DH is
   strictly triggered by the way dh_installsystemd is called. At the time, the
   .service unit was enabled in postinst and that implies we needed to act as consequence 
   in prerm. The DH scripts do not help about that: remove/purge does not imply
   cleaning running services. Incidentally -4 was good about that, but now as for
   -5 the prerm needs some explicit actions.

That said, I would ask RMs for a p-u for 12.1 in order to correctly manage the
damn whole thing. 


>=====================================
>debian/proftpd-core.NEWS
>=====================================
>@@ -1,3 +1,16 @@
>+proftpd-dfsg (1.3.8+dfsg-5) unstable; urgency=medium
>+
>+    Starting from this version a new systemd unit file 'proftpd-run.service' has
>+    been introduced to allow switching between standalone and systemd (socket) mode.
>+    In order to switch mode, it possible to change ServerType from standalone to inetd
>+    in /etc/proftpd/proftpd.conf and run
>+        systemctl stop proftpd.service
>+        systemctl start proftpd.socket
>+    The only unit to be maintained enabled is proftpd-run.service, and disabling
>+    it would ensures to stop the ftp service at boot time.
>+
>+ -- Francesco Paolo Lovergine <frankie at debian.org>  Wed, 21 Jun 2023 15:21:32 +0200
>+
>=====================================
>debian/proftpd-core.proftpd-run.service
>=====================================
>@@ -0,0 +1,14 @@
>+[Unit]
>+Description=ProFTPD FTP Server in standalone/socket mode
>+Documentation=man:proftpd(8)
>+OnFailure=proftpd.socket
>+OnSuccess=proftpd.service
>+
>+[Service]
>+Type=oneshot
>+Environment=CONFIG_FILE=/etc/proftpd/proftpd.conf
>+EnvironmentFile=-/etc/default/proftpd
>+ExecStart=/usr/bin/grep -iqE '^[[:space:]]*ServerType[[:space:]]+standalone$' $CONFIG_FILE
>+
>+[Install]
>+WantedBy=multi-user.target
>
>
>=====================================
>debian/proftpd-substvars
>=====================================
>@@ -0,0 +1 @@
>+proftpd:Depends=proftpd-abi-1.3.8
>
>
>=====================================
>debian/rules
>=====================================
>@@ -93,8 +93,9 @@ override_dh_installinit:
> 	dh_installinit --name=$(NAME)
>
> override_dh_installsystemd:
>-	dh_installsystemd -p$(PACKAGE) --name=$(NAME) $(NAME).socket
>+	dh_installsystemd -p$(PACKAGE) --no-enable --no-start --name=$(NAME) $(NAME).socket
> 	dh_installsystemd -p$(PACKAGE) --name=$(NAME)@ $(NAME)@.service
>-	dh_installsystemd -p$(PACKAGE) --name=$(NAME) $(NAME).service
>+	dh_installsystemd -p$(PACKAGE) --no-enable --no-start --name=$(NAME) $(NAME).service
>+	dh_installsystemd -p$(PACKAGE) --name=$(NAME)-run $(NAME)-run.service
>
> .PHONY: debian/proftpd-substvars debian/control
>
>
>
>View it on GitLab: https://salsa.debian.org/debian-proftpd-team/proftpd/-/compare/6b07054b46ea55aea8ab31314b8aa2ea646e5ff0...899363f55512f41cc567133409553a8a4addb34c
>
>-- 
>View it on GitLab: https://salsa.debian.org/debian-proftpd-team/proftpd/-/compare/6b07054b46ea55aea8ab31314b8aa2ea646e5ff0...899363f55512f41cc567133409553a8a4addb34c
>You're receiving this email because of your account on salsa.debian.org.
>
>
>_______________________________________________
>Pkg-proftpd-maintainers mailing list
>Pkg-proftpd-maintainers at alioth-lists.debian.net
>https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-proftpd-maintainers
>

-- 
Francesco P. Lovergine



More information about the Pkg-proftpd-maintainers mailing list