Upstream project .gitlab-ci.yml
image: node:10
stages:
- build
- build-child
cache:
paths:
- node_modules/
project-build:
stage: build
only:
- master
script:
- npm install
- npm run build
artifacts:
expire_in: 90 days
paths:
- ./dist
trigger-child-build:
stage: build-child
trigger:
project: ghanshyamgehlot/childTestProject
strategy: depend
Downstream project .gitlab-ci.yml
image: node:10
stages:
- build-this-project
cache:
paths:
- ./node_modules/
build-this:
stage: build-this-project
needs:
- project: ghanshyamgehlot/testProject
job: project-build
ref: master
artifacts: true
only:
- master
script:
- npm install
- npm run build
As soon as the downstream project pipeline is triggered by the upstream project, the following error appears in the downstream project pipeline even though the artifact has been successfully created by the upstream project:
This job depends on other jobs with expired/erased artifacts: