dnd-it/action-lock
GitHub Action for distributed mutex locking using git refs. Acquire and release locks to serialize workflow jobs.
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Activelast commit Feb 20, 2026
- License
- None
Pinned Snippet
uses: dnd-it/action-lock@33c5cfe59a96e64f99e083e46bd1ee4ce416d468 # v0.1.0tags can be moved; commit SHAs can't. why a SHA?
Inputs
| name | description | required | default |
|---|---|---|---|
| action | Lock action: acquire or release | yes | — |
| lock_name | Name of the lock (used as the ref name under refs/locks/) | yes | — |
| timeout | Maximum time in seconds to wait for lock acquisition | no | 300 |
| poll_interval | Seconds between lock acquisition attempts | no | 10 |
| stale_threshold | Seconds after which a lock is considered stale and can be force-acquired. Set to 0 to disable. | no | 600 |
| fail_on_timeout | Fail the step if the lock cannot be acquired within timeout. Set to false to skip gracefully. | no | true |
| token | GitHub token with contents:write permission | yes | — |
Outputs
| name | description |
|---|---|
| acquired | Whether the lock was successfully acquired (true/false) |
| lock_ref | The full git ref used for the lock |