.\" Generated by scdoc 1.11.3 .\" Complete documentation for this program is not available as a GNU info page .ie \n(.g .ds Aq \(aq .el .ds Aq ' .nh .ad l .\" Begin generated content: .TH "apk" "8" "2024-04-29" .PP .SH NAME .PP apk - Alpine Package Keeper .PP .SH SYNOPSIS .PP \fBapk\fR [<\fIoptions\fR>.\&.\&.\&] \fIcommand\fR [<\fIarguments\fR>.\&.\&.\&] .PP .SH DESCRIPTION .PP \fBapk\fR manages packages installed on the system.\& The set of top level constraints on system packages is called the \fIworld\fR (see \fBapk-world\fR(5)).\& .PP \fBapk\fR supports various sub-commands to query and manipulate \fIworld\fR and package repositories.\& .PP By default apk is non-interactive.\& See \fBFILES\fR or \fB--interactive\fR on changing this default to be interactive.\& .PP .SH COMMANDS .PP Each command is documented in detail on its manual page.\& .PP .SS PACKAGE INSTALLATION AND REMOVAL .PP .TS l lx l lx. T{ \fBapk-add\fR(8) T} T{ Add packages to \fIworld\fR and commit changes T} T{ \fBapk-del\fR(8) T} T{ Remove packages from \fIworld\fR and commit changes T} .TE .sp 1 .SS SYSTEM MAINTENANCE .PP .TS l lx l lx l lx l lx. T{ \fBapk-fix\fR(8) T} T{ Fix, reinstall or upgrade packages without modifying \fIworld\fR T} T{ \fBapk-update\fR(8) T} T{ Update repository indexes T} T{ \fBapk-upgrade\fR(8) T} T{ Install upgrades available from repositories T} T{ \fBapk-cache\fR(8) T} T{ Manage the local package cache T} .TE .sp 1 .SS QUERYING PACKAGE INFORMATION .PP .TS l lx l lx l lx l lx l lx. T{ \fBapk-info\fR(8) T} T{ Give detailed information about packages or repositories T} T{ \fBapk-list\fR(8) T} T{ List packages matching a pattern or other criteria T} T{ \fBapk-dot\fR(8) T} T{ Render dependencies as graphviz graphs T} T{ \fBapk-policy\fR(8) T} T{ Show repository policy for packages T} T{ \fBapk-search\fR(8) T} T{ Search for packages by name or description T} .TE .sp 1 .SS REPOSITORY MAINTENANCE .PP .TS l lx l lx l lx l lx. T{ \fBapk-index\fR(8) T} T{ Create repository index file from packages T} T{ \fBapk-fetch\fR(8) T} T{ Download packages from repositories to a local directory T} T{ \fBapk-manifest\fR(8) T} T{ Show checksums of package contents T} T{ \fBapk-verify\fR(8) T} T{ Verify package integrity and signature T} .TE .sp 1 .SS MISCELLANEOUS .PP .TS l lx l lx l lx. T{ \fBapk-audit\fR(8) T} T{ Audit system for changes T} T{ \fBapk-stats\fR(8) T} T{ Show statistics about repositories and installations T} T{ \fBapk-version\fR(8) T} T{ Compare package versions or perform tests on version strings T} .TE .sp 1 .SH GLOBAL OPTIONS .PP The following options are available for all commands.\& .PP \fB-f, --force\fR .RS 4 Enable selected --force-* options (deprecated).\& .PP .RE \fB-i, --interactive\fR .RS 4 Ask confirmation before performing certain operations.\& Interactive mode can be made the default when running on a tty, by creating /etc/apk/interactive as an empty file.\& .PP .RE \fB-p, --root\fR \fIROOT\fR .RS 4 Manage file system at \fIROOT\fR.\& .PP .RE \fB-q, --quiet\fR .RS 4 Print less information.\& .PP .RE \fB-U, --update-cache\fR .RS 4 Alias for '\&--cache-max-age 1'\&.\& .PP .RE \fB-v, --verbose\fR .RS 4 Print more information (can be specified twice).\& .PP .RE \fB-V, --version\fR .RS 4 Print program version and exit.\& .PP .RE \fB-X, --repository\fR \fIREPO\fR .RS 4 Specify additional package repository.\& This option can be specified multiple times.\& .PP .RE \fB--allow-untrusted\fR .RS 4 Install packages with untrusted signature or no signature.\& .PP .RE \fB--arch\fR \fIARCH\fR .RS 4 Temporarily override architecture.\& When used with --root the architecture will be saved.\& .PP .RE \fB--cache-dir\fR \fICACHEDIR\fR .RS 4 Temporarily override the cache directory.\& \fICACHEDIR\fR is treated relative to the \fIROOT\fR.\& .PP .RE \fB--cache-max-age\fR \fIAGE\fR .RS 4 Maximum AGE (in minutes) for index in cache before it'\&s refreshed.\& .PP .RE \fB--force-binary-stdout\fR .RS 4 Continue even if binary data will be printed to the terminal.\& .PP .RE \fB--force-broken-world\fR .RS 4 DANGEROUS: Delete world constraints until a solution without conflicts is found.\& This does not allow installation of packages with unsatisfiable dependencies and is mainly intended to be used initramfs boot and is implied by \fB--initramfs-diskless-boot\fR.\& The primary purpose is to allow run-from-tmpfs systems to boot if media was upgraded and some packages are no longer available in the new release.\& .PP APK will try to determine the world constraints that causes packages with conflicting dependencies and start disabling the world constraints in this order until a satisfiable set of constraints is left.\& Using this switch on hard disk installation will likely result in unexpected removal of some packages.\& If uncertain, use with \fB--interactive\fR or \fB--simulate\fR first.\& .PP .RE \fB--force-missing-repositories\fR .RS 4 Continue even if some of the repository indexes are not available.\& .PP .RE \fB--force-non-repository\fR .RS 4 Continue even if packages may be lost on reboot.\& This can happen when running in run-from-tmpfs mode, and installing non-repository package.\& .PP .RE \fB--force-old-apk\fR .RS 4 Continue even if packages use unsupported features.\& .PP .RE \fB--force-overwrite\fR .RS 4 Overwrite files in other packages.\& .PP .RE \fB--force-refresh\fR .RS 4 Do not use cached files (local or from proxy).\& .PP .RE \fB--keys-dir\fR \fIKEYSDIR\fR .RS 4 Override directory of trusted keys.\& This is treated relative to \fIROOT\fR.\& .PP .RE \fB--no-cache\fR .RS 4 Do not use any local cache path.\& .PP .RE \fB--no-check-certificate\fR .RS 4 Do not validate the HTTPS server certificates.\& .PP .RE \fB--no-interactive\fR .RS 4 Disable interactive mode.\& .PP .RE \fB--no-network\fR .RS 4 Do not use the network.\& The cache is still used when possible.\& .PP .RE \fB--no-progress\fR .RS 4 Disable progress bar even for TTYs.\& .PP .RE \fB--print-arch\fR .RS 4 Print default arch and exit.\& .PP .RE \fB--progress\fR .RS 4 Show progress.\& .PP .RE \fB--progress-fd\fR \fIFD\fR .RS 4 Write progress to the specified file descriptor.\& .PP .RE \fB--purge\fR .RS 4 Purge modified configuration and cached packages.\& Enables deletion of modified configuration files on package removal.\& On cache clean action this enables deletion of unneeded cached packages (uninstalled packages on tmpfs installations or all packages on disk installations).\& .PP .RE \fB--repositories-file\fR \fIREPOFILE\fR .RS 4 Override system repositories, see \fBapk-repositories\fR(8).\& Specifying this option overrides the normal repositories file and repositories.\&d directory processing.\& The given \fIREPOFILE\fR is relative to the startup directory since apk 2.\&12.\&0_rc2.\& .PP .RE \fB--timeout\fR \fITIME\fR .RS 4 Timeout network connections if no progress is made in TIME seconds.\& The default is 60 seconds.\& .PP .RE \fB--wait\fR \fITIME\fR .RS 4 Wait for TIME seconds to get an exclusive repository lock before failing.\& .PP .RE .SH COMMIT OPTIONS .PP The following options are available for all commands which commit the database.\& .PP \fB-s, --simulate\fR .RS 4 Simulate the requested operation without making any changes.\& The database is opened in read only mode, and auto-updating of indexes is disabled.\& You may want to run "apk update" before running a simulation to make sure it is done with up-to-date repository indexes.\& .PP .RE \fB--clean-protected\fR .RS 4 Do not create .\&apk-new files in configuration directories.\& .PP .RE \fB--overlay-from-stdin\fR .RS 4 Read list of overlay files from stdin.\& Normally this is used only during initramfs when booting run-from-tmpfs installation.\& .PP .RE \fB--no-scripts\fR .RS 4 Do not execute any scripts.\& Useful for extracting a system image for different architecture on alternative \fIROOT\fR.\& .PP .RE \fB--no-commit-hooks\fR .RS 4 Skip pre/post hook scripts (but not other scripts).\& .PP .RE \fB--initramfs-diskless-boot\fR .RS 4 Used by initramfs when it'\&s recreating root tmpfs.\& This enables selected force options to minimize failure, and disables commit hooks, among other features.\& .PP .PP .RE .SH SOURCE OPTIONS .PP The following options are available for all commands which operate on the package indexes only.\& .PP \fB--from\fR \fIFROMSPEC\fR .RS 4 Search packages from: \fBsystem\fR (all system sources), \fBrepositories\fR (exclude installed database), \fBinstalled\fR (exclude normal repositories) or \fBnone\fR (commandline repositories only).\& .PP .RE .SH ENVIRONMENT .PP \fBLANG\fR .RS 4 Used to determine if UTF-8 is supported, and set the default progress character accordingly.\& .PP .RE \fBSOURCE_DATE_EPOCH\fR .RS 4 See \fBapk-index\fR(8).\& .PP .RE \fBTERM\fR .RS 4 Used to determine if the terminal is dumb or not.\& Progress bar is not enabled on dumb terminals by default.\& .PP .RE .SS Variables to configure built-in libfetch .PP \fBFETCH_BIND_ADDRESS\fR .RS 4 A local IP address to which libfetch will bind all sockets it creates.\& Can be useful for source routing.\& .PP .RE \fBFTP_PROXY\fR, \fBftp_proxy\fR .RS 4 If set, these variables should contain the proxy URL for \fBftp\fR connections.\& .PP .RE \fBNETRC\fR .RS 4 Specify the \fB.\&netrc\fR file to read for authentication secrets.\& If not set, defaults to \fB$HOME/.\&netrc\fR.\& .PP .RE \fBHTTP_AUTH\fR .br \fBHTTP_REFERER\fR .br \fBHTTP_USER_AGENT\fR .RS 4 Specify a custom HTTP level \fBAuthorization\fR, \fBReferer\fR or \fBUser-Agent\fR header.\& .PP .RE \fBHTTP_PROXY\fR, \fBhttp_proxy\fR .br \fBHTTPS_PROXY\fR, \fBhttps_proxy\fR .br If set, these variables should contain the proxy URL for \fBhttp\fR .RS 4 and \fBhttps\fR connections respectively.\& .PP .RE \fBHTTP_PROXY_AUTH\fR .RS 4 Specify a HTTP \fBProxy-Authorization\fR header.\& Used only if the connection is established through a configured HTTP proxy.\& .PP .RE \fBNO_PROXY\fR, \fBno_proxy\fR .RS 4 Comma-separated list of domain extensions or CIDR notation IP addresses to which a proxy should \fInot\fR be used for.\& This is used explicitly to test the URL hostname portion only.\& That is, specifying an IP address or CIDR block will not match a DNS name that resolves to the IP address.\& .PP .RE \fBSSL_CLIENT_CERT_FILE\fR .br \fBSSL_CLIENT_KEY_FILE\fR .RS 4 Override default SSL client certificate and corresponding private key filename.\& .PP .RE \fBSSL_NO_VERIFY_HOSTNAME\fR .RS 4 If set to anything, disables the server certificate name verification.\& .PP .RE .SH FILES .PP .SS Configuration files .PP \fB/etc/apk/arch\fR .RS 4 The CPU architecture for this database.\& See \fBapk-package\fR(5) section on package metadata field \fBarch\fR for the list.\& .PP .RE \fB/etc/apk/cache\fR .RS 4 This is expected to be a symlink to directory what apk will use as package cache.\& See also \fBapk-cache\fR(5) and \fBapk-cache\fR(8).\& .PP .RE \fB/etc/apk/commit_hooks.\&d/*.\&pre-commit\fR .br \fB/etc/apk/commit_hooks.\&d/*.\&post-commit\fR .RS 4 Hook scripts which are executed before or after changes to database are committed.\& If a pre-commit script returns failure, the commit is aborted.\& .PP If \fB--no-scripts\fR or \fB--no-commit-hooks\fR option is specified, these hook scripts are not executed.\& .PP .RE \fB/etc/apk/interactive\fR .RS 4 If this file exists and apk is running on a tty, \fB--interactive\fR mode is enabled by default.\& .PP .RE \fB/etc/apk/keys\fR .RS 4 A directory containing trusted signing keys for apk.\& .PP .RE \fB/etc/apk/protected_paths.\&d/*.\&list\fR .RS 4 Configuration files to specify how to treat changes to specified directory or file masks.\& .PP .RE \fB/etc/apk/repositories\fR .br \fB/etc/apk/repositories.\&d/*.\&list\fR .RS 4 Configuration files to specify repositories.\& See \fBapk-repositories\fR(5) for details.\& .PP .RE \fB/etc/apk/world\fR .RS 4 Top level requirements and constraints on what should be installed.\& See \fBapk-world\fR(5) for details.\& .PP .RE .SS Configuration files for built-in libfetch .PP \fB/etc/apk/ca.\&pem\fR .RS 4 CA certificate store bundle for verifying server certificates.\& If not present, the default system CA store is used.\& .PP .RE \fB/etc/apk/crl.\&pem\fR .RS 4 CRL store to check the server certificates against.\& .PP .RE \fB/etc/apk/cert.\&key\fR .RS 4 Client certificate private key.\& .PP .RE \fB/etc/apk/cert.\&pem\fR .RS 4 Client certificate to use for authentication.\& .PP .RE .SS System files .PP \fB/lib/apk/db/lock\fR .RS 4 A lock file used to allow only one concurrent write transaction on the system.\& .PP .RE \fB/lib/apk/db/installed\fR .RS 4 Database of installed packages and their contents.\& .PP .RE \fB/lib/apk/db/scripts.\&tar\fR .RS 4 Collection of all package scripts from currently installed packages.\& .PP .RE \fB/lib/apk/db/triggers\fR .RS 4 List of triggers rules for currently installed packages.\& .PP .RE \fB/lib/apk/exec\fR .RS 4 Temporary directory for extraction and execution of package scripts and triggers.\& .PP .RE .SH NOTES .PP This apk has coffee making abilities.\&