Installation
Install the prebuilt nginxpm binary or build nginxpm CLI from source.
Install script (recommended)
Installs the latest prebuilt binary for your OS/arch. No Go toolchain is required:
curl -sSfL https://raw.githubusercontent.com/piyush-gambhir/nginxpm-cli/main/install.sh | shPin a version or change the install directory:
curl -sSfL https://raw.githubusercontent.com/piyush-gambhir/nginxpm-cli/main/install.sh | VERSION=0.1.7 sh
curl -sSfL https://raw.githubusercontent.com/piyush-gambhir/nginxpm-cli/main/install.sh | INSTALL_DIR=~/.local/bin shThe installer supports macOS and Linux on amd64 and arm64. Its default install
directory is /usr/local/bin.
Download a release manually
Prebuilt binaries are attached to each
GitHub Release. Download
the archive for your OS/arch, extract it, and put nginxpm on your PATH:
# example (macOS arm64): adjust the version and asset name
curl -sSfL -o nginxpm.tar.gz https://github.com/piyush-gambhir/nginxpm-cli/releases/download/v0.1.7/nginxpm-cli_darwin_arm64.tar.gz
tar -xzf nginxpm.tar.gz
sudo mv nginxpm /usr/local/bin/Build from source
Requires a Go toolchain. The CLI lives in the cli-go/ directory of the
repository:
git clone https://github.com/piyush-gambhir/nginxpm-cli.git
cd nginxpm-cli/cli-go && make installThe binary is nginxpm.
Update
nginxpm update --check # compare your version with the latest release
nginxpm update # download, verify, and install itnginxpm update works on macOS, Linux, and Windows. It downloads the release
archive for your platform, verifies its SHA-256 against the release's
checksums.txt, and replaces the binary. On Windows the running nginxpm.exe
is moved aside to nginxpm.exe.old, which the next run deletes. It asks before
installing; pass --yes to skip the prompt (required with --no-input or
without a terminal). If the binary's directory is not writable, re-run with
sudo or reinstall with the install script into a writable INSTALL_DIR. A
source build in a Go bin directory ($GOBIN, $GOPATH/bin, ~/go/bin) is not
replaced: run git pull && make install in your clone instead.
In an interactive terminal, nginxpm checks GitHub for a new release at most once a day and, after the command's own output, prints a notice on stderr:
A new version of nginxpm is available: v0.1.9 -> v0.1.10
Update with: nginxpm update
Release notes: https://github.com/piyush-gambhir/nginxpm-cli/releases/tag/v0.1.10The check never runs when stderr is not a terminal (pipes, scripts, coding
agents), when CI is set, with --quiet, or for update, version,
completion, and help. Turn it off with NGINXPM_NO_UPDATE_NOTIFIER=1 or
NO_UPDATE_NOTIFIER=1.
Continue with authentication, then use the quick start to verify the connection.
Verify
nginxpm version