Skip to content

Commit

Permalink
Add GeoIP2, Remove GeoIP.
Browse files Browse the repository at this point in the history
  • Loading branch information
hakasenyang committed Sep 21, 2018
1 parent 6c52bec commit 2087659
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
Example Web Server - [https://ssl.hakase.io/](https://ssl.hakase.io/)

## Please install dependency library.
- CentOS / Red Hat - `yum install jemalloc-devel libuuid-devel libatomic libatomic_ops-devel expat-devel unzip autoconf automake libtool gd-devel geoip-devel gcc-c++ curl`
- Ubuntu / Debian - `apt install libjemalloc-dev uuid-dev libatomic1 libatomic-ops-dev expat unzip autoconf automake libtool libgd-dev libgeoip-dev g++ curl`
- CentOS / Red Hat - `yum install jemalloc-devel libuuid-devel libatomic libatomic_ops-devel expat-devel unzip autoconf automake libtool gd-devel libmaxminddb-dev gcc-c++ curl`
- Ubuntu / Debian - `apt install libjemalloc-dev uuid-dev libatomic1 libatomic-ops-dev expat unzip autoconf automake libtool libgd-dev libmaxminddb-dev g++ curl`

## How to Install?
1. Clone this repository - `git clone https://github.com/hakasenyang/nginx-build.git --recursive`
Expand Down Expand Up @@ -42,10 +42,13 @@ Example Web Server - [https://ssl.hakase.io/](https://ssl.hakase.io/)
- Strict SNI requires at least two ssl server settings (server { listen 443 ssl }).
- It does not matter what kind of certificate or duplicate.
- Use "strict_sni_header on" if you do not want to respond to invalid headers. (only with strict_sni)
- GeoIP2 Module [#2](https://github.com/hakasenyang/nginx-build/issues/2)
- [Check the following page](https://github.com/leev/ngx_http_geoip2_module) for GeoIP2 settings method.

## Upcoming Features
- Auto build (rpm, deb, etc.)
- ETC.

## Deprecated Features
- SPDY (Not compatible this version.)
- GeoIP (Changed to GeoIP2.)
3 changes: 1 addition & 2 deletions auto.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ if [ "$RTMP" = 1 ]; then BUILD_MODULES="${BUILD_MODULES} --add-module=./lib/ngin
if [ "$NAXSI" = 1 ]; then BUILD_MODULES="${BUILD_MODULES} --add-module=./lib/naxsi/naxsi_src"; fi
if [ "$DAV_EXT" = 1 ]; then BUILD_MODULES="${BUILD_MODULES} --add-module=./lib/nginx-dav-ext-module"; fi
if [ "$FANCYINDEX" = 1 ]; then BUILD_MODULES="${BUILD_MODULES} --add-module=./lib/ngx-fancyindex"; fi
if [ "$GEOIP2" = 1 ]; then BUILD_MODULES="${BUILD_MODULES} --add-module=./lib/ngx_http_geoip2_module"; fi

auto/configure \
--with-cc-opt="-DTCP_FASTOPEN=23 ${BUILD_BIT}${BUILD_LTO} -g -O3 -march=native -fstack-protector-strong -fuse-ld=gold -fuse-linker-plugin --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wno-strict-aliasing -Wp,-D_FORTIFY_SOURCE=2 -gsplit-dwarf -DNGX_HTTP_HEADERS" \
Expand Down Expand Up @@ -122,7 +123,6 @@ auto/configure \
--with-http_stub_status_module \
--with-http_flv_module \
--with-http_mp4_module \
--with-http_geoip_module \
--with-http_gunzip_module \
--with-http_slice_module \
--with-http_gzip_static_module \
Expand All @@ -142,7 +142,6 @@ auto/configure \
--with-http_v2_module \
--with-http_v2_hpack_enc \
--with-stream_ssl_module \
--with-stream_geoip_module \
--with-stream_realip_module \
--with-stream_ssl_preread_module \
--add-module=./lib/ngx_devel_kit \
Expand Down
3 changes: 3 additions & 0 deletions config.inc.example
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ DAV_EXT=1
### fancyindex
FANCYINDEX=1

### GEOIP2
GEOIP2=1

##########################
### nginx install path ###
##########################
Expand Down

0 comments on commit 2087659

Please sign in to comment.