diff --git a/cookbooks/blog/nginx.rb b/cookbooks/blog/nginx.rb index 96004e0..3f0d40c 100644 --- a/cookbooks/blog/nginx.rb +++ b/cookbooks/blog/nginx.rb @@ -15,7 +15,7 @@ file '/etc/fstab' do not_if 'grep /var/www/blog /etc/fstab' - notifies :run, 'execute[fstab -a]' + notifies :run, 'execute[mount -a]' end execute 'mount -a' do @@ -41,3 +41,9 @@ service 'monit' do action :nothing end +# Create storage directory for blog data +directory '/home/webadm/works/public' do + owner 'webadm' + group 'webadm' + mode '775' +end diff --git a/cookbooks/nginx/default.rb b/cookbooks/nginx/default.rb index 8529d93..e38c4f9 100644 --- a/cookbooks/nginx/default.rb +++ b/cookbooks/nginx/default.rb @@ -4,6 +4,9 @@ include_recipe './attributes.rb' # Kernel Parameters: include_recipe './kernel.rb' +# Install Let's Encrypt: +include_recipe './lego.rb' + # Prerequisites for Building nginx: include_recipe './webadm.rb' @@ -12,6 +15,3 @@ include_recipe './build.rb' # Setup nginx: include_recipe './setup.rb' - -# Install Let's Encrypt: -include_recipe './lego.rb' diff --git a/cookbooks/nginx/files/etc/sysctl.d/90-nginx.conf b/cookbooks/nginx/files/etc/sysctl.d/90-nginx.conf index f95e580..a38de3a 100644 --- a/cookbooks/nginx/files/etc/sysctl.d/90-nginx.conf +++ b/cookbooks/nginx/files/etc/sysctl.d/90-nginx.conf @@ -1,7 +1,6 @@ net.core.somaxconn=32768 net.core.netdev_max_backlog=32768 net.ipv4.tcp_max_syn_backlog=32768 -net.ipv4.tcp_tw_recycle=1 net.ipv4.tcp_tw_reuse=1 net.ipv4.tcp_fin_timeout=10 net.core.rmem_max = 16777216