diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-11-28 12:10:10 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-11-28 12:10:10 +0000 |
commit | 22fd199237e247c36de5b982d444cedc194126e6 (patch) | |
tree | 1a5ad68a1dffdf37dfae0d1267bf3bcc04c292cb /doc/ci/runners/configure_runners.md | |
parent | 97b93f6d05b26e57a4d6a6d33a46aacb5f3235a6 (diff) | |
download | gitlab-ce-22fd199237e247c36de5b982d444cedc194126e6.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/ci/runners/configure_runners.md')
-rw-r--r-- | doc/ci/runners/configure_runners.md | 35 |
1 files changed, 6 insertions, 29 deletions
diff --git a/doc/ci/runners/configure_runners.md b/doc/ci/runners/configure_runners.md index c675f7204ec..3757410e355 100644 --- a/doc/ci/runners/configure_runners.md +++ b/doc/ci/runners/configure_runners.md @@ -306,7 +306,6 @@ globally or for individual jobs: - [`GIT_STRATEGY`](#git-strategy) - [`GIT_SUBMODULE_STRATEGY`](#git-submodule-strategy) -- [`GIT_SUBMODULE_PATHS`](#sync-or-exclude-specific-submodules-from-ci-jobs) - [`GIT_CHECKOUT`](#git-checkout) - [`GIT_CLEAN_FLAGS`](#git-clean-flags) - [`GIT_FETCH_EXTRA_FLAGS`](#git-fetch-extra-flags) @@ -524,6 +523,12 @@ The path syntax is the same as [`git submodule`](https://git-scm.com/docs/git-su GIT_SUBMODULE_PATHS: :(exclude)submoduleA :(exclude)submoduleB ``` +WARNING: +Git ignores nested paths. To ignore a nested submodule, exclude +the parent submodule and then manually clone it in the job's scripts. For example, + `git clone <repo> --recurse-submodules=':(exclude)nested-submodule'`. Make sure +to wrap the string in single quotes so the YAML can be parsed successfully. + ### Git submodule update flags > [Introduced](https://gitlab.com/gitlab-org/gitlab-runner/-/merge_requests/3192) in GitLab Runner 14.8. @@ -565,34 +570,6 @@ You should be aware of the implications for the security, stability, and reprodu your builds when using the `--remote` flag. In most cases, it is better to explicitly track submodule commits as designed, and update them using an auto-remediation/dependency bot. -### Sync or exclude specific submodules from CI jobs - -> [Introduced](https://gitlab.com/gitlab-org/gitlab-runner/-/issues/26495) in GitLab Runner 14.0. - -Some projects have a large number of submodules, and not all of them need to be -synced or updated in all CI jobs. Use the `GIT_SUBMODULE_PATHS` variable to control this behavior. -The path syntax is the same as [`git submodule`](https://git-scm.com/docs/git-submodule#Documentation/git-submodule.txt-ltpathgt82308203): - -- To sync and update specific paths: - - ```yaml - variables: - GIT_SUBMODULE_PATHS: 'submoduleA' - ``` - -- To exclude specific paths: - - ```yaml - variables: - GIT_SUBMODULE_PATHS: ':(exclude)submoduleA' - ``` - -WARNING: -Git ignores nested and multiple submodule paths. To ignore a nested submodule, exclude -the parent submodule and then manually clone it in the job's scripts. For example, - `git clone <repo> --recurse-submodules=':(exclude)nested-submodule'`. Make sure -to wrap the string in single quotes so the YAML can be parsed successfully. - ### Shallow cloning > Introduced in GitLab 8.9 as an experimental feature. |