Cov txheej txheem:

Kuv yuav khiav Jenkins Docker li cas?
Kuv yuav khiav Jenkins Docker li cas?

Video: Kuv yuav khiav Jenkins Docker li cas?

Video: Kuv yuav khiav Jenkins Docker li cas?
Video: Kuv yuav txiv lawm cover kab lia vwj 2024, Kaum ib hlis
Anonim

Tsim ib Docker ntim hauv lub thawv ntawm /var/jenkins_home (the Jenkins home directory) Khiav Jenkins ntawm qhov chaw nres nkoj 8080 (raws li tau teev los ntawm parameter -p)

Yog hais tias koj yuav tau ua txhua yam manually koj yuav tau:

  1. Nruab Java.
  2. Qhov siab Jenkins .
  3. Nruab xav tau plugins.
  4. Configure Jenkins .
  5. Tsim ib lub tsev tshiab.
  6. Khiav lub tsev.

Kuj nug, Kuv yuav txuas Jenkins rau Docker li cas?

Docker plugin yog kev siv "Cloud". Koj yuav tau kho Jenkins system configuration ( Jenkins > Tswj > System configuraiton) thiab ntxiv huab tshiab hom " Docker ". Configure Docker (lossis Swarm standalone) API URL nrog cov ntawv pov thawj xav tau. Ib lub pob kuaj cia koj kev sib txuas nrog API tau teeb tsa zoo.

Ib yam li ntawd, kuv yuav khiav Jenkins li cas? Txhawm rau rub tawm thiab khiav WAR cov ntaub ntawv version ntawm Jenkins:

  1. Download tau qhov tseeb ruaj khov Jenkins WAR cov ntaub ntawv mus rau cov npe tsim nyog ntawm koj lub tshuab.
  2. Qhib lub terminal/command prompt qhov rais mus rau lub download directory.
  3. Khiav cov lus txib java -jar jenkins. tsov rog.
  4. Txuas ntxiv mus nrog Post-installation teeb wizard hauv qab no.

Qhov thib ob, Kuv yuav ua li cas thiaj li khiav Jenkins ntawm Windows?

Yuav ua li cas rau nruab Jenkins ntawm Windows

  1. Nyem "Tom ntej" mus pib lub installation.
  2. Nyem rau "Hloov" khawm yog tias koj xav nruab Jenkins hauv lwm daim nplaub tshev.
  3. Nyem rau "Nruab" khawm kom pib lub installation txheej txheem.
  4. Lub installation yog ua.
  5. Thaum ua tiav, nyem lub pob "Finish" kom tiav cov txheej txheem installation.

Kuv yuav khiav lub thawv docker hauv Jenkins li cas?

Qhib lub Jenkins home page nyob rau hauv ib tug browser thiab nyem qhov "tsim cov hauj lwm tshiab" txuas. Sau lub npe khoom (piv txwv li " docker -test"), xaiv "Freestyle project" thiab nyem OK. Ntawm nplooj ntawv teeb tsa, nyem "Add build step" ces " Ua kom tiav shell" nyob rau hauv lub thawv hais kom nkag mus rau "sudo docker khiav nyob zoo-world"

Pom zoo: