commit: 2563ac2933be85a58e7bc953e1f80ac0b04f173b Author: Sven Eden <yamakuzure <AT> gmx <DOT> net> AuthorDate: Wed May 24 07:29:35 2017 +0000 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> CommitDate: Sun Jun 4 17:02:35 2017 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2563ac29
sci-misc/boinc: Fix suspend/resume commands in the init script. Both suspend and resume do not work any more, at least with boinc-7.6.33. The reason is, that fetching the project URLs require password authentication. This commit adds the required steps to no longer get an authentication error when trying to suspend/resume boinc. Closes: https://github.com/gentoo/gentoo/pull/4732 Package-Manager: portage-2.3.6 ...boinc-7.2.44-r3.ebuild => boinc-7.2.44-r4.ebuild} | 0 ...boinc-7.4.52-r3.ebuild => boinc-7.4.52-r4.ebuild} | 0 ...boinc-7.6.33-r3.ebuild => boinc-7.6.33-r4.ebuild} | 0 sci-misc/boinc/files/boinc.init | 20 ++++++++++++-------- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/sci-misc/boinc/boinc-7.2.44-r3.ebuild b/sci-misc/boinc/boinc-7.2.44-r4.ebuild similarity index 100% rename from sci-misc/boinc/boinc-7.2.44-r3.ebuild rename to sci-misc/boinc/boinc-7.2.44-r4.ebuild diff --git a/sci-misc/boinc/boinc-7.4.52-r3.ebuild b/sci-misc/boinc/boinc-7.4.52-r4.ebuild similarity index 100% rename from sci-misc/boinc/boinc-7.4.52-r3.ebuild rename to sci-misc/boinc/boinc-7.4.52-r4.ebuild diff --git a/sci-misc/boinc/boinc-7.6.33-r3.ebuild b/sci-misc/boinc/boinc-7.6.33-r4.ebuild similarity index 100% rename from sci-misc/boinc/boinc-7.6.33-r3.ebuild rename to sci-misc/boinc/boinc-7.6.33-r4.ebuild diff --git a/sci-misc/boinc/files/boinc.init b/sci-misc/boinc/files/boinc.init index ceeeac87145..23450a6857c 100644 --- a/sci-misc/boinc/files/boinc.init +++ b/sci-misc/boinc/files/boinc.init @@ -184,15 +184,17 @@ resume() { env_check || return 1 local password="" - local master_urls=( \ - $("${BOINCCMD}" --get_project_status | \ - sed -n 's/\s*master URL: //p') \ - ) if need_passwd_arg; then password="--passwd \"$(cat "${RUNTIMEDIR}/gui_rpc_auth.cfg")\"" fi + local master_urls=( \ + $(cd "${RUNTIMEDIR}" ; \ + "${BOINCCMD}" ${password} --get_project_status | \ + sed -n 's/\s*master URL: //p') \ + ) + for url in "${master_urls[@]}"; do ebegin "Resuming $url" start-stop-daemon --user "${USER}:${GROUP}" --quiet \ @@ -207,15 +209,17 @@ suspend() { env_check || return 1 local password="" - local master_urls=( \ - $("${BOINCCMD}" --get_project_status | \ - sed -n 's/\s*master URL: //p') \ - ) if need_passwd_arg; then password="--passwd \"$(cat "${RUNTIMEDIR}/gui_rpc_auth.cfg")\"" fi + local master_urls=( \ + $(cd "${RUNTIMEDIR}" ; \ + "${BOINCCMD}" ${password} --get_project_status | \ + sed -n 's/\s*master URL: //p') \ + ) + for url in "${master_urls[@]}"; do ebegin "Suspending $url" start-stop-daemon --user "${USER}:${GROUP}" --quiet \