This moves all existing `image/services/before_script/variables`
into `default:`. This allows us to easily add a default and
top-level entries. `default`: is keep backward compatible: to
be considered to be job if `default:script:` is specified. This
behavior should be removed.
All existing `image/services/before_script/variables` are properly
handled in root context.
This fix is a followup to !24098 which introduced a validation of the
`include:` keyword of a gitlab-ci configuration file when triggered
from /ci/lint API calls.
However, there was a test case missing: the case of a single string as
value. I have added a test case for that which shows that the code was
not validating it correctly.
This commit fixes that to allow all `include:` valid inputs.
This brings support for untrusted regexp for 'only:refs:' when
enabled via feature flag: alllow_unsafe_ruby_regexp.
This is by default disabled, and should not be used in production
In order to implement https://gitlab.com/gitlab-org/gitlab-ee/issues/10179
we need several modifications on the CI config file. We are
adding a new ports section in the default Image object.
Each of these ports will accept: number, protocol and name.
By default this new configuration will be only enabled in
the Web IDE config file.
Introduce `default:` configuration entry setting that makes it possible
to configure a default value of an entry, what overrides class-level
`def self.default` value.
This commit refactors only/except policies so that these policies could
be self-contained. This also adds some changes to YAML configuration
library to provide more context to default entry value fabrication
process.