I have a .gitlab-ci.yaml
with the extends
directive, which works on the gitlab-ci, but I cannot test it with gitlab-runner exec
, it looks like the extends
is ignored by gitlab-runner
.
I have two files, like:
# .2extend.yml
.job2extend:
image: some/docker/img
stage: test
script:
- echo do things with "${myvar}"
and
# .gitlab-ci.yml
include:
- project: 'project/to/extend'
ref: master
file: '.2extend.yml'
myjob:
extends: .job2extend
variables:
myvar: 'My Variable'
This is the error I'm having:
$ gitlab-runner exec docker myjob
Runtime platform arch=amd64 os=linux pid=29785 revision=45d9c1d6 version=12.4.0~beta.1935.g45d9c1d6
FATAL: missing 'script' for job
The job I am extending from, have both script
and image
directives.
I have come to this issue which has the same problem as I do.
So, there is workaround to do this while the issue is not solved?