Disable jobset deletion

This is a good way to make Hydra hang. (E.g. we had a deletion of
nixos:gcc-7 running for > 12 hours and blocking UPDATE statements from
hydra-queue-runner.) Generally it's better to just disable/hide an old
jobset anyway.
This commit is contained in:
Eelco Dolstra 2018-03-13 14:01:49 +01:00
parent 02888105a8
commit 85524b2d0f
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE
2 changed files with 5 additions and 1 deletions

View file

@ -92,7 +92,9 @@ sub jobset_PUT {
sub jobset_DELETE {
my ($self, $c) = @_;
requireProjectOwner($c, $c->stash->{project});
#requireProjectOwner($c, $c->stash->{project});
requireAdmin($c);
if (length($c->stash->{project}->declfile)) {
error($c, "can't modify jobset of declarative project", 403);

View file

@ -51,7 +51,9 @@
<ul class="dropdown-menu">
[% UNLESS project.declfile %]
[% INCLUDE menuItem title="Edit configuration" icon="icon-edit" uri=c.uri_for(c.controller('Jobset').action_for('edit'), c.req.captures) %]
<!--
[% INCLUDE menuItem title="Delete this jobset" icon="icon-trash" uri="javascript:deleteJobset()" %]
-->
[% INCLUDE menuItem title="Clone this jobset" uri=c.uri_for(c.controller('Jobset').action_for('edit'), c.req.captures, { cloneJobset => 1 }) %]
[% END %]
[% INCLUDE menuItem title="Evaluate this jobset" uri="javascript:confirmEvaluateJobset()" %]