License Cutoff for Bitbucket
Keep licensed Bitbucket users under a cap automatically.
Overview
A Bitbucket Data Center plugin that keeps the licensed group under a configured cap. On a schedule it removes the direct members with the lowest recent-activity rank.
When a removed user authenticates over HTTP or SSH, it swaps them with the lowest-ranked member before Bitbucket checks the license, so the same request goes through.
How it works
Instead of public screens, here is how it works.
- 1Cutoff job ranks recent activity
- 2Members over the cap are removed
- 3A removed user authenticates
- 4Swapped one-for-one and let through
Highlights
Safe defaults
Both cutoff and restore start in dry-run mode, with limits for removals per run, headroom, a grace period and a daily restore cap.
Invisible to users
Restore happens right after authentication and before the license check, aiming for the first attempt to succeed, and is designed for swaps as often as hourly.
No extra credentials
Group changes go through the Crowd directory already registered in Bitbucket, so no separate Crowd account or directory sync is needed.