Switch back to the upstream nginx cookbook

chef_nginx is deprecated
This commit is contained in:
Greg Karékinian
2019-03-14 10:35:11 +01:00
parent e20ad9e6f9
commit fc265014de
122 changed files with 565 additions and 617 deletions

View File

@@ -0,0 +1,23 @@
#
# Cookbook:: nginx
# Attributes:: auth_request
#
# Author:: David Radcliffe (<radcliffe.david@gmail.com>)
#
# Copyright:: 2013-2017, David Radcliffe
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['auth_request']['url'] = 'http://mdounin.ru/hg/ngx_http_auth_request_module/archive/662785733552.tar.gz'
default['nginx']['auth_request']['checksum'] = '2057bdefd2137a5000d9dbdbfca049d1ba7832ad2b9f8855a88ea5dfa70bd8c1'

View File

@@ -0,0 +1,134 @@
#
# Cookbook:: nginx
# Attributes:: default
#
# Author:: Adam Jacob (<adam@chef.io>)
# Author:: Joshua Timberman (<joshua@chef.io>)
#
# Copyright:: 2009-2017, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# In order to update the version, the checksum attribute must be changed too.
# This attribute is defined in the source.rb attribute file
default['nginx']['version'] = '1.12.1'
default['nginx']['package_name'] = 'nginx'
default['nginx']['port'] = '80'
default['nginx']['dir'] = '/etc/nginx'
default['nginx']['script_dir'] = '/usr/sbin'
default['nginx']['log_dir'] = '/var/log/nginx'
default['nginx']['log_dir_perm'] = '0750'
default['nginx']['binary'] = '/usr/sbin/nginx'
default['nginx']['default_root'] = '/var/www/nginx-default'
default['nginx']['ulimit'] = '1024'
# cleanup runit install of previous cookbooks
default['nginx']['cleanup_runit'] = true
# use the upstream nginx repo vs. distro packages
# this enables the use of modern nginx releases
# set this to nil to use the distro packages
# this is ignored if install_method is set to source
default['nginx']['repo_source'] = 'nginx'
default['nginx']['install_method'] = 'package'
case node['platform_family']
when 'rhel', 'fedora', 'amazon'
default['nginx']['user'] = 'nginx'
when 'freebsd'
default['nginx']['package_name'] = 'www/nginx'
default['nginx']['user'] = 'www'
default['nginx']['dir'] = '/usr/local/etc/nginx'
default['nginx']['script_dir'] = '/usr/local/sbin'
default['nginx']['binary'] = '/usr/local/sbin/nginx'
default['nginx']['default_root'] = '/usr/local/www/nginx-dist'
when 'suse'
default['nginx']['user'] = 'wwwrun'
default['nginx']['group'] = 'www'
else # debian probably
default['nginx']['user'] = 'www-data'
end
default['nginx']['user_home'] = '/var/www'
default['nginx']['upstart']['runlevels'] = '2345'
default['nginx']['upstart']['respawn_limit'] = nil
default['nginx']['upstart']['foreground'] = true
default['nginx']['group'] = node['nginx']['group'] || node['nginx']['user']
default['nginx']['gzip'] = 'on'
default['nginx']['gzip_static'] = 'off'
default['nginx']['gzip_http_version'] = '1.0'
default['nginx']['gzip_comp_level'] = '2'
default['nginx']['gzip_proxied'] = 'any'
default['nginx']['gzip_vary'] = 'off'
default['nginx']['gzip_buffers'] = nil
default['nginx']['gzip_types'] = %w(
text/plain
text/css
application/x-javascript
text/xml
application/xml
application/rss+xml
application/atom+xml
image/svg+xml
text/javascript
application/javascript
application/json
text/mathml
)
default['nginx']['gzip_min_length'] = 1_000
default['nginx']['gzip_disable'] = 'MSIE [1-6]\.'
default['nginx']['keepalive'] = 'on'
default['nginx']['keepalive_requests'] = 100
default['nginx']['keepalive_timeout'] = 65
default['nginx']['worker_processes'] = node['cpu'] && node['cpu']['total'] ? node['cpu']['total'] : 1
default['nginx']['worker_connections'] = 1_024
default['nginx']['worker_rlimit_nofile'] = nil
default['nginx']['multi_accept'] = false
default['nginx']['event'] = nil
default['nginx']['accept_mutex_delay'] = nil
default['nginx']['server_tokens'] = nil
default['nginx']['server_names_hash_bucket_size'] = 64
default['nginx']['variables_hash_max_size'] = 1024
default['nginx']['variables_hash_bucket_size'] = 64
default['nginx']['sendfile'] = 'on'
default['nginx']['underscores_in_headers'] = nil
default['nginx']['tcp_nodelay'] = 'on'
default['nginx']['tcp_nopush'] = 'on'
default['nginx']['access_log_options'] = nil
default['nginx']['error_log_options'] = nil
default['nginx']['disable_access_log'] = false
default['nginx']['log_formats'] = {}
default['nginx']['default_site_enabled'] = true
default['nginx']['types_hash_max_size'] = 2_048
default['nginx']['types_hash_bucket_size'] = 64
default['nginx']['proxy_read_timeout'] = nil
default['nginx']['client_body_buffer_size'] = nil
default['nginx']['client_max_body_size'] = nil
default['nginx']['large_client_header_buffers'] = nil
default['nginx']['map_hash_max_size'] = nil
default['nginx']['proxy_buffer_size'] = nil
default['nginx']['proxy_buffers'] = nil
default['nginx']['proxy_busy_buffers_size'] = nil
default['nginx']['default']['modules'] = []
default['nginx']['extra_configs'] = {}
default['nginx']['ohai_plugin_enabled'] = true
default['nginx']['load_modules'] = []

