Skip to contents

Maps a package manager to the corresponding platform identifier used by the pak package's system requirements feature.

Usage

map_to_sysreqs_platform(package_manager, os = NULL)

Arguments

package_manager

Package manager type (e.g., "apt", "yum")

os

Operating system (if known)

Value

Character string of platform for sysreqs

Details

This internal function maps package managers to platform identifiers understood by the pak package's system requirements feature. It uses the following mappings:

  • apt → ubuntu (or debian if specified)

  • yum → centos (or fedora, redhat, rockylinux if specified)

  • zypper → opensuse (or sle if specified)

  • apk → ubuntu (Alpine not directly supported)

  • pacman → ubuntu (Arch not directly supported)

If the OS is explicitly provided and supported by pak, that platform is used directly.

See also

determine_package_manager() for determining the package manager & dk_add_sysreqs() for adding system requirements to a dockerfile

Other utility functions: determine_linux_distribution(), determine_package_manager(), dk_add_sysreqs()