Skip to content
Snippets Groups Projects
Commit 5f0fbbf6 authored by Andy Knight's avatar Andy Knight
Browse files

docs: add docs

parent d16284fa
No related branches found
No related tags found
No related merge requests found
Pipeline #21756180 passed
Loading
Loading
@@ -12,6 +12,18 @@ Looking to setup your workstation? Follow the documentation at: [`docs/developer
 
It is possible to use these templates without a `ref` tag when including them in your project, but this is not recommended as it may break your build process and make it non-repeatable. For example, if you revert a change, the templates will still reference the latest template which may no longer be compatible. For this reason, it's recommended you always use refs for your templates.
 
## Dockerhub image override
All templates that use an upstream image from [dockerhub](https://hub.docker.com/) (e.g anything without a hostname as part of the image path) by default are prefixed with `docker.io`. This can be changed (for example to use GitLab's [dependency proxy](https://docs.gitlab.com/ee/user/packages/dependency_proxy/) or [GCR pull through cache](https://cloud.google.com/artifact-registry/docs/pull-cached-dockerhub-images)) when you include the templates by providing an [input](https://docs.gitlab.com/ee/ci/yaml/inputs.html) value for `docker_hub_host` like so (this example uses dependency proxy):
```yaml
- project: "gitlab-com/gl-infra/common-ci-tasks"
ref: v2.8.0
file: templates/standard.yml
inputs:
docker_hub_host: ${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}
```
## Templates
 
It is preferable to use templates over individual CI jobs as it reduces clutter, increases standardization and improves consistency across projects. Additionally, new functionality can be added to projects with only an upgrade to the `ref`.
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment