GitLab CI/CD Examples
GitLab CI/CD Examples
该页面包含指向各种示例的链接,这些示例可以帮助您了解如何针对特定用例实现GitLab CI / CD .
示例有几种形式. 作为以下内容的集合:
- 在 GitLab 中维护的
.gitlab-ci.yml
模板文件 ,用于许多常见的框架和编程语言. - 具有各种语言示例项目的存储库. 您可以分叉并根据自己的需要进行调整. 项目包括多项目管道的演示以及在 NGINX 服务的静态站点上使用Review Apps .
- 下面列出了示例和其他资源 .
CI/CD examples
下表列出了本节中包含分步教程的示例.
Contributing examples
欢迎捐款! 您可以通过发送合并请求和该语言的指南来帮助您最喜欢的编程语言用户和 GitLab.
CI/CD templates
使用.gitlab-ci.yml
模板开始使用 GitLab CI / CD 和您喜欢的编程语言或框架.
在用户界面中创建gitlab-ci.yml
文件时,可以选择以下模板之一:
- Android (
Android.gitlab-ci.yml
) - Android with fastlane (
Android-Fastlane.gitlab-ci.yml
) - Bash (
Bash.gitlab-ci.yml
) - C++ (
C++.gitlab-ci.yml
) - Chef (
Chef.gitlab-ci.yml
) - Clojure (
Clojure.gitlab-ci.yml
) - Composer
Composer.gitlab-ci.yml
- Crystal (
Crystal.gitlab-ci.yml
) - Django (
Django.gitlab-ci.yml
) - Docker (
Docker.gitlab-ci.yml
) - dotNET (
dotNET.gitlab-ci.yml
) - dotNET Core (
dotNET-Core.yml
) - Elixir (
Elixir.gitlab-ci.yml
) - goLang (
Go.gitlab-ci.yml
) - Gradle (
Gradle.gitlab-ci.yml
) - Grails (
Grails.gitlab-ci.yml
) - iOS with fastlane (
iOS-Fastlane.gitlab-ci.yml
) - Julia (
Julia.gitlab-ci.yml
) - Laravel (
Laravel.gitlab-ci.yml
) - LaTeX (
LaTeX.gitlab-ci.yml
) - Maven (
Maven.gitlab-ci.yml
) - Mono (
Mono.gitlab-ci.yml
) - NPM (
npm.gitlab-ci.yml
) - Node.js (
Nodejs.gitlab-ci.yml
) - OpenShift (
OpenShift.gitlab-ci.yml
) - Packer (
Packer.gitlab-ci.yml
) - PHP (
PHP.gitlab-ci.yml
) - Python (
Python.gitlab-ci.yml
) - Ruby (
Ruby.gitlab-ci.yml
) - Rust (
Rust.gitlab-ci.yml
) - Scala (
Scala.gitlab-ci.yml
) - Swift (
Swift.gitlab-ci.yml
) - Terraform (
Terraform.gitlab-ci.yml
)
如果编程语言或框架模板不在此列表中,则可以提供一种. 要创建模板,请向https://gitlab.com/gitlab-org/gitlab/tree/master/lib/gitlab/ci/templates提交合并请求.
Adding templates to your GitLab installation
您可以将自定义示例和模板添加到自我管理的 GitLab 实例. 您的 GitLab 管理员可以指定一个实例模板存储库 ,其中包含特定于您组织的示例和模板.
Other resources
本节提供更多资源,以帮助您熟悉 GitLab CI / CD 的各种用法. 请注意,较早的文章和视频可能无法反映最新的 GitLab 版本的状态.
CI/CD in the cloud
有关为基于云的环境设置 GitLab CI / CD 的示例,请参见:
- How to set up multi-account AWS SAM deployments with GitLab CI
- Automating Kubernetes Deployments with GitLab CI/CD
- How to autoscale continuous deployment with GitLab Runner on DigitalOcean
- How to create a CI/CD pipeline with Auto Deploy to Kubernetes using GitLab and Helm
- Demo - Deploying from GitLab to OpenShift Container Cluster
另请参阅以下视频概述:
Customer stories
有关使用 GitLab CI / CD 的一些客户体验,请参阅:
- How Verizon Connect reduced datacenter deploys from 30 days to under 8 hours with GitLab
- How Wag! cut their release process from 40 minutes to just 6
- How Jaguar Land Rover embraced CI to speed up their software lifecycle
Getting started
有关帮助您入门的一些示例,请参阅:
Implementing GitLab CI/CD
有关其他已实施 GitLab CI / CD 的示例,请参见:
- How to streamline interactions between multiple repositories with multi-project pipelines
- How we used GitLab CI to build GitLab faster
- Test all the things in GitLab CI with Docker by example
- A Craftsman looks at continuous integration
- Go tools and GitLab: How to do continuous integration like a boss
- GitBot – automating boring Git operations with CI
- How to use GitLab CI for Vue.js
- Video: GitLab CI/CD Deep Dive
- Dockerizing GitLab Review Apps
- Fast and natural continuous integration with GitLab CI
- Demo: CI/CD with GitLab in action
Migrating to GitLab from third-party CI tools
Integrating GitLab CI/CD with other systems
要查看如何将 GitLab CI / CD 与第三方系统集成,请参阅:
- Streamline and shorten error remediation with Sentry’s new GitLab integration
- How to simplify your smart home configuration with GitLab CI/CD
- Demo: GitLab + Jira + Jenkins
- Introducing Auto Breakfast from GitLab (sort of)
Mobile development
有关使用 GitLab CI / CD 进行移动应用程序开发的帮助,请参阅: