Revert "chore(cleanup): lxc-helpers does not need a global lock (#1047)" #1103
No reviewers
Labels
No labels
FreeBSD
Kind/Breaking
Kind/Bug
Kind/Chore
Kind/DependencyUpdate
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
Windows
linux-powerpc64le
linux-riscv64
linux-s390x
run-end-to-end-tests
run-forgejo-tests
run-multi-platform-tests
No milestone
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
forgejo/runner!1103
Loading…
Reference in a new issue
No description provided.
Delete branch "earl-warren/runner:wip-lock"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This reverts commit
996ac343ee.The lock is still needed to guard against the following scenario.
function build_template_act() {local name="$(template_act)"if lxc_exists_and_apt_not_old $name ; thenreturn 0filxc_build_template $(lxc_template_release) $namelxc_container_start $nameinstall_nodejs $namelxc_container_stop $name}lxc_build_template $(lxc_template_release) $name) - lxc-helpers now has transactions and they won't race against each otherwith a global lock only the first one will build and populate the act template. The other will then do nothing because it already exists.
The bug can trivially be reproduced with:
6a24559a4abadc918e60