ci: limit stages to run in child pipelines

This commit is contained in:
2024-05-07 11:26:44 +02:00
parent bd01f6050a
commit 815921a6c9

View File

@@ -48,6 +48,8 @@ formatter:
- pip install -e .[dev] - pip install -e .[dev]
- isort --check --diff ./ - isort --check --diff ./
- black --check --diff --color ./ - black --check --diff --color ./
rules:
- if: $CI_PROJECT_PATH == "bec/ophyd_devices"
pylint: pylint:
stage: Formatter stage: Formatter
@@ -62,6 +64,8 @@ pylint:
paths: paths:
- ./pylint/ - ./pylint/
expire_in: 1 week expire_in: 1 week
rules:
- if: $CI_PROJECT_PATH == "bec/ophyd_devices"
pylint-check: pylint-check:
stage: Formatter stage: Formatter
@@ -93,10 +97,14 @@ pylint-check:
paths: paths:
- ./pylint/ - ./pylint/
expire_in: 1 week expire_in: 1 week
rules:
- if: $CI_PROJECT_PATH == "bec/ophyd_devices"
secret_detection: secret_detection:
before_script: before_script:
- "" - ""
rules:
- if: $CI_PROJECT_PATH == "bec/ophyd_devices"
pytest: pytest:
stage: test stage: test
@@ -145,6 +153,7 @@ trigger_bec:
OPHYD_DEVICES_BRANCH: $CI_COMMIT_REF_NAME OPHYD_DEVICES_BRANCH: $CI_COMMIT_REF_NAME
rules: rules:
- if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "main"' - if: '$CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "main"'
- if: $CI_PROJECT_PATH == "bec/ophyd_devices"
semver: semver:
stage: Deploy stage: Deploy
@@ -173,3 +182,4 @@ semver:
allow_failure: false allow_failure: false
rules: rules:
- if: '$CI_COMMIT_REF_NAME == "main"' - if: '$CI_COMMIT_REF_NAME == "main"'
- if: $CI_PROJECT_PATH == "bec/ophyd_devices"