Skip to content

Instantly share code, notes, and snippets.

@asamofal
Last active August 23, 2024 07:06
Show Gist options
  • Save asamofal/0c943192e1953dd3a0020a19e610dbc2 to your computer and use it in GitHub Desktop.
Save asamofal/0c943192e1953dd3a0020a19e610dbc2 to your computer and use it in GitHub Desktop.
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://nginx.org/keys/nginx_signing.key | sudo gpg --dearmor -o /etc/apt/keyrings/nginx.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/nginx.gpg] http://nginx.org/packages/ubuntu \
$(lsb_release -cs) nginx" | sudo tee /etc/apt/sources.list.d/nginx.list > /dev/null
sudo apt update
sudo apt install nginx
nginx -v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment