<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                企業??AI智能體構建引擎,智能編排和調試,一鍵部署,支持知識庫和私有化部署方案 廣告
                # Jenkins GitHub 集成:安裝 Git 插件 > 原文: [https://www.guru99.com/jenkins-github-integration.html](https://www.guru99.com/jenkins-github-integration.html) 您已經從以前的 Guru99 教程中學到了 Jenkins 是什么以及如何將其安裝到 Windows 系統上。 假設您已完成這些基本步驟,我們現在將繼續進行插件管理。 Jenkins 具有出色的插件支持。 他們的網站上有成千上萬的第三方應用程序插件。 要了解 Jenkins 是否支持您所考慮的第三方應用程序,請在 [https://wiki.jenkins-ci.org/display/JENKINS/Plugins](https://wiki.jenkins-ci.org/display/JENKINS/Plugins) 中檢查其插件目錄。 ![](https://img.kancloud.cn/0c/b8/0cb81bf962bd08cdac40a7d082a6a82b_585x103.png) 在本教程中,您將學習: * [在 Jenkins 中安裝插件](#1) * [安裝 GIT 插件](#2) * [將 Jenkins 與 GitHub 集成](#3) ## 在 Jenkins 中安裝插件 Jenkins 提供了非常基本的設置,因此您將需要安裝必需的插件以啟用相應的第三方應用程序支持。 GitHub 是基于 Web 的代碼存儲庫,在 DevOps 中起著重要作用。 它為從事同一代碼/項目的多個開發人員提供了一個通用平臺,以上傳和檢索更新的代碼,從而促進了持續集成。 Jenkins 需要安裝 GitHub 插件才能從 GitHub 存儲庫中提取代碼。 如果您已經安裝了 Git 插件來響應 Jenkins 安裝設置中的提示,則無需安裝 GitHub 插件。 但是,如果沒有,這是在 Jenkins 中安裝 GitHub 插件并從 GitHub 存儲庫中提取代碼的方法。 ## 安裝 GIT 插件 **步驟 1**:單擊 Jenkins 儀表板上的**管理 Jenkins** 按鈕: ![](https://img.kancloud.cn/f1/3c/f13c08c1dc1ead8e1991decf563e546c_725x351.png) **步驟 2**:單擊**管理插件**: [![](https://img.kancloud.cn/98/a8/98a8b71f04c7c797fbcb04deea0bb08f_624x563.png) ](/images/1/091318_0440_JenkinsGitH3.png) **步驟 3**:在插件頁面中 1. 選擇 GIT 插件 2. 單擊**安裝,無需重新啟動。** 該插件將需要一些時間才能完成下載,具體取決于您的 Internet 連接,并且該插件會自動安裝。 3. 您還可以選擇選項**立即下載和重新啟動后安裝**按鈕。 重新啟動后在哪個插件中安裝 4. 如果您已經安裝了 Git 插件,則會顯示“無可用更新”消息。 ![](https://img.kancloud.cn/42/ef/42ef64abeefd2e17b2749a34a076421b_1222x538.png) **步驟 4**:安裝插件后,轉到 Jenkins 儀表板上的**管理 Jenkins** 。 您將在其余列表中看到您的插件。 ![](https://img.kancloud.cn/4d/14/4d14788ddbf111b91c398fc335ccb227_784x297.png) ## 將 Jenkins 與 GitHub 集成 現在,我們將討論在 Windows 系統中將 GitHub 集成到 Jenkins 中的過程。 **步驟 1)**在 Jenkins 中創建一個新作業,使用您的 Jenkins URL 打開 Jenkins 儀表板。 例如, [http:// localhost:8080 /](http://localhost:8080/) 單擊**創建新作業**: ![](https://img.kancloud.cn/2e/e7/2ee7445d20987bfe5744ca620d34900b_432x134.png) **步驟 2)**輸入項目名稱,選擇作業類型,然后單擊**確定**。 我們將以一個 Freestyle 項目為例。 ![](https://img.kancloud.cn/e1/b7/e1b7eb83c442f531df17249b2a520a43_737x366.png) **步驟 3)**單擊**確定,然后單擊**,頁面將重定向到其項目表單。 在這里您將需要輸入項目信息: ![](https://img.kancloud.cn/0b/33/0b33edfcfe1c773e4f0382fae9d4a357_1124x474.png) **步驟 4)**如果您的 Git 插件已安裝在 Jenkins 中,您將在**源代碼管理**下看到 **Git** 選項: ![](https://img.kancloud.cn/bc/ef/bcef74b6b28dac1e5eb84c2ba4816556_327x168.png) 注意:如果 **Git** 選項沒有出現,請嘗試重新安裝插件,然后重新啟動并重新登錄到 Jenkins 儀表板。 現在,您將能夠看到如上所述的 **Git** 選項。 **步驟 5)**輸入 Git 存儲庫 URL,以從 GitHub 中提取代碼。 [![](https://img.kancloud.cn/04/00/040031236741abf666625beeddb4a820_928x405.png) ](/images/1/091318_0440_JenkinsGitH10.png) **步驟 6)**首次輸入存儲庫 URL 時,您可能會收到一條錯誤消息。 例如: ![](https://img.kancloud.cn/85/0a/850a692eb3fc1bdc13414f079034d923_903x228.png) 如果您的本地計算機上未安裝 Git ,則會發生這種情況。 要在本地計算機上安裝 Git,請轉到 [https://git-scm.com/downloads](https://git-scm.com/downloads) ![](https://img.kancloud.cn/97/76/9776b323afff2424b3ddff33a5b6fe4c_950x377.png) 下載適合您的操作系統(在本例中為 Windows)的 Git 文件,并將其安裝到運行 Jenkins 的本地計算機上。 按照屏幕上的說明安裝 GIT。 ![](https://img.kancloud.cn/1f/c3/1fc308404f044cd4ccac6d01b2b04b99_504x393.png) **步驟 7)**一旦在計算機上安裝了 Git,就可以在 Jenkins 中執行 Git 存儲庫。 要檢查,是否已成功安裝到系統上,請打開**命令提示符,**鍵入“ Git” ,然后按 Enter。 您應該看到 Git 出現了不同的選擇: ![](https://img.kancloud.cn/30/7d/307dda046894add20604e2f2ae5c2b9a_639x193.png) 這意味著 Git 已安裝在您的系統中。 注意:如果您的系統中已經安裝了 GIT,則只需在“全局工具配置”中添加 git.exe 路徑。 **步驟 8)**一切就緒后,嘗試將 Git URL 添加到 Jenkins 中。 您將不會看到任何錯誤消息: [![](https://img.kancloud.cn/4d/a1/4da1ee10703287ec4675b7f5a8f60b47_932x313.png) ](/images/1/091318_0440_JenkinsGitH15.png) 現在已經在系統上正確配置了 Git。
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看