Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
GitLab Cloud Native CI/CD with Rancher
Search
Shingo.Kitayama
May 30, 2019
Technology
5
640
GitLab Cloud Native CI/CD with Rancher
「Rancher Meetup Tokyo #19(CIについて語ろう会)」で利用した資料です。
https://rancherjp.connpass.com/event/129147/
Shingo.Kitayama
May 30, 2019
Tweet
Share
More Decks by Shingo.Kitayama
See All by Shingo.Kitayama
Introduction Konveyor AI - 2025
shkitayama
0
69
Why we expect the Microservices
shkitayama
2
500
Why run OpenShift on Google Cloud
shkitayama
1
350
Container Replatform 101
shkitayama
4
1.8k
Red Hat OpenShift Platform Plus - Red Hat Summit Connect 2022
shkitayama
0
780
NVIDIA AI Enterprise for Red Hat OpenShift
shkitayama
0
990
Kubernetes CICD Pipelines Book
shkitayama
2
2.1k
Shipwright Overview
shkitayama
0
1.9k
CloudNative CICD in OpenShift Commons Japan
shkitayama
5
18k
Other Decks in Technology
See All in Technology
M&Aで拡大し続けるGENDAのデータ活用を促すためのDatabricks権限管理 / AEON TECH HUB #22
genda
0
310
業務の煩悩を祓うAI活用術108選 / AI 108 Usages
smartbank
9
19k
AI駆動開発ライフサイクル(AI-DLC)の始め方
ryansbcho79
0
290
Claude Codeを使った情報整理術
knishioka
16
11k
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
3.5k
20251203_AIxIoTビジネス共創ラボ_第4回勉強会_BP山崎.pdf
iotcomjpadmin
0
170
マーケットプレイス版Oracle WebCenter Content For OCI
oracle4engineer
PRO
5
1.5k
小さく、早く、可能性を多産する。生成AIプロジェクト / prAIrie-dog
visional_engineering_and_design
0
300
2025-12-27 Claude CodeでPRレビュー対応を効率化する@機械学習社会実装勉強会第54回
nakamasato
4
1.4k
Introduction to Bill One Development Engineer
sansan33
PRO
0
340
モノタロウ x クリエーションラインで実現する チームトポロジーにおける プラットフォームチーム・ ストリームアラインドチームの 効果的なコラボレーション
creationline
0
210
202512_AIoT.pdf
iotcomjpadmin
0
180
Featured
See All Featured
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
22k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
40
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
48
9.8k
The #1 spot is gone: here's how to win anyway
tamaranovitovic
1
880
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
280
How To Stay Up To Date on Web Technology
chriscoyier
791
250k
Code Reviewing Like a Champion
maltzj
527
40k
A Tale of Four Properties
chriscoyier
162
23k
New Earth Scene 8
popppiees
0
1.3k
Into the Great Unknown - MozCon
thekraken
40
2.2k
Building Adaptive Systems
keathley
44
2.9k
Chasing Engaging Ingredients in Design
codingconduct
0
93
Transcript
GitLab Cloud Native CI/CD with Rancher Rancher Meetup Tokyo #19
GitLab.JP
2 Introductions Red Hat K.K.
3 Kubernetes実践ガイド 7/12発売予定 (あくまで予定ですからねっ! 「Kubernetes実践ガイド」 Kubernetesの話はしますが、主にクラウ ドネイティブ is なに?って話の本です。 ※400ページくらい
・Helmの展開 ・Operatorの活用 ・SpinnakerのCDパイプライン ・Clairのコンテナスキャニング ・Istioのサービスメッシュ などなど
Agenda GitLab Cloud Native CI/CD with Rancher 4 What’s GitLab
GitLab Deployment through Rancher GitLab CI/CD on Kubernetes Summary
5 What’s GitLab
6 Traditional DevOps Toolchainのステージごとに異なるミドルウェアを連携している Continuous Integration Continuous Deployment Plan Create
Verify Package Release Configure Monitor
7 Complete DevOps DevOps Toolchain for Complete DevOps Continuous Integration
Continuous Deployment Plan Create Verify Package Release Configure Monitor Complete DevOps
8 GitLab Main Features Target features [参照] https://about.gitlab.com/features/
9 GitLab Deployment thr Rancher
10 Rancher Catalog Catalog Configuration Library Rancher LabsがカスタマイズしたChartを使用する Helm Chart
Helm公式のChartを使用するHelm Stable、Helm Incubator
11 Helm Stable Catalog GitLab Catalog GitLab CE オープンソース版であり、プロプライ エタリなコードを含んでない
GitLab EEの機能を使用可能にするためには、ライセンスを購 入する必要があります。 もしもライセンスがないGitLab EEを使 用している場合は、MITライセンスの機能だけを使用する GitLab EE GitLab EEはGitLab CEと共通のコ アを利用して、追加的な機能を提供 しています。これはプロプライエタリ なライセンスのもと配布されます
12 Helm Stable Catalog GitLab Catalog GitLab CE オープンソース版であり、プロプライ エタリなコードを含んでない
GitLab EEの機能を使用可能にするためには、ライセンスを購 入する必要があります。 もしもライセンスがないGitLab EEを使 用している場合は、MITライセンスの機能だけを使用する GitLab EE GitLab EEはGitLab CEと共通のコ アを利用して、追加的な機能を提供 しています。これはプロプライエタリ なライセンスのもと配布されます HelmのStableが ステーブルだったことなんて 稀だよね? (GitLabうごかねぇ…)
13 Helm Stable Catalog gitlab-ce そろそろ公式Helm Chart 変えたほうがいいよね
14 公式の公式のHelm Chartを利用する GitLab Helm Chart
15 GitLab Architecture was Monolith GitLab自体のコンポーネントが複雑化 Gitaly GitLab-Shell nginx GitLab-
Workhouse GitLab-Rails (unicorn) redis sidekiq PostgreSQL http/https git nfs nfs nfs ・ユーザーから要求された タスクのスケジューリング ・静的コンテンツの配信 ・タスク情報の保持 ・ログインセッションの保持 タスクの実行 タスクの依頼 タスクの依頼 ユーザー情報の 問い合わせ タスク情報 の取得 GitLab
16 GitLab.com is also planning to Cloud Native Monolith to
Microservice https://about.gitlab.com/handbook/engineering/infrastructure/production-architecture/
17 GitLab Cloud Native Helm Chart Need Some Answer Sheet
for Deployment
18 GitLab Cloud Native Helm Chart Deployed on Rancher
19 GitLab CI/CD on k8s
GitLab Instance GitLab CI/CD Architecture On Kubernetes Executor 20 GitLab
CI/CD GitLab Repository GitLab Project .gitlab-ci.yml Developers GitLab Runner Executors - SSH - Shell - Parallels - VirtualBox - Docker - Docker Machine - Kubernetes Kubernetes Cluster NAMESPACE: ci-${CI_COMMIT_REF_SLUG} GitLab Job Pod - build-xxxxx - svc-xxxxx Job実行用のPodは、Jobが完了次第(成功しても失敗 しても)動的に削除される。そのため、Job実行のPodと 実際にデプロイするサービスPodは異なる。 → デプロイ作業はJobとして実行しなければいけない。 ※Auto DevOps機能を利用しない場合 継続的インテグレーションサービス
GitLab CI/CD Script Sample in .gitlab-ci.yml 21 stages: - build
- test - deploy job 1: stage: build script: make build dependencies job 2: stage: build script: make build artifacts job 3: stage: test script: make test job 4: stage: deploy script: make deploy Build Stage Test Stage Deploy Stage
GitLab Instance GitLab CI/CD Architecture On Kubernetes Executor 22 GitLab
CI/CD GitLab Repository GitLab Project .gitlab-ci.yml Developers GitLab Runner Kubernetes Cluster NAMESPACE: project-name GitLab Job Pod gitlab-managed-apps Helm Tiller Nginx Ingress Prometheus Master Branch Topic Branch Default: GitLab 1 Project = Kubernetes 1 Cluster Env: review/xxxxx Env: production master topic (リリース版) (開発版)
Installing managed applications gitlab-managed-apps 23 GitLab Instance 23 GitLab Runner
Kubernetes Cluster NAMESPACE: project-name GitLab Job Pod gitlab-managed-apps Helm Tiller Nginx Ingress Prometheus Master Branch Topic Branch Env: review/xxxxx Env: production
Installing managed applications 動的にデプロイ可能なApplicationリスト 24 Application GitLab version Description Helm
Chart Helm Tiller 10.2+ 他のアプリケーションをインストールために必要。クラスタ内の専用ポッドにTillerがインストールされ、安全な 環境でhelm CLIを実行。 n/a Ingress 10.2+ アプリケーションのロードバランシング、SSL処理などを提供。これは、アプリケーションのWebプロキシとして 機能し、Auto DevOpsでの独自のWebアプリケーションを展開。 stable/nginx- ingress Cert Manager 11.6+ 証明書の発行を支援するネイティブKubernetes証明書管理コントローラ。Let‘s Encryptによって証明書 が発行され、証明書が有効で最新であることが動的に確認される。 stable/cert- manager Prometheus 10.4+ 導入されたアプリケーションを監視。レビュー用のアプリケーションに対してもPrometheusで監視。 stable/prometh eus GitLab Runner 10.6+ CIジョブを実行し、その結果をGitLabに送り返すプロセス。アプリケーションを介してGitLab Runnerをイン ストールすると、デフォルトで特権モードで実行される。(*セキュリティ的に注意) runner/gitlab- runner JupyterHub 11.0+ プロジェクトチーム全体のJupyter Notebookを管理するためのマルチユーザサービス。 NurtchのRubixライ ブラリで構築された、すぐに使えるDevOps Runbookもご覧いただけます。 (*OAuth2経由でGitLabサー バーのユーザーに認証が有効) jupyter/jupyterh ub Knative 11.5+ サーバレスワークロードを作成、展開、および管理するためのプラットフォームを提供。これは、Knativeによっ てホストされているすべてのプログラムに外部IPアドレスを提供するためにIstioとともに使用されます。 アプリ ケーションが公開されるワイルドカードドメイン(DNS設定)が必要。 knative/knative
Kubernetes Integrations Add Existing Cluster 25
Kubernetes Integrations New Cluster on GKE 26 Googleアカウントにサインインすれば、動的にクGKEクラスターを作成してくれる。
GitLab Instance Auto DevOps Application Access Nginx Ingress for applications
27 27 GitLab Runner Kubernetes Cluster NAMESPACE: project-name GitLab Job Pod gitlab-managed-apps Helm Tiller Nginx Ingress Prometheus Master Branch Topic Branch Env: review/xxxxx Env: production master topic (リリース版) (開発版) Developers DNS Record *.example.com 3600 A 1.2.3.4 http://project.example.com http://review-project-5td1uj.example.com Monitoring 動的にURL生成
Using multiple Kubernetes clusters Deploy different environments to different Kubernetes
clusters 28 異なる環境を異なるKubernetesクラスタに展開することが可能 GitLab Instance Kubernetes Cluster for Production NAMESPACE: project-name gitlab-managed-apps Nginx Ingress Prometheus Master Branch Topic Branch Env: review/xxxxx Env: production master (リリース版) Developers http://project.example.com Monitoring Kubernetes Cluster for Review NAMESPACE: project-name gitlab-managed-apps Nginx Ingress Prometheus http://review-project-5td1uj.review.example.com
29 Summary
Summary GitLab CI/CD Pipeline GitLab supports Kubernetes worlds 30 CI/CD
Pipelines Kubernetes Cluster Container Applications GitLabのビジョン エンタープライズの開発チームが、Toolchainを維持する時間を短縮し、 ソフトウェア開発に時間を費す環境を提供すること。
[Ad.1] GitLab Meetup Tokyo #17 GitLab Contribute 2019 recap 31
日時 2019/06/06(木) 19:00 2019年5月に開催されるGitLab Contribute 2019のレポートをMeetup Tokyo #17として開催します。