Created
January 14, 2015 18:10
-
-
Save jorgecarleitao/d4c9cd3f87727255cc16 to your computer and use it in GitHub Desktop.
Installs nginx in a local directory (e.g. for webfaction)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# prepare | |
VERSION=$1 | |
DIRECTORY=$2 | |
# download | |
curl -O http://nginx.org/download/nginx-$VERSION.tar.gz | |
# extract | |
tar -xzf nginx-$VERSION.tar.gz | |
# configure, compile, and install | |
cd nginx-$VERSION | |
./configure --prefix=$DIRECTORY && make && make install | |
# clean | |
cd .. | |
rm -rf nginx-$VERSION* |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment