Bug#993522: Re[2]: Bug#993522: buildbot-worker: Setting WORKER_OPTIONS to any non-empty value doesn't work
On Thu, 2 Sep 2021 16:27:27 +0200 Robin Jarry wrote: > 2021-09-02, Vadim Zeitlin: > > Package: buildbot-worker > > Version: 2.10.1-1 > > Severity: normal > > > > Dear Maintainer, > > > > Setting WORKER_OPTIONS in /etc/default/buildbot-worker to e.g. "--verbose" > > doesn't work because its value is used in a wrong place in the init.d > > script: it does > > > > "$WORKER_RUNNER $op ${WORKER_OPTIONS[$mi]} ${WORKER_BASEDIR[$mi]} > > > > when the correct syntax would be > > > > "$WORKER_RUNNER ${WORKER_OPTIONS[$mi]} $op ${WORKER_BASEDIR[$mi]} > > > > i.e. the options must come before the operation for buildbot-worker, not > > after it. > > Actually, this is only true for the --verbose option. Other options must > be passed after $op. Hello and thank you for your reply! Yes, indeed, sorry, I haven't realized this. Even the symmetric --quiet option does need to come after the operation. So this looks like poor buildbot command line UI and not a problem in the package itself, finally. > I see that you are using systemd. You should not use the init.d script > but the systemd unit template which is provided with the package. There > are examples in the man page to tweak the unit parameters: > > https://manpages.debian.org/bullseye/buildbot-worker/buildbot-worker.7.en.html#systemd > > In your case, you should override ExecStart= in a drop-in file. Oh, I see... it's really a comedy of errors and it looks like I did just about everything wrong because I did try using systemd, but when I saw that the buildbot-worker.service was masked, I've removed the file /lib/systemd/system/buildbot-worker.service to unmask it -- instead of using buildbot-worker@$NAME which is, as I now understand, the right thing to do. And while this allowed me to run "systemctl start buildbot-worker", in the meanwhile I had added "--verbose" to the defaults file to help me debugging the problem and this "--verbose" actually prevented things from working. > Also, it looks like this is a duplicate of bug #993521. Should I close > the first one? Yes, sorry about this one too, I've resent the bug report accidentally. I've tried to correct the problem by merging the 2 reports, but I'm not sure if I made things better or worse by doing it. In any case, it looks like both bug reports should be closed and the only thing to do might be to update the comment in the defaults file to say that the "--verbose" option can't be used there. Thanks again for your reply and explanations! VZ pgpdR0QSDOh5j.pgp Description: PGP signature
Bug#993522: buildbot-worker: Setting WORKER_OPTIONS to any non-empty value doesn't work
Hi Vadim, 2021-09-02, Vadim Zeitlin: > Package: buildbot-worker > Version: 2.10.1-1 > Severity: normal > > Dear Maintainer, > > Setting WORKER_OPTIONS in /etc/default/buildbot-worker to e.g. "--verbose" > doesn't work because its value is used in a wrong place in the init.d > script: it does > > "$WORKER_RUNNER $op ${WORKER_OPTIONS[$mi]} ${WORKER_BASEDIR[$mi]} > > when the correct syntax would be > > "$WORKER_RUNNER ${WORKER_OPTIONS[$mi]} $op ${WORKER_BASEDIR[$mi]} > > i.e. the options must come _before_ the operation for buildbot-worker, not > after it. Actually, this is only true for the --verbose option. Other options must be passed after $op. > -- System Information: > Debian Release: 11.0 > APT prefers stable-security > APT policy: (500, 'stable-security'), (500, 'stable') > Architecture: amd64 (x86_64) > > Kernel: Linux 5.10.0-8-amd64 (SMP w/12 CPU threads) > Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set > to C.UTF-8), LANGUAGE=en_US:en > Shell: /bin/sh linked to /bin/dash > Init: systemd (via /run/systemd/system) I see that you are using systemd. You should not use the init.d script but the systemd unit template which is provided with the package. There are examples in the man page to tweak the unit parameters: https://manpages.debian.org/bullseye/buildbot-worker/buildbot-worker.7.en.html#systemd In your case, you should override ExecStart= in a drop-in file. Also, it looks like this is a duplicate of bug #993521. Should I close the first one? -- Robin
Bug#993522: buildbot-worker: Setting WORKER_OPTIONS to any non-empty value doesn't work
Package: buildbot-worker Version: 2.10.1-1 Severity: normal Dear Maintainer, Setting WORKER_OPTIONS in /etc/default/buildbot-worker to e.g. "--verbose" doesn't work because its value is used in a wrong place in the init.d script: it does "$WORKER_RUNNER $op ${WORKER_OPTIONS[$mi]} ${WORKER_BASEDIR[$mi]} when the correct syntax would be "$WORKER_RUNNER ${WORKER_OPTIONS[$mi]} $op ${WORKER_BASEDIR[$mi]} i.e. the options must come _before_ the operation for buildbot-worker, not after it. -- System Information: Debian Release: 11.0 APT prefers stable-security APT policy: (500, 'stable-security'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 5.10.0-8-amd64 (SMP w/12 CPU threads) Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set to C.UTF-8), LANGUAGE=en_US:en Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages buildbot-worker depends on: ii lsb-base 11.1.0 ii passwd 1:4.8.1-1 ii python3 3.9.2-3 ii python3-future 0.18.2-5 ii python3-twisted 20.3.0-7 Versions of packages buildbot-worker recommends: ii git 1:2.30.2-1 buildbot-worker suggests no packages. -- Configuration Files: /etc/default/buildbot-worker changed [not included] -- no debconf information pgpU1yClnS8cy.pgp Description: PGP signature