View File

@@ -0,0 +1,24 @@
#
# Cookbook:: nginx
# Attributes:: devel
#
# Author:: Arthur Freyman (<afreyman@riotgames.com>)
#
# Copyright:: 2013-2017, Riot Games
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['devel']['version'] = '0.3.0'
default['nginx']['devel']['url'] = "https://github.com/simpl/ngx_devel_kit/archive/v#{node['nginx']['devel']['version']}.tar.gz"
default['nginx']['devel']['checksum'] = '88e05a99a8a7419066f5ae75966fb1efc409bad4522d14986da074554ae61619'

View File

@@ -0,0 +1,24 @@
#
# Cookbook:: nginx
# Attributes:: echo
#
# Author:: Danial Pearce (<github@tigris.id.au>)
#
# Copyright:: 2013-2017, Danial Pearce
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['echo']['version'] = '0.61'
default['nginx']['echo']['url'] = "https://github.com/openresty/echo-nginx-module/archive/v#{node['nginx']['echo']['version']}.tar.gz"
default['nginx']['echo']['checksum'] = '2e6a03032555f5da1bdff2ae96c96486f447da3da37c117e0f964ae0753d22aa'

View File

@@ -0,0 +1,35 @@
#
# Cookbook:: nginx
# Attributes:: geoip
#
# Author:: Jamie Winsor (<jamie@vialstudios.com>)
#
# Copyright:: 2012-2017, Riot Games
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# NOTE: The GeoIP database checksums are nil by default as these files change
# continuously and are not versioned.
# If you self host these files you should create a checksum and set these attributes
default['nginx']['geoip']['path'] = '/srv/geoip'
default['nginx']['geoip']['enable_city'] = true
default['nginx']['geoip']['country_dat_url'] = 'http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz'
default['nginx']['geoip']['country_dat_checksum'] = nil
default['nginx']['geoip']['city_dat_url'] = 'http://geolite.maxmind.com/download/geoip/database/GeoLiteCity.dat.gz'
default['nginx']['geoip']['city_dat_checksum'] = nil
default['nginx']['geoip']['lib_version'] = '1.6.9'
lib_version = node['nginx']['geoip']['lib_version'] # convenience variable for line length
default['nginx']['geoip']['lib_url'] = "https://github.com/maxmind/geoip-api-c/releases/download/v#{lib_version}/GeoIP-#{lib_version}.tar.gz"
default['nginx']['geoip']['lib_checksum'] = '4b446491843de67c1af9b887da17a3e5939e0aeed4826923a5f4bf09d845096f'

View File

@@ -0,0 +1,24 @@
#
# Cookbook:: nginx
# Attributes:: headers_more
#
# Author:: Lucas Jandrew (<ljandrew@riotgames.com>)
#
# Copyright:: 2012-2017, Riot Games
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['headers_more']['version'] = '0.30'
default['nginx']['headers_more']['source_url'] = "https://github.com/openresty/headers-more-nginx-module/archive/v#{node['nginx']['headers_more']['version']}.tar.gz"
default['nginx']['headers_more']['source_checksum'] = '2aad309a9313c21c7c06ee4e71a39c99d4d829e31c8b3e7d76f8c964ea8047f5'

View File

@@ -0,0 +1,28 @@
#
# Cookbook:: nginx
# Attributes:: lua
#
# Author:: Arthur Freyman (<afreyman@riotgames.com>)
#
# Copyright:: 2013-2017, Riot Games
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['lua']['version'] = '0.10.10'
default['nginx']['lua']['url'] = "https://github.com/chaoslawful/lua-nginx-module/archive/v#{node['nginx']['lua']['version']}.tar.gz"
default['nginx']['lua']['checksum'] = 'b4acb84e2d631035a516d61830c910ef6e6485aba86096221ec745e0dbb3fbc9'
default['nginx']['luajit']['version'] = '2.0.4'
default['nginx']['luajit']['url'] = "http://luajit.org/download/LuaJIT-#{node['nginx']['luajit']['version']}.tar.gz"
default['nginx']['luajit']['checksum'] = '620fa4eb12375021bef6e4f237cbd2dd5d49e56beb414bee052c746beef1807d'

View File

@@ -0,0 +1,24 @@
#
# Cookbook:: nginx
# Attributes:: naxsi
#
# Author:: Artiom Lunev (<artiom.lunev@gmail.com>)
#
# Copyright:: 2012-2017, Artiom Lunev
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['naxsi']['version'] = '0.54'
default['nginx']['naxsi']['url'] = "https://github.com/nbs-system/naxsi/archive/#{node['nginx']['naxsi']['version']}.tar.gz"
default['nginx']['naxsi']['checksum'] = '9cc2c09405bc71f78ef26a8b6d70afcea3fccbe8125df70cb0cfc480133daba5'

View File

@@ -0,0 +1,23 @@
#
# Cookbook:: nginx
# Attributes:: openssl_source
#
# Author:: David Radcliffe (<radcliffe.david@gmail.com>)
#
# Copyright:: 2013-2017, David Radcliffe
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['openssl_source']['version'] = '1.0.2k'
default['nginx']['openssl_source']['url'] = "http://www.openssl.org/source/openssl-#{node['nginx']['openssl_source']['version']}.tar.gz"

View File

@@ -0,0 +1,9 @@
#
# Cookbook:: nginx
# Recipe:: pagespeed_module
#
default['nginx']['pagespeed']['version'] = '1.11.33.2'
default['nginx']['pagespeed']['url'] = "https://github.com/pagespeed/ngx_pagespeed/archive/release-#{node['nginx']['pagespeed']['version']}-beta.tar.gz"
default['nginx']['psol']['url'] = "https://dl.google.com/dl/page-speed/psol/#{node['nginx']['pagespeed']['version']}.tar.gz"
default['nginx']['pagespeed']['packages']['rhel'] = %w(pcre-devel zlib-devel)
default['nginx']['pagespeed']['packages']['debian'] = %w(zlib1g-dev libpcre3 libpcre3-dev)

View File

@@ -0,0 +1,74 @@
#
# Cookbook:: nginx
# Attribute:: passenger
#
# Author:: Alex Dergachev (<alex@evolvingweb.ca>)
#
# Copyright:: 2013-2017, Chef Software, Inc.
# Copyright:: 2012-2017, Susan Potter
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
ubuntu_18 = platform?('ubuntu') && node['platform_version'].to_i >= 18
# this is only used for source installs
# for package installs you will receive the latest version in the repository
node.default['nginx']['passenger']['version'] = '4.0.57'
if node['nginx']['repo_source'] == 'passenger'
node.default['nginx']['passenger']['root'] = '/usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini'
node.default['nginx']['passenger']['ruby'] = '/usr/bin/ruby'
elsif node['languages'].attribute?('ruby')
node.default['nginx']['passenger']['root'] = "#{node['languages']['ruby']['gems_dir']}/gems/passenger-#{node['nginx']['passenger']['version']}"
node.default['nginx']['passenger']['ruby'] = node['languages']['ruby']['ruby_bin']
else
Chef::Log.warn("node['languages']['ruby'] attribute not detected in #{cookbook_name}::#{recipe_name}")
Chef::Log.warn("Install a Ruby for automatic detection of node['nginx']['passenger'] attributes (root, ruby)")
Chef::Log.warn('Using default values that may or may not work for this system.')
node.default['nginx']['passenger']['root'] = "/usr/lib/ruby/gems/1.8/gems/passenger-#{node['nginx']['passenger']['version']}"
node.default['nginx']['passenger']['ruby'] = '/usr/bin/ruby'
end
node.default['nginx']['passenger']['conf_file'] = if ubuntu_18
"#{node['nginx']['dir']}/conf.d/mod-http-passenger.conf"
else
"#{node['nginx']['dir']}/conf.d/passenger.conf"
end
node.default['nginx']['passenger']['packages']['rhel'] = if platform_family?('rhel') && node['platform_version'].to_i >= 6
%w(ruby-devel libcurl-devel)
else
%w(ruby-devel curl-devel)
end
node.default['nginx']['passenger']['packages']['fedora'] = %w(ruby-devel libcurl-devel)
node.default['nginx']['passenger']['packages']['debian'] = if ubuntu_18
%w(ruby-dev libcurl4-gnutls-dev libnginx-mod-http-passenger)
else
%w(ruby-dev libcurl4-gnutls-dev)
end
node.default['nginx']['passenger']['install_rake'] = true
node.default['nginx']['passenger']['spawn_method'] = 'smart-lv2'
node.default['nginx']['passenger']['buffer_response'] = 'on'
node.default['nginx']['passenger']['max_pool_size'] = 6
node.default['nginx']['passenger']['min_instances'] = 1
node.default['nginx']['passenger']['max_instances_per_app'] = 0
node.default['nginx']['passenger']['pool_idle_time'] = 300
node.default['nginx']['passenger']['max_requests'] = 0
node.default['nginx']['passenger']['gem_binary'] = nil
node.default['nginx']['passenger']['show_version_in_header'] = 'on'
# By default, the Passenger log file is the global Nginx error log file. Set this attribute to write passenger log to another location.
node.default['nginx']['passenger']['passenger_log_file'] = nil
# NodeJs disable by default
node.default['nginx']['passenger']['nodejs'] = nil

View File

@@ -0,0 +1,23 @@
#
# Cookbook:: nginx
# Attribute:: rate_limiting
#
# Copyright:: 2013-2017, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['enable_rate_limiting'] = false
default['nginx']['rate_limiting_zone_name'] = 'default'
default['nginx']['rate_limiting_backoff'] = '10m'
default['nginx']['rate_limit'] = '1r/s'

View File

@@ -0,0 +1,40 @@
#
# Cookbook:: nginx
# Recipe:: repo
#
# Author:: Nick Rycar <nrycar@bluebox.net>
#
# Copyright:: 2008-2017, Chef Software, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['upstream_repository'] =
case node['platform_family']
when 'rhel', 'fedora', 'amazon'
case node['platform']
when 'centos'
# See http://wiki.nginx.org/Install
"https://nginx.org/packages/centos/#{node['platform_version'].to_i}/$basearch/"
when 'amazon' # Chef < 13 on Amazon
'https://nginx.org/packages/rhel/6/$basearch/'
else
"https://nginx.org/packages/rhel/#{node['platform_version'].to_i}/$basearch/"
end
when 'debian'
"https://nginx.org/packages/#{node['platform']}"
when 'suse'
'https://nginx.org/packages/sles/12'
end
default['nginx']['repo_signing_key'] = 'https://nginx.org/keys/nginx_signing.key'

View File

@@ -0,0 +1,8 @@
#
# Cookbook:: nginx
# Attributes:: set_misc
#
default['nginx']['set_misc']['version'] = '0.30'
default['nginx']['set_misc']['url'] = "https://github.com/agentzh/set-misc-nginx-module/archive/v#{node['nginx']['set_misc']['version']}.tar.gz"
default['nginx']['set_misc']['checksum'] = '59920dd3f92c2be32627121605751b52eae32b5884be09f2e4c53fb2fae8aabc'

View File

@@ -0,0 +1,18 @@
#
# Cookbook:: nginx
# Attributes:: socketproxy.rb
#
default['nginx']['socketproxy']['root'] = '/usr/share/nginx/apps'
default['nginx']['socketproxy']['app_owner'] = 'root'
default['nginx']['socketproxy']['logname'] = 'socketproxy'
default['nginx']['socketproxy']['log_level'] = 'error'
# default['nginx']['socketproxy']['default_app'] = 'default'
# default['nginx']['socketproxy']['apps'] = {
# 'default' => {
# 'prepend_slash' => false,
# 'context_name' => '',
# 'subdir' => 'current',
# 'socket_path' => 'shared/sockets/unicorn.sock'
# }
# }

View File

@@ -0,0 +1,52 @@
#
# Cookbook:: nginx
# Attributes:: source
#
# Author:: Jamie Winsor (<jamie@vialstudios.com>)
#
# Copyright:: 2012-2017, Riot Games
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
include_attribute 'nginx::default'
default['nginx']['init_style'] = if node['platform'] == 'ubuntu' && node['platform_version'].to_f <= 14.04
# init_package identifies 12.04/14.04 as init, but we should be using upstart here
'upstart'
else
node['init_package']
end
default['nginx']['source']['version'] = node['nginx']['version']
default['nginx']['source']['prefix'] = "/opt/nginx-#{node['nginx']['source']['version']}"
default['nginx']['source']['conf_path'] = "#{node['nginx']['dir']}/nginx.conf"
default['nginx']['source']['sbin_path'] = "#{node['nginx']['source']['prefix']}/sbin/nginx"
# Wno-error can be removed when nginx compiles on GCC7: https://trac.nginx.org/nginx/ticket/1259
default['nginx']['source']['default_configure_flags'] = %W(
--prefix=#{node['nginx']['source']['prefix']}
--conf-path=#{node['nginx']['dir']}/nginx.conf
--sbin-path=#{node['nginx']['source']['sbin_path']}
--with-cc-opt=-Wno-error
)
default['nginx']['configure_flags'] = []
default['nginx']['source']['version'] = node['nginx']['version']
default['nginx']['source']['url'] = "http://nginx.org/download/nginx-#{node['nginx']['source']['version']}.tar.gz"
default['nginx']['source']['checksum'] = '8793bf426485a30f91021b6b945a9fd8a84d87d17b566562c3797aba8fac76fb'
default['nginx']['source']['modules'] = %w(
nginx::http_ssl_module
nginx::http_gzip_static_module
)
default['nginx']['source']['use_existing_user'] = false

View File

@@ -0,0 +1,22 @@
#
# Cookbook:: nginx
# Attributes:: status
#
# Author:: David Radcliffe (<radcliffe.david@gmail.com>)
#
# Copyright:: 2013-2017, David Radcliffe
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['status']['port'] = '8090'

View File

@@ -0,0 +1,23 @@
#
# Cookbook:: nginx
# Attributes:: syslog
#
# Author:: Bob Ziuchkovski (<bob@bz-technology.com>)
#
# Copyright:: 2014-2017, UserTesting
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['syslog']['git_repo'] = 'https://github.com/yaoweibin/nginx_syslog_patch.git'
default['nginx']['syslog']['git_revision'] = 'master'

View File

@@ -0,0 +1,26 @@
#
# Cookbook:: nginx
# Attributes:: upload_progress
#
# Author:: Jamie Winsor (<jamie@vialstudios.com>)
#
# Copyright:: 2012-2017, Riot Games
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
default['nginx']['upload_progress']['url'] = 'https://github.com/masterzen/nginx-upload-progress-module/tarball/v0.9.0'
default['nginx']['upload_progress']['checksum'] = '3fb903dab595cf6656fa0fc5743a48daffbba2f6b5c554836be630800eaad4e2'
default['nginx']['upload_progress']['javascript_output'] = true
default['nginx']['upload_progress']['zone_name'] = 'proxied'
default['nginx']['upload_progress']['zone_size'] = '1m'