Alpine Linux: Difference between revisions

Content deleted Content added
m clean up
Cleanup
Tags: Mobile edit Mobile web edit Advanced mobile edit
 
(42 intermediate revisions by 33 users not shown)
Line 1:
{{short description|Linux distribution based on musl and BusyBox}}
{{Use dmy dates|date=JanuaryJune 20212025}}
{{Infobox OS
| name = Alpine Linux
| logo = Alpine Linux.svg{{!}}class=skin-invert
| screenshot =
| caption =
Line 11:
| source model = [[Open-source software|Open source]]
| released = {{Start date and age|2005|08|df=yes}}<ref name="sf-history"/>
| latest release version = 3.18.2{{wikidata|property|reference|P348}}
| latest release date = {{start date and age|{{wikidata|qualifier|P348|P577}}}}
| latest release date = {{Start date and age|2023|06|14|df=yes}}<ref>{{Cite web|url=https://alpinelinux.org/posts/Alpine-3.15.9-3.16.6-3.17.4-3.18.2-released.html|title="Alpine 3.15.9, 3.16.6, 3.17.4 and 3.18.2 released" |date=2023-06-14 | accessdate=2023-06-22}}</ref>
| marketing target = General-purpose. Security, embedded systems and other resource-constrained systems, such as containers.<ref name="about">{{Cite web |title=about &#124; Alpine Linux |url=https://alpinelinux.org/about/ |website=alpinelinux.org}}</ref>
| marketing target = Power users
| language = [[Multilingualism|Multilingual]]
| package manager = APK ''(Alpine Package Keeper)''<ref name="apk">{{Cite web |title=Alpine Package Keeper |url=https://wiki.alpinelinux.org/wiki/Alpine_Package_Keeper |website=wiki.alpinelinux.org}}</ref>
| package manager = apk-tools
| supported platforms = {{Plain list|
* [[x86]],
* [[x86-64]],
* [[ARMhf]],
* [[ARMv7]],
* [[AArch64]],
* [[ppc64le]],
* [[s390x]]
* [[LoongArch]]
* [[RISC-V|riscv64]]
}}
| kernel type = [[Monolithic kernel|Monolithic]] ([[Linux kernel|Linux]])
| userland = [[BusyBox]]
Line 30 ⟶ 34:
}}
 
'''Alpine Linux''' is a [[Linux distribution]] designed to be small, simple, and secure.<ref name="about">{{Cite web |title=about &#124; Alpine Linux |url=https://alpinelinux.org/about/ |website=alpinelinux.org}}</ref> Alpine LinuxIt uses [[musl]], [[BusyBox]], and [[OpenRC]] instead of the more commonly used [[glibc]], [[GNU Core Utilities]], and [[systemd]] respectively.<ref name="linuxbsdos">{{Cite web|url=https://linuxbsdos.com/2010/08/23/alpine-linux-2-review/|title=Alpine Linux 2 review &#124; LinuxBSDos.com|first=GigaTux|last=says|date=24 August 2010}}</ref><ref name="softpedia">[https://news.softpedia.com/news/security-oriented-alpine-linux-3-7-has-uefi-support-grub-support-in-installer-518820.shtml Security-Oriented Alpine Linux 3.7 Has UEFI Support, GRUB Support in Installer], ''Softpedia News''</ref><ref name="fossbytes">[https://fossbytes.com/secure-linux-distros-privacy-anonymity/ 10 Most Secure Linux Distros For Complete Privacy & Anonymity | 2017 Edition], ''FossBytes''</ref><ref name="networkworld">{{Cite web|url=https://www.networkworld.com/article/3031762/is-docker-ditching-ubuntu-linux-confusion-reigns.html|title=Is Docker ditching Ubuntu Linux? Confusion reigns|first=Katherine|last=Noyes|date=9 February 2016|website=Network World}}</ref><ref>{{Cite web |title=OpenRC - Alpine Linux |url=https://wiki.alpinelinux.org/wiki/OpenRC |website=wiki.alpinelinux.org}}</ref> This makes Alpine one of few Linux distributions not to be based on the GNU Core Utilities or glibc.<ref>{{Cite web |title=What is Alpine Linux? {{!}} Definition from TechTarget |url=https://www.techtarget.com/searchitoperations/definition/Alpine-Linux |access-date=24 November 2023 |website=IT Operations |language=en}}</ref>
 
For security, Alpine compiles all [[user space|user-space]] binaries as [[position-independent executable]]s with [[stack-smashing protection]].<ref>{{CitationCite web needed|datetitle=MayAlpine 2023Linux official website under Secure section. |url=https://alpinelinux.org/about/ |website=alpinelinux.org/}}</ref>
 
Because of its small size and rapid startup, it is commonly used in [[Operating-system-level virtualization|containers]] providing quick boot-up times,<ref name="thenewstack">{{Cite web|url=https://thenewstack.io/alpine-linux-heart-docker/|title=Meet Alpine Linux, Docker's Distribution of Choice for Containers|date=28 March 2017}}</ref><ref name="infoworld">{{Cite web|url=https://www.infoworld.com/article/3206644/review-alpine-linux-is-made-for-docker.html|title=Review: Alpine Linux is made for Docker|date=10 July 2017|website=InfoWorld}}</ref> on [[virtual machine]]s as well as on real hardware in [[Embedded system|embedded devices]], such as [[Router (computing)|routers]], [[Server (computing)|servers]] and [[Network-attached storage|NAS]].{{Citation needed|date=May 2023}}
 
==History==
Originally, Alpine Linux began as an embedded-first distribution for devices such as [[wireless router]]s, based on [[Gentoo Linux]],<ref>{{cite web|url=https://sourceforge.net/p/leaf/mailman/message/12731262/|title=Re: [leaf-devel] 2.6.x kernel support?|website=SourceForge}}</ref> inspired by {{Tooltip|GNAP|Gentoo Network Appliance Project}} and the Bering-uClibc branch of the [[LEAF Project]].<ref name="sf-history">{{cite web|url=https://sourceforge.net/p/leaf/mailman/message/12731159/|title=Re: [leaf-devel] 2.6.x kernel support?|website=SourceForge}}</ref> Founder Natanael Copa has said that the name was chosen as a [[backronym]] for "A Linux-Powered Network Engine" or some such similar phrase, but that the exact phrase has since been forgotten.<ref name=":0">{{Citation |title=Small, Simple, and Secure: Alpine Linux under the Microscope | date=3 November 2017 |url=https://www.youtube.com/watch?v=sIG2P9k6EjA |access-date=30 June 2023 |language=en}}</ref>
 
Alpine's [[package management]] system, the Alpine Package Keeper (apk-tools),<ref>{{Citeefn|Not webto |title=Alpinebe Packageconfused Keeperwith -the Alpine[[apk Linux(file format)|url=https://wiki.alpinelinux.org/wiki/Alpine_Package_Keeperapk file format]] used by [[Android (operating system)|website=wiki.alpinelinux.orgAndroid]]}}</ref name="apk"/> was originally a collection of [[shell scriptsscript]]s<ref>{{Cite web|url=https://sourceforge.net/projects/apk-tools/|title=apk-tools|website=SourceForge|date=18 April 2013 }}</ref> but was later rewritten in [[C (programming language)|C]].<ref>{{Cite web|url=https://git.alpinelinux.org/apk-tools/|title=apk-tools - Alpine package manager|website=git.alpinelinux.org}}</ref> The aim of this package manager is to achieve a high install and update speed, which it does by writing new data directly in-place into the operating system's [[file system]], rather than employing [[Cache (computing)|caching]] or [[Data compression|compression]].<ref name=":0"/>
 
As of 4 JuneIn 2014, Alpine Linux switched from [[uClibc]] to [[musl]] as its [[C standard library]].<ref>{{cite web |title=Release notes |url=https://alpinelinux.org/posts/Alpine-3.0.0-released.html |access-date=6 May 2018 |website=alpinelinux.org}}</ref>
 
A [[HardeningExecutable-space (computing)protection#PaX|hardenedPaX]] hardened kernel was included in the default distribution for up to and including Alpine 3.7, which aidedaid in reducing the impact of exploits and vulnerabilities.,<ref>{{Cite web |title=Alpine 3.8.0 released {{!}} Alpine Linux |url=https://alpinelinux.org/posts/Alpine-3.8.0-released.html |access-date=27 April 2022 |website=alpinelinux.org}}</ref> but Alpine's maintainers chose to discontinue this support due to the PaX patch no longer being made publicly available.<ref>{{Cite web |title=How does Alpine Linux harden its kernel? — alpinelinux lists |url=https://lists.alpinelinux.org/~alpine/users/%3CCABbU2U-04w34QfSGg4wZKxvCoYgtqLRj9Z0SKHipDPNaSdHdBeAQ@mail.gmail.com%3E |access-27date=30 June 2023 |website=lists.alpinelinux.org}}</ref> Alpine still uses a [[Hardening (computing)|hardened]] toolchain and position-independent executables to minimize the potential for [[Buffer overflow|stack-based attacks]],<ref name=":0" /> but is now based on the standard long term stable distribution of the Linux kernel.
 
==Features==
 
Alpine's primary feature is its small size, which enables it to start quickly and run in environments very low in memory and storage, such as [[OS-level virtualization|containers]] or [[Embedded system|embedded devices]].
Alpine Linux can be installed as a [[RAM drive|run-from-RAM]] operating system. The ''LBU'' (Alpine Local Backup)<ref>{{Cite web|url=https://wiki.alpinelinux.org/wiki/Alpine_local_backup|title=Alpine local backup - Alpine Linux|website=wiki.alpinelinux.org}}</ref> tool optionally allows all configuration files to be backed up to an APK overlay file (usually shortened to ''apkovl''), a [[tar.gz]] file that by default stores a copy of all changed files in /etc (with the option to add more directories). This allows Alpine to work reliably in demanding embedded environments or to (temporarily) survive partial disk failures as sometimes experienced in public cloud environments.
 
Alpine Linux can optionally be installed as a [[RAM drive|run-from-RAM]] operating system. This allows Alpine to work reliably in demanding embedded environments or to (temporarily) survive partial disk failures as sometimes experienced in public cloud environments. By default, Alpine running in this mode will only load a few key packages, but a tool called ''LBU'' (Alpine Local Backup)<ref>{{Cite web |title=Alpine local backup - Alpine Linux |url=https://wiki.alpinelinux.org/wiki/Alpine_local_backup |website=wiki.alpinelinux.org}}</ref> is made available that allow changes in this boot configuration to be written to a special file called an APK overlay file (usually shortened to ''apkovl''), a [[tar.gz]] file that by default stores a copy of all files in /etc that have been changed from the default configuration, with the option to track more directories as needed.
Alpine Configuration Framework (ACF): While optional, ACF is an application for configuring an Alpine Linux machine, with goals similar to [[Debian|Debian's]] [[Debconf (software package)|debconf]]. It is a standard framework based on simple Lua scripts.<ref>{{Cite web|url=https://wiki.alpinelinux.org/wiki/Alpine_Configuration_Framework_Design|title=Alpine Configuration Framework Design - Alpine Linux|website=wiki.alpinelinux.org}}</ref>
 
Alpine offers a number of preinstalled configuration scripts which guide the user through initial configuration of the system for common computing tasks.<ref>{{Citation |title=alpine-conf |date=17 June 2023 |url=https://github.com/alpinelinux/alpine-conf |access-date=30 June 2023 |publisher=Alpine Linux}}</ref> In addition, Alpine also offers a [[Web server|webserver]]-based tool known as the Alpine Configuration Framework, which allows users less familiar with Alpine or the command line to configure the operating system in a way similar to that allowed by [[Debian|Debian's]] [[Debconf (software package)|debconf]] utility. Alpine's configuration scripts are written entirely as UNIX [[shell script]]s, which call a small [[Optical disc image|ISO image]] parsing utility written in C and distributed in Alpine. The Alpine Configuration Framework is scripted in [[Lua (programming language)|Lua]].<ref>{{Cite web|url=https://wiki.alpinelinux.org/wiki/Alpine_Configuration_Framework_Design|title=Alpine Configuration Framework Design - Alpine Linux|website=wiki.alpinelinux.org}}</ref>
== Derivatives ==
[[postmarketOS]], a Linux distribution for [[Linux for mobile devices|mobile devices]], is based on Alpine Linux.<ref name="postmarketOS">{{Cite web |date=28 April 2022 |title=postmarketOS // real Linux distribution for phones |url=https://postmarketos.org |website=postmarketos.org}}</ref>
 
=== Integration with popular developer and administrator environments ===
Due to its robustness and compactness, Alpine Linux gotis tightly integrated with popular developer and system administrator environments and toolsets.
 
* [[Microsoft Windows Store]] offers a deployment-ready version of Alpine WSL<ref>{{Cite web |title=Get Alpine WSL from the Microsoft Store |url=https://apps.microsoft.com/store/detail/alpine-wsl/9P804CRF0395 |access-date=2023-04-14 April 2023 |website=apps.microsoft.com |language=en}}</ref> for [[Windows Subsystem for Linux|WSL2]]
* [[Docker (software)|Docker]] offers Alpineofficial Dockerimages Officialof ImageAlpine Linux<ref>{{Cite web |date=8 September 2022-09-08 |title=How to Use the Alpine Docker Official Image {{!}} Docker |url=https://www.docker.com/blog/how-to-use-the-alpine-docker-official-image/ |access-date=2023-04-14 April 2023 |website=www.docker.com |language=en-US}}</ref>
* [[PowerShell|Microsoft PowerShell]] provides an Alpine Linux specific build<ref>{{Cite web |last=sdwheeler |title=Installing PowerShell on Alpine Linux - PowerShell |url=https://learn.microsoft.com/en-us/powershell/scripting/install/install-alpine |access-date=2023-04-14 April 2023 |website=learn.microsoft.com |date=17 March 2023 |language=en-us}}</ref>
 
== Derivatives ==
[[postmarketOS]], a Linux distribution for [[Linux for mobile devices|mobile devices]], is based on Alpine Linux.<ref name="postmarketOS">{{Cite web |date=28 April 2022 |title=postmarketOS // real Linux distribution for phones |url=https://postmarketos.org |website=postmarketos.org}}</ref>
 
==References and notes==
{{Reflist|30em|refs=}}
{{Notelist}}
 
==External links==