注冊(cè) | 登錄讀書好,好讀書,讀好書!
讀書網(wǎng)-DuShu.com
當(dāng)前位置: 首頁出版圖書科學(xué)技術(shù)工業(yè)技術(shù)建筑科學(xué)建筑設(shè)計(jì)Kubernetes即學(xué)即用

Kubernetes即學(xué)即用

Kubernetes即學(xué)即用

定 價(jià):¥58.00

作 者: (美)凱爾西海托華,(美)布蘭登柏恩思,(美)喬貝達(dá)
出版社: 中國電力出版社
叢編項(xiàng):
標(biāo) 簽: 暫缺

ISBN: 9787519826192 出版時(shí)間: 2018-12-01 包裝:
開本: 頁數(shù): 字?jǐn)?shù):  

內(nèi)容簡(jiǎn)介

  本書作者一直在Google和其他公司從事Kubernetes方面的工作,為我們解釋了該系統(tǒng)如何融入分布式應(yīng)用程序的生命周期之中的。你將學(xué)習(xí)如何使用各種工具和API來實(shí)現(xiàn)可擴(kuò)展分布式系統(tǒng)管理的自動(dòng)化,無論該系統(tǒng)用于在線服務(wù)、機(jī)器學(xué)習(xí)應(yīng)用程序,還是Raspberry Pi計(jì)算機(jī)群集。本書的主要內(nèi)容有:探索Kubernetes所面臨的分布式系統(tǒng)挑戰(zhàn)。使用Docker等容器進(jìn)行容器化應(yīng)用開發(fā)。使用docker鏡像格式和容器運(yùn)行時(shí)在Kubernetes上創(chuàng)建和運(yùn)行容器。探索在生產(chǎn)中運(yùn)行應(yīng)用程序所必需的專門對(duì)象。在無需停機(jī)或無差錯(cuò)情況下可靠地推出新的軟件版本。舉例說明如何在Kubernetes中開發(fā)和部署真實(shí)應(yīng)用程序。

作者簡(jiǎn)介

  作者主要從事數(shù)據(jù)中心網(wǎng)絡(luò)解決方案的研發(fā)與部署,技術(shù)方向包括云計(jì)算、軟件定義網(wǎng)絡(luò)(SDN)、網(wǎng)絡(luò)安全等,是國內(nèi)較早從事 SDN 和網(wǎng)絡(luò)虛擬化相關(guān)技術(shù)的推廣者,同時(shí)也是 Docke開源社區(qū)的發(fā)起人之一。

圖書目錄

前言 .........................................................................................................................................1 第1章 概述 ...............................................................................................................................7 速度 ...........................................................................................................................................8 不變性的價(jià)值 ..................................................................................................................9 聲明式配置 .....................................................................................................................10 自我修復(fù)系統(tǒng) .................................................................................................................11 擴(kuò)展服務(wù)和團(tuán)隊(duì) .....................................................................................................................12 解耦 ..................................................................................................................................12 更易于擴(kuò)展的應(yīng)用程序和集群 ..................................................................................12 利用微服務(wù)擴(kuò)展開發(fā)團(tuán)隊(duì) ...........................................................................................13 一致性和可擴(kuò)展性的隔離 ...........................................................................................14 抽象基礎(chǔ)設(shè)施 ..........................................................................................................................16 效率 ..........................................................................................................................................17 小結(jié) ..........................................................................................................................................18 第2章 創(chuàng)建和運(yùn)行容器 ......................................................19 容器鏡像 ..................................................................................................................................20 Docker鏡像格式 ............................................................................................................21 使用Docker構(gòu)建應(yīng)用程序鏡像 ...........................................................................................23 Dockerfile ........................................................................................................................23 鏡像的安全性 .................................................................................................................24 優(yōu)化鏡像大小 .................................................................................................................24 將鏡像存儲(chǔ)到遠(yuǎn)程倉儲(chǔ) ........................................................................................................25 Docker容器運(yùn)行時(shí) .................................................................................................................26 通過Docker運(yùn)行容器 ....................................................................................................27 探索kuard應(yīng)用程序 ......................................................................................................27 限制資源使用 .................................................................................................................27 刪除鏡像 ..................................................................................................................................28 小結(jié) ..........................................................................................................................................29 第3章 部署Kubernetes群集 .............................................30 在公共云上安裝Kubernetes ...............................................................................................31 Google Container Service ...........................................................................................31 使用Azure Container Service安裝Kubernetes ......................................................31 在Amazon Web Services上安裝Kubernetes ...........................................................32 使用minikube在本地安裝Kubernetes .............................................................................33 在Raspberry Pi上運(yùn)行Kubernetes ....................................................................................34 Kubernetes客戶端 .................................................................................................................34 檢查群集狀態(tài) .................................................................................................................34 查看Kubernetes Worker節(jié)點(diǎn) ......................................................................................35 群集組件 ..................................................................................................................................38 Kubernetes代理 .............................................................................................................38 Kubernetes DNS .............................................................................................................38 Kubernetes UI .................................................................................................................39 小結(jié) .........................................................................................................................................40 第4章 常用kubectl命令 ....................................................41 命名空間 ..................................................................................................................................41 上下文 ......................................................................................................................................41 查看Kubernetes API對(duì)象 .....................................................................................................42 創(chuàng)建、更新和銷毀Kubernetes對(duì)象...................................................................................43 標(biāo)記和注釋對(duì)象 ....................................................................................................................44 調(diào)試命令 ..................................................................................................................................44 小結(jié) ..........................................................................................................................................45 第5章 pod ........................................................................46 Kubernetes中的pod ..............................................................................................................47 用pod思考 ...............................................................................................................................48 pod Manifest ...........................................................................................................................48 創(chuàng)建pod ...........................................................................................................................49 創(chuàng)建pod Manifest ..........................................................................................................50 運(yùn)行pod ...................................................................................................................................51 列出pod ...........................................................................................................................51 pod的詳細(xì)信息 .............................................................................................................52 刪除pod ...........................................................................................................................53 訪問pod ..................................................................................................................................54 使用端口轉(zhuǎn)發(fā) .................................................................................................................54 使用日志獲取更多信息 ...............................................................................................55 利用exec執(zhí)行容器中的命令 .......................................................................................55 在容器間復(fù)制文件 ........................................................................................................56 健康檢查 ..................................................................................................................................56 活性探針 .........................................................................................................................57 就緒探針 ..........................................................................................................................58 健康檢查的類型 .............................................................................................................59 資源管理 ..................................................................................................................................59 資源請(qǐng)求:所需資源下限 ...........................................................................................60 通過限額控制資源用量 ...............................................................................................62 利用卷實(shí)現(xiàn)數(shù)據(jù)持久化 ........................................................................................................63 通過pod使用存儲(chǔ)卷 .....................................................................................................63 pod使用卷的不同方式 .................................................................................................64 使用遠(yuǎn)程磁盤實(shí)現(xiàn)數(shù)據(jù)的持久性 ..............................................................................65 綜合討論 ..................................................................................................................................66 小結(jié) ..........................................................................................................................................67 第6章 標(biāo)簽和注釋 ............................................................68 標(biāo)簽 ..........................................................................................................................................68 應(yīng)用標(biāo)簽 ..........................................................................................................................70 修改標(biāo)簽 .........................................................................................................................71 標(biāo)簽選擇器 .....................................................................................................................72 API對(duì)象中的標(biāo)簽選擇器..............................................................................................74 注釋 ..........................................................................................................................................75 定義注釋 ..........................................................................................................................76 清理 ..........................................................................................................................................76 小結(jié) ..........................................................................................................................................77 第7章 服務(wù)發(fā)現(xiàn) ...............................................................78 什么是服務(wù)發(fā)現(xiàn)? .................................................................................................................78 Service對(duì)象 .............................................................................................................................79 提供DNS服務(wù) ..................................................................................................................80 就緒檢查 ..........................................................................................................................82 集群之外 ..................................................................................................................................83 云集成 ......................................................................................................................................85 高級(jí)細(xì)節(jié) .................................................................................................................................86 端點(diǎn) ..................................................................................................................................86 手動(dòng)服務(wù)發(fā)現(xiàn) .................................................................................................................88 kube-proxy與集群IP .....................................................................................................89 群集IP環(huán)境變量..............................................................................................................90 清除對(duì)象 ..................................................................................................................................91 小結(jié) ..........................................................................................................................................91 第8章 ReplicaSet .............................................................92 調(diào)和循環(huán) ..................................................................................................................................93 將pod和ReplicaSet關(guān)聯(lián)起來 ..............................................................................................94 采用現(xiàn)有容器 .................................................................................................................94 隔離容器 ..........................................................................................................................94 使用ReplicaSet進(jìn)行設(shè)計(jì) ......................................................................................................95 ReplicaSet的規(guī)范 ...................................................................................................................95 pod模板 ..........................................................................................................................96 標(biāo)簽 ..................................................................................................................................96 創(chuàng)建ReplicaSet ........................................................................................................................97 監(jiān)查ReplicaSet ........................................................................................................................97 從pod中查找ReplicaSet...............................................................................................98 查找ReplicaSet的pod集...............................................................................................98 擴(kuò)展ReplicaSet ........................................................................................................................99 使用kubectl Scale進(jìn)行命令式縮放 ...........................................................................99 使用kubectl apply進(jìn)行聲明式縮放 ....................................................................... 100 自動(dòng)調(diào)整ReplicaSet ................................................................................................... 101 刪除ReplicaSet ..................................................................................................................... 102 小結(jié) ....................................................................................................................................... 103 第9章 DaemonSet .......................................................... 104 DaemonSet調(diào)度器 ............................................................................................................. 105 創(chuàng)建DaemonSet .................................................................................................................. 105 將DaemonSet限制為特定節(jié)點(diǎn) ........................................................................................ 108 為節(jié)點(diǎn)添加標(biāo)簽 .......................................................................................................... 108 節(jié)點(diǎn)選擇器 .................................................................................................................. 109 更新DaemonSet .................................................................................................................. 110 通過刪除單個(gè)pod來更新DaemonSet ................................................................... 110 滾動(dòng)更新DaemonSet ................................................................................................. 111 刪除DaemonSet .................................................................................................................. 112 小結(jié) ....................................................................................................................................... 112 第10章 作業(yè) ................................................................... 113 Job對(duì)象 ................................................................................................................................. 113 作業(yè)模式 ............................................................................................................................... 114 一次性作業(yè) .................................................................................................................. 114 并行性 ........................................................................................................................... 120 工作隊(duì)列 ....................................................................................................................... 122 小結(jié) ....................................................................................................................................... 126 第11章 ConfigMap與Secret ........................................... 127 ConfigMap ............................................................................................................................ 127 創(chuàng)建ConfigMap ........................................................................................................... 128 ConfigMap的用法 ...................................................................................................... 129 Secret .................................................................................................................................... 132 創(chuàng)建Secret .................................................................................................................... 133 消費(fèi)secret .................................................................................................................... 134 私有Docker倉庫 ......................................................................................................... 136 命名約束 ............................................................................................................................... 137 管理ConfigMap和Secret ................................................................................................... 137 顯示 ............................................................................................................................... 138 創(chuàng)建 ............................................................................................................................... 138 更新 ............................................................................................................................... 139 小結(jié) ....................................................................................................................................... 141 第12章 Deployment ....................................................... 142 我們的個(gè)Deployment對(duì)象 ...................................................................................... 143 Deployment對(duì)象的運(yùn)行機(jī)制 .................................................................................. 143 創(chuàng)建Deployment對(duì)象 ........................................................................................................ 145 管理Deployment對(duì)象 ........................................................................................................ 146 更新Deployment對(duì)象 ........................................................................................................ 147 Deployment對(duì)象的縮放 ........................................................................................... 148 更新容器鏡像 .............................................................................................................. 148 更新的歷史記錄 .......................................................................................................... 150 部署策略 ............................................................................................................................... 153 Recreate策略 ............................................................................................................... 153 RollingUpdate策略..................................................................................................... 153 降低更新速度以確保服務(wù)的健康 ........................................................................... 157 刪除Deployment ................................................................................................................. 159 小結(jié) ....................................................................................................................................... 159 第13章 為Kubernetes集成存儲(chǔ)解決方案 ......................... 160 導(dǎo)入外部服務(wù) ....................................................................................................................... 161 沒有選擇器的服務(wù) .................................................................................................... 163 外部服務(wù)的局限性:健康檢查 ............................................................................... 165 運(yùn)行可靠的單例 .................................................................................................................. 165 運(yùn)行MySQL單例 .......................................................................................................... 165 動(dòng)態(tài)卷配置 .................................................................................................................. 169 帶有StatefulSet的Kubernetes-Native存儲(chǔ) .................................................................. 170 StatefulSet的特性 ....................................................................................................... 171 使用StatefulSet手動(dòng)部署備份式MongoDB ......................................................... 171 自動(dòng)創(chuàng)建MongoDB群集 ........................................................................................... 174 持久卷和有狀態(tài)集 ..................................................................................................... 177 后一件事:準(zhǔn)備就緒探針 .................................................................................... 178 小結(jié) ....................................................................................................................................... 179 第14章 部署實(shí)際應(yīng)用程序 ............................................... 180 Parse ...................................................................................................................................... 180 先決條件 ....................................................................................................................... 181 構(gòu)建parse-server ........................................................................................................ 181 部署parse-server ........................................................................................................ 182 測(cè)試Parse ...................................................................................................................... 183 Ghost ..................................................................................................................................... 183 配置Ghost..................................................................................................................... 183 Redis ...................................................................................................................................... 187 配置Redis ...................................................................................................................... 188 創(chuàng)建Redis服務(wù) ............................................................................................................. 190 部署Redis ...................................................................................................................... 190 測(cè)試Redis群集 ............................................................................................................. 192 小結(jié) ....................................................................................................................................... 193 附錄A 利用Raspberry Pi搭建Kubernetes群集 ...................................................................... 195

本目錄推薦

掃描二維碼
Copyright ? 讀書網(wǎng) m.ranfinancial.com 2005-2020, All Rights Reserved.
鄂ICP備15019699號(hào) 鄂公網(wǎng)安備 42010302001612號(hào)