zuul/zuul/model_api.py
James E. Blair 9b17dd730b Deprecate cleanup-run
This moves cleanup-run playbooks into the post-run phase to address
a security vulnerability.

To protect against cleanup playbooks being able to access the
resources of playbooks higher in the inheritance stack, we will now
only execute post (including cleanup) playbooks at the level we
reached when running pre-run playbooks.

The cleanup-run attribute is deprecated.  A new attribute to mark
individual post-run playbooks as "cleanup" playbooks is added, and
existing cleanup-run playbooks are treated thusly for backwards
compatibility.

A new deprecation warning is issued for users of cleanup-run.

Change-Id: I49245a4eecb931d8fe7f523805b6e4d7292c806b
2024-07-10 11:29:44 -07:00

18 lines
708 B
Python

# Copyright 2022 Acme Gating, LLC
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
# When making ZK schema changes, increment this and add a record to
# doc/source/developer/model-changelog.rst
MODEL_API = 30