The Admin CLI in Posit Package Manager

Follow

Posit Package Manager is administered through a command-line interface (CLI). Administrators can use the CLI to create repositories and sources, add local packages to sources, and setup sync schedules for CRAN sources.

The CLI is installed at /opt/rstudio-pm/bin/rspm. The CLI uses the configuration defined in /etc/rstudio-pm/rstudio-pm.gcfg unless you specify an alternate configuration file with the --config flag.

Privileges

Users must be a member of the rstudio-pm group in order to use the Posit Package Manager CLI. See Changing RunAs User for instructions on changing the required group.

The Posit Package Manager CLI uses a Unix domain socket for communicating with the Posit Package Manager server. By default, the domain socket file is located at /var/run/rstudio-pm/rstudio-pm.sock. You can customize the location by configuring the Server.SockFileDir setting.

Any user invoking the Posit Package Manager CLI must have read/write access to the Unix domain socket in order to communicate with the Posit Package Manager server.

Location

The CLI is located at /opt/rstudio-pm/bin/rspm. We recommend that users make an alias, add this location to their PATH, or navigate to this directory if they will be running multiple commands in one session, for example:

alias rspm='/opt/rstudio-pm/bin/rspm'

Getting Help

Simply run rspm without any arguments to display the top-level help for the Posit Package Manager CLI. For help with a specific command, you can use the help command. For example, to display help about the create command, you can use rspm help create.

Examples

For examples using the CLI, please refer to the Configuration guide.

Comments