debian-mirror-gitlab/doc/ci/README.md

136 lines
7.8 KiB
Markdown
Raw Normal View History

2018-03-17 18:26:18 +05:30
---
comments: false
2018-11-08 19:23:39 +05:30
description: "Learn how to use GitLab CI/CD, the GitLab built-in Continuous Integration, Continuous Deployment, and Continuous Delivery toolset to build, test, and deploy your application."
2018-03-17 18:26:18 +05:30
---
# GitLab Continuous Integration (GitLab CI/CD)
2015-09-25 12:07:36 +05:30
2017-09-10 17:25:29 +05:30
![Pipeline graph](img/cicd_pipeline_infograph.png)
2017-08-17 22:00:37 +05:30
The benefits of Continuous Integration are huge when automation plays an
integral part of your workflow. GitLab comes with built-in Continuous
2018-03-17 18:26:18 +05:30
Integration, Continuous Deployment, and Continuous Delivery support
to build, test, and deploy your application.
2017-08-17 22:00:37 +05:30
Here's some info we've gathered to get you started.
## Getting started
2018-03-17 18:26:18 +05:30
The first steps towards your GitLab CI/CD journey.
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
- [Getting started with GitLab CI/CD](quick_start/README.md): understand how GitLab CI/CD works.
2018-11-08 19:23:39 +05:30
- [GitLab CI/CD configuration file: `.gitlab-ci.yml`](yaml/README.md) - Learn all about the ins and outs of `.gitlab-ci.yml`.
2018-03-17 18:26:18 +05:30
- [Pipelines and jobs](pipelines.md): configure your GitLab CI/CD pipelines to build, test, and deploy your application.
- Runners: The [GitLab Runner](https://docs.gitlab.com/runner/) is responsible by running the jobs in your CI/CD pipeline. On GitLab.com, Shared Runners are enabled by default, so
you don't need to set up anything to start to use them with GitLab CI/CD.
### Introduction to GitLab CI/CD
- Article (2016-08-05): [Continuous Integration, Delivery, and Deployment with GitLab - Intro to CI/CD](https://about.gitlab.com/2016/08/05/continuous-integration-delivery-and-deployment-with-gitlab/)
- Article (2015-12-14): [Getting started with GitLab and GitLab CI - Intro to CI](https://about.gitlab.com/2015/12/14/getting-started-with-gitlab-and-gitlab-ci/)
- Article (2017-07-13): [Making CI Easier with GitLab](https://about.gitlab.com/2017/07/13/making-ci-easier-with-gitlab/)
- Article (2017-05-22): [Fast and Natural Continuous Integration with GitLab CI](https://about.gitlab.com/2017/05/22/fast-and-natural-continuous-integration-with-gitlab-ci/)
2017-08-17 22:00:37 +05:30
- **Videos:**
2018-03-17 18:26:18 +05:30
- Demo (Streamed live on Jul 17, 2017): [GitLab CI/CD Deep Dive](https://youtu.be/pBe4t1CD8Fc?t=195)
- Demo (March, 2017): [How to get started using CI/CD with GitLab](https://about.gitlab.com/2017/03/13/ci-cd-demo/)
- Webcast (April, 2016): [Getting started with CI in GitLab](https://about.gitlab.com/2016/04/20/webcast-recording-and-slides-introduction-to-ci-in-gitlab/)
2017-08-17 22:00:37 +05:30
- **Third-party videos:**
- [Intégration continue avec GitLab (September, 2016)](https://www.youtube.com/watch?v=URcMBXjIr24&t=13s)
- [GitLab CI for Minecraft Plugins (July, 2016)](https://www.youtube.com/watch?v=Z4pcI9F8yf8)
2018-03-17 18:26:18 +05:30
### Why GitLab CI/CD?
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
- Article (2016-10-17): [Why We Chose GitLab CI for our CI/CD Solution](https://about.gitlab.com/2016/10/17/gitlab-ci-oohlala/)
- Article (2016-07-22): [Building our web-app on GitLab CI: 5 reasons why Captain Train migrated from Jenkins to GitLab CI](https://about.gitlab.com/2016/07/22/building-our-web-app-on-gitlab-ci/)
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
## Exploring GitLab CI/CD
- [CI/CD Variables](variables/README.md) - Learn how to use variables defined in
2018-11-08 19:23:39 +05:30
your `.gitlab-ci.yml` or the ones defined in your project's settings
- [Where variables can be used](variables/where_variables_can_be_used.md) - A
deeper look on where and how the CI/CD variables can be used
2017-08-17 22:00:37 +05:30
- **The permissions model** - Learn about the access levels a user can have for
performing certain CI actions
- [User permissions](../user/permissions.md#gitlab-ci)
2018-03-17 18:26:18 +05:30
- [Job permissions](../user/permissions.md#job-permissions)
- [Configure a Runner, the application that runs your jobs](runners/README.md)
- Article (2016-03-01): [Setting up GitLab Runner For Continuous Integration](https://about.gitlab.com/2016/03/01/gitlab-runner-with-docker/)
- Article (2016-07-29): [GitLab CI: Run jobs sequentially, in parallel, or build a custom pipeline](https://about.gitlab.com/2016/07/29/the-basics-of-gitlab-ci/)
- Article (2016-08-26): [GitLab CI: Deployment & environments](https://about.gitlab.com/2016/08/26/ci-deployment-and-environments/)
- Article (2016-05-23): [Introduction to GitLab Container Registry](https://about.gitlab.com/2016/05/23/gitlab-container-registry/)
2017-08-17 22:00:37 +05:30
## Advanced use
2018-03-17 18:26:18 +05:30
Once you get familiar with the basics of GitLab CI/CD, it's time to dive in and
2017-08-17 22:00:37 +05:30
learn how to leverage its potential even more.
2018-03-17 18:26:18 +05:30
- [Environments and deployments](environments.md): Separate your jobs into
2017-08-17 22:00:37 +05:30
environments and use them for different purposes like testing, building and
deploying
- [Job artifacts](../user/project/pipelines/job_artifacts.md)
2018-04-04 21:44:52 +05:30
- [Caching dependencies](caching/index.md)
- [Git submodules](git_submodules.md) - How to run your CI jobs when Git
2017-08-17 22:00:37 +05:30
submodules are involved
2018-12-23 12:14:25 +05:30
- [Pipelines for merge requests](merge_request_pipelines/index.md)
2016-06-02 11:05:42 +05:30
- [Use SSH keys in your build environment](ssh_keys/README.md)
2017-08-17 22:00:37 +05:30
- [Trigger pipelines through the GitLab API](triggers/README.md)
- [Trigger pipelines on a schedule](../user/project/pipelines/schedules.md)
2018-03-17 18:26:18 +05:30
- [Kubernetes clusters](../user/project/clusters/index.md) - Integrate one or
more Kubernetes clusters to your project
2018-11-20 20:47:30 +05:30
- [Interactive web terminal](interactive_web_terminal/index.md) - Open an interactive
web terminal to debug the running jobs
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
## GitLab CI/CD for Docker
Leverage the power of Docker to run your CI pipelines.
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
- [Use Docker images with GitLab Runner](docker/using_docker_images.md)
- [Use CI to build Docker images](docker/using_docker_build.md)
- [CI services (linked Docker containers)](services/README.md)
- Article (2016-03-01): [Setting up GitLab Runner For Continuous Integration](https://about.gitlab.com/2016/03/01/gitlab-runner-with-docker/)
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
## Review Apps
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
- [Review Apps documentation](review_apps/index.md)
- Article (2016-11-22): [Introducing Review Apps](https://about.gitlab.com/2016/11/22/introducing-review-apps/)
- [Example project that shows how to use Review Apps](https://gitlab.com/gitlab-examples/review-apps-nginx/)
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
## Auto DevOps
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
- [Auto DevOps](../topics/autodevops/index.md): Auto DevOps automatically detects, builds, tests, deploys, and monitors your applications.
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
## GitLab CI for GitLab Pages
See the documentation on [GitLab Pages](../user/project/pages/index.md).
2017-08-17 22:00:37 +05:30
## Examples
2018-03-17 18:26:18 +05:30
Check the [GitLab CI/CD examples](examples/README.md) for a collection of tutorials and guides on setting up your CI/CD pipeline for various programming languages, frameworks,
and operating systems.
2017-08-17 22:00:37 +05:30
## Integrations
2018-03-17 18:26:18 +05:30
- Article (2016-06-09): [Continuous Delivery with GitLab and Convox](https://about.gitlab.com/2016/06/09/continuous-delivery-with-gitlab-and-convox/)
- Article (2016-05-05): [Getting Started with GitLab and Shippable Continuous Integration](https://about.gitlab.com/2016/05/05/getting-started-gitlab-and-shippable/)
- Article (2016-04-19): [GitLab Partners with DigitalOcean to make Continuous Integration faster, safer, and more affordable](https://about.gitlab.com/2016/04/19/gitlab-partners-with-digitalocean-to-make-continuous-integration-faster-safer-and-more-affordable/)
## Special configuration (GitLab admin)
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
As a GitLab administrator, you can change the default behavior of GitLab CI/CD in
your whole GitLab instance as well as in each project.
2017-08-17 22:00:37 +05:30
2018-03-17 18:26:18 +05:30
- [Continuous Integration admin settings](../administration/index.md#continuous-integration-settings)
- **Project specific:**
- [Pipelines settings](../user/project/pipelines/settings.md)
- [Learn how to enable or disable GitLab CI](enable_or_disable_ci.md)
- **Affecting the whole GitLab instance:**
- [Continuous Integration admin settings](../user/admin_area/settings/continuous_integration.md)
2017-08-17 22:00:37 +05:30
## Breaking changes
- [CI variables renaming for GitLab 9.0](variables/README.md#9-0-renaming) Read about the
deprecated CI variables and what you should use for GitLab 9.0+.
- [New CI job permissions model](../user/project/new_ci_build_permissions_model.md)
Read about what changed in GitLab 8.12 and how that affects your jobs.
There's a new way to access your Git submodules and LFS objects in jobs.