Now we provide official OpenResty packages repos for Debian 11 Bullseye (includes both x86_64 and aarch64 architectures). Feedback is always welcome. Thanks a lot!
Note: if nginx is already installed and running, try disabling and stopping it before installing openresty like below:
sudo systemctl disable nginx sudo systemctl stop nginx
Otherwise the installation might fail.
You can add the
openresty repository to your Debian system so as to easily install our packages and receive updates in the future (via the
apt-get update command).
To add the repository, just run the following commands (only need to run once for each system):
Step 1: install some prerequisites needed by adding GPG public keys (could be removed later):
sudo apt-get -y install --no-install-recommends wget gnupg ca-certificates
Step 2: import our GPG key:
wget -O - https://openresty.org/package/pubkey.gpg | sudo apt-key add -
Step 3: add the our official APT repository.
codename=`grep -Po 'VERSION="[0-9]+ \(\K[^)]+' /etc/os-release` echo "deb http://openresty.org/package/debian $codename openresty" \ | sudo tee /etc/apt/sources.list.d/openresty.list
And for arm64 or aarch64 systems:
codename=`grep -Po 'VERSION="[0-9]+ \(\K[^)]+' /etc/os-release` echo "deb http://openresty.org/package/arm64/debian $codename openresty" \ | sudo tee /etc/apt/sources.list.d/openresty.list
Step 4: update the APT index:
sudo apt-get update
Then you can install a package, say,
openresty, like this:
sudo apt-get -y install openresty
This package also recommends the openresty-opm and openresty-restydoc packages so the latter two will also automatically get installed by default. If that is not what you want, you can disable the automatic installation of recommended packages like this:
sudo apt-get -y install --no-install-recommends openresty
See the OpenResty Deb Packages page for more details on all available packages in this repository.
Check out Linux Packages page for more information about the official OpenResty package repository.
Feedback is always welcome. Thanks a lot!