•  untoreh-ukukhanya

I-Alpine

I-Pine, i-Alpine linux ngokususelwa ku-OSTree

Ukukhetha ini OS run kumaseva akho kuyindaba elula nokujwayela. Ukuba lula kusho ukuthi ufuna okuthile okukunikeza izinkinga ezimbalwa ngangokunokwenzeka, ukujwayela kusho ukuthi ungathanda hhayi ukufunda izinto ezingeziwe uma ungadingi.

Amaseva ami izilwane ezifuywayongakho-ke kulungile ngikhipha imiyalo embalwa njalo ngesikhashana, futhi angidingi ukuzenzakalela okuphelele.

Ngemuva kokuzama ICoreOS isikhathi esingangonyaka ngishintshela kweyami eyenziwe lula distro ngokususelwa ku-alpine futhi u-ostree.

Imigomo

Le nguqulo ye-alpine ithatha izinkomba kusuka ku- I-flatcar futhi iphrojekthi-athomu futhi kulindeleke ukuthi ifakwe njengohlelo lokufunda kuphela lwempande enezibuyekezo ezenzeka nge-athomu, okungukuthi, ziyaphumelela noma uhlelo lubuyela esimweni esedlule. Ukuze lokhu kwenzeke ohlelweni kufanele okungenani kube nakho okungenani izifinyezo ezimbili yohlobo lwefayela lohlelo olukhishiwe, olutholakala ekugcineni.

Okuqondiwe

Kuzosebenza kuziphi izindawo uhlelo? Ngikhombe I-OVZ ne- [KVM], kepha ngokujwayelekile ungasho iziqukathi futhi imishini ebonakalayo ngomehluko omkhulu ukuthi iziqukathi azisebenzi i-kernel yazo, ikakhulukazi ayinayo inqubo yokuqalisa, zibiza ngqo ku init system (okuyisibonelo kuDockerfile kungachazwa yiCMD nomaENTRYPOINT izitatimende), esibhekele ukuphatha isihlahla semithamo esizogcina isitsha sisebenza (njengeseshini ejwayelekile, uma inqubo ye-init ifa, isitsha siyaphela). Futhi iziqukathi azikwazi ukumisa izinkinobho zohlelo, futhi zingaba nemikhawulo eyengeziwe emandleni.

Ukuqaphela inqubo yokwakha

Isithombe sakhiwa kanjani?

Ukuncika

I-prepare.sh iskripthi sisingatha ukuncika, iningi lakhona okungamaphakeji okunikela ngamathuluzi ajwayelekile we-ehl afana ne-coreutils, util-linux, binutils , Izinsiza ezisebenza ngamadivayisi we-block njengeblkid, sfdisk, multipath-tools nezinhlelo zamafayela ngexfsprogs futhie2fsprogs . I-squashfs-tools package isetshenziswa ekugcineni ukucindezela uhlelo lwefayela lempande elakhiwe. Aglib iphakethe lokuhambisana nalo lifakwe ngokuzenzakalela ngoba i-alpine isuselwe ku-musl, iphakethe lokuhambisana lisebenza ngokunikela ngemitapo yolwazi ethile eyakhelwe ngokumelene nayo.

Isihlahla

Izihlahla zefayela zawo womabili ama-VM neziqukathi zakhiwa ngokulandelanamake.sh futhimake_ovz.sh . Le incazelo elula yezinyathelo

Kwiziqukathi, ukulandelana kuyafana, kepha izinguquko zokumiswa, ngoba ngohlelo olungaboshiwe ku-a ukulanda I-ostree inezinkinga zokuqinisekisa imvelo, kufanele sisebenzise ezinye ukusebenza futhi usethe amanye amadivayisi avame ukuphathwa yifayela le- initramfs isinyathelo. Ngale ndlela I-OVZ noma I-LXC izifanekiso zilungiselelwe.

Ukupakisha

Lapho sesinesihlahla sethu samafayela esizinikele nge-ostreebuild.sh nomabuild-update.sh unakekela ukukhiqiza i-artifact ezosatshalaliswa. Umehluko phakathi kwemibhalo ukuthi inguqulo yokuvuselela iqala endaweni yokugcina yangaphambilini ye-ostree, futhi futhi ikhiqiza i-delta artifact lapho uhlelo olusebenzayo lungasebenza esimweni sayo se-ostree ukwenza ukuthuthuka. Le yincazelo eyenziwe lula yezinyathelo zokwakha

Ukucushwa kokuhlukaniswa kusetshenziswa nge-fdisklayout.cfg ifayela elichaza osayizi bokuhlukanisa, sinesahlukaniso esisodwa sezimpande (~430M ), ukwahlukaniswa kwebhuthi (~40M ) kanye nokwahlukanisa okushintshanayo (~40M ). Ngeziqukathi ezinokweqa nje ukufaka okwedlule ngokwedivayisi ye-loop, bese umane udonse ukuzibophezela okusha kwe-ostree ngaphezulu kwendawo endala (ekhishiwe) ye-ostree.

Ukwenza ngezifiso

Yini engiyihlanganisa kulesi sithombe (ngaphandle kwamaphakeji afakiwe)?

Lokho okwake kwaba khona futhi akusekho

Ukufaka

Ukufaka isithombe ungasilayisha kumhlinzeki wokusingathwa bese usifaka kusuka ku-VNC, uma kwenzeka kuba nemishini ebonakalayo, kepha ngivame ukuduna ukufakwa okukhona, ngoba kuhlala kunokwenzeka, inqobo nje uma ngivivinye iskripthi sokusetha ngohlobo lwe ukusatshalaliswa kwe-linux, imvamisa ngisebenzisa i-debian-8 noma i-ubuntu-14, angizange ngivivinye ezinye ngoba lokhu ngihlale ngithola ukuthi lokhu kuyatholakala. Izinyathelo zokusetha ziyalandela

Iziphetho

ngenze uphayini 5 years from time of writing and I am still using it, and I see no reasons to switch to anything else. Alpine as a linux distro is great, simple, and I have never experienced breakage. I can easily deploy on OKUDLALIWE amaseva ajwayele ukunikela ngezinsizakusebenza eziphansi kakhulu, empeleni nginebhokisi elisebenza nge-just64M ye-RAM, futhi ngisenazo zonke izici engizidingayo.

[1]uhlelo lwefayela lempande

Thumela Amathegi: