Skip to content

Instantly share code, notes, and snippets.

@instaBOT
Created September 23, 2015 14:46
Show Gist options
  • Save instaBOT/7cd533ebc6d468c50591 to your computer and use it in GitHub Desktop.
Save instaBOT/7cd533ebc6d468c50591 to your computer and use it in GitHub Desktop.
install latest stable Nginx from external PPA repo. It also installs some additional useful and popular packages (ssl-cert, openssl-blacklist, openssl-blacklist-extra)
#!/usr/bin/env bash
cd
set -e
###############################################################################
# APT repos
###############################################################################
sudo add-apt-repository --yes ppa:nginx/stable
sudo apt-get update
sudo apt-get upgrade --yes
###############################################################################
# install packages
###############################################################################
# optional but very useful
sudo apt-get install --yes \
ssl-cert \
openssl-blacklist \
openssl-blacklist-extra \
# required
sudo apt-get install --yes nginx
# stop services just installed (they are not configured yet)
sudo service nginx stop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment