
Consuela is a tool we use at inventid to prevent accidental merges. It works by checking tags of your Pull request. In case a PR has one of the mentioned tags, Consuela will drop a status to your PR to prevent merges.
Additionally, Consuela offers support for locking repositories entirely through the /merge-lock endpoint.
This puts an error status on all the open pull request, indicating an ongoing merge lock
The endpoints can be accessed using POST for setting the lock, and DELETE for releasing it.
Both endpoints require a repo query parameter to be set, and the lock creation optionally supports a message query param for indicating why the lock is in place.
One caveat of the current locking system is that it uses a global variable to store the current lock state. That means that if a lock is in place and Consuela is restarted, any changes to pull requests will not be updated with the lock status.


It works really simple:
default.json.example to default.jsonapplication/json, and leave the secret empty. As the hook, only select Pull Request.node server.js
class consuela {
file { '/opt/consuela.json':
ensure => present,
source => 'puppet:///modules/consuela/config.json',
mode => '0600',
notify => Docker::Run['consuela']
}
docker::image { 'rogierslag/consuela:latest': }
docker::run { 'consuela':
image => 'rogierslag/consuela',
volumes => ['/opt/consuela.json:/opt/consuela/config/default.json'],
ports => ["${ipaddress_eth0}:8543:8543"]
}
firewall { '200 allow gonzuela':
dport => ['8543'],
proto => 'tcp',
action => 'accept'
}
}
sudo docker run -d -v /opt/consuela.json:/opt/consuela/config/default.json -p <IP>:8543:8543 rogierslag/consuela
Content type
Image
Digest
sha256:851148f4d…
Size
377.7 MB
Last updated
over 2 years ago
docker pull rogierslag/consuela