Skip to content

Instantly share code, notes, and snippets.

View zoghal's full-sized avatar
🏠
Working from home

Saleh Souzanchi zoghal

🏠
Working from home
View GitHub Profile
# Install dependencies
#
# * checkinstall: package the .deb
# * libpcre3, libpcre3-dev: required for HTTP rewrite module
# * zlib1g zlib1g-dbg zlib1g-dev: required for HTTP gzip module
apt-get install git checkinstall libpcre3 libpcre3-dev zlib1g zlib1g-dbg zlib1g-dev && \
mkdir -p ~/sources/ && \
# Compile against OpenSSL to enable NPN

Install dependencies

sudo apt-get install libpcre3-dev zlib1g-dev libgd2-xpm-dev libssl-dev

Configure and make

./configure \
--prefix=/usr/local/stow/nginx \
--conf-path=/etc/nginx/nginx.conf \

--sbin-path=/usr/sbin \

@zoghal
zoghal / tutorial.md
Last active August 29, 2015 14:17 — forked from dlsniper/tutorial.md
export LANGUAGE="en_US.UTF-8" 
export LANG="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"
locale-gen en_US.UTF-8 
dpkg-reconfigure locales

apt-get install unzip libpcre3 libpcre3-dev libssl-dev libpcrecpp0 zlib1g-dev debhelper dh-systemd libgeoip-dev autotools-dev libgd2-noxpm-dev libluajit-5.1-dev libmhash-dev libpam0g-dev libperl-dev po-debconf libexpat-dev
@zoghal
zoghal / tutorial.md
Last active August 29, 2015 14:17 — forked from dlsniper/tutorial.md
export LANGUAGE="en_US.UTF-8" 
export LANG="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"
locale-gen en_US.UTF-8 
dpkg-reconfigure locales

apt-get install unzip libpcre3 libpcre3-dev libssl-dev libpcrecpp0 zlib1g-dev debhelper dh-systemd libgeoip-dev autotools-dev libgd2-noxpm-dev libluajit-5.1-dev libmhash-dev libpam0g-dev libperl-dev po-debconf libexpat-dev
#!/usr/bin/env bash
# names of latest versions of each package
export NGINX_VERSION=1.7.10
export VERSION_NGINX=nginx-$NGINX_VERSION
export VERSION_LIBRESSL=libressl-2.1.4
export VERSION_PCRE=pcre-8.36
# URLs to the source directories
export SOURCE_NGINX=http://nginx.org/download/
#!/usr/bin/env bash
# names of latest versions of each package
export NGINX_VERSION=1.7.10
export VERSION_PCRE=pcre-8.36
export VERSION_LIBRESSL=libressl-2.1.3
export VERSION_NGINX=nginx-$NGINX_VERSION
# URLs to the source directories
export SOURCE_LIBRESSL=ftp://ftp.openbsd.org/pub/OpenBSD/LibreSSL/
#!/bin/bash
### build nginx as a static binary with most recent libraries.
### depends on sha256sum, tar and curl.
NGINX_VERSION="${NGINX_VERSION:-1.7.6}"
NGINX_SHA256="${NGINX_SHA256:-08e2efc169c9f9d511ce53ea16f17d8478ab9b0f7a653f212c03c61c52101599}"
NGINX_OPENRESTY_VERSION="${NGINX_OPENRESTY_VERSION:-1.7.7.1}"
NGINX_OPENRESTY_SHA256="${NGINX_OPENRESTY_SHA256:-e00b038945ca198eca7424026ccade0f8a5ad95b8aa40c5c2961684fc50ca4d4}"
#!/usr/bin/env bash
# names of latest versions of each package
export VERSION_PCRE=pcre-8.36
export VERSION_LIBRESSL=libressl-2.1.3
export VERSION_NGINX=nginx-1.7.10
export VERSION_NGINX=nginx-$NGINX_VERSION
# URLs to the source directories for each package
export SOURCE_LIBRESSL=ftp://ftp.openbsd.org/pub/OpenBSD/LibreSSL/
@zoghal
zoghal / nginx-update
Last active August 29, 2015 14:17 — forked from MikeWilkie/nginx-update
cd ~/git/nginx
rm -rf nginx-1*
rm -rf openssl-1*
wget https://www.openssl.org/source/openssl-1.0.1k.tar.gz
wget http://nginx.org/download/nginx-1.7.10.tar.gz
tar xzvf openssl* && rm -rf openssl-1.0.1k.tar.gz
tar -xzvf nginx-1*.tar.gz
rm -rf nginx-1*.tar.gz
cd echo-nginx-module && git pull && cd ../
cd headers-more-nginx-module && git pull && cd ../
#!/bin/bash
#
# Nginx build script - jacob@ycnrg.org
#
# Updates code from git/hg repos (or clones if it doesn't exist) for both
# nginx and extra modules, then fires off make
#
# Revision: 3
#
PREFIX="/usr"