0

I have the following YAML file that is dynamically created.

one:
    script:
        - !reference [.install_env, before_script]
        - python -c 'from integration_tests.staging_test_pipeline import run_algorithm; run_algorithm()'
        - !reference [.install_env, after_script]
two:
    script:
        - !reference [.install_env, before_script]
        - python -c 'from integration_tests.staging_test_pipeline import run_algorithm; run_algorithm()'
        - !reference [.install_env, after_script]

When the trigger tries to use this file I get this error:

Found errors in your .gitlab-ci.yml:

  • !reference [".install_env"
  • "before_script"] could not be found

Why is the yaml linter spliting the line?

I am able to use !reference [".install_env", "before_script"] in my .gitlab-ci.yml file just fine.

lr100
  • 648
  • 1
  • 9
  • 29

1 Answers1

0

Need to have

include:
    - local: <file that has .install_env>.yml
lr100
  • 648
  • 1
  • 9
  • 29