cookbook 'thumbor_ng', '~> 0.4.2'
thumbor_ng (15) Versions 0.4.2 Follow0
Installs/Configures Thumbor
cookbook 'thumbor_ng', '~> 0.4.2', :supermarket
knife supermarket install thumbor_ng
knife supermarket download thumbor_ng
thumbor_ng Cookbook
This is a Chef Cookbook to Install and Configure Thumbor.
This cookbook was heavily inspired from thumbor cookbook maintained by Zanui.
For Production environment, always prefer the most recent release.
Repository
https://github.com/vkhatri/chef-thumbor-ng
Supported OS
Currently cookbook only supports Ubuntu 12.04 & 14.04.
Supported Install Methods
This cookbook only supports pip
based installation. As mentioned in Thumbor wiki, new release is
always available via pip
. Other install methods like source code
or package
are not
incorporated in this cookbook.
Major Changes
v0.4.0
Redis setup is not in the scope of this cookbook and hence redisio
cookbook
dependency has been removed.
Recipes
thumbor_ng::default
- default cookbook run_list recipethumbor_ng::install
- install packages required for thumborthumbor_ng::user
- setup user for thumbor servicethumbor_ng::config
- setup and mange thumbor configurationthumbor_ng::monit
- setup monit checks for nginx/thumbor using cookbookmonit-ng
thumbor_ng::nginx
- setup and manage frontend proxy nginx for thumbor using cookbooknginx
<del>
thumbor_ng::haproxy
- setup and mange fronend proxy haproxy for thumbor, not completed yet </del><del>
thumbor_ng::varnish
- setup and mange fronend proxy varnish for thumbor, not completed yet </del>
For run_list use
recipe[thumbor_ng::default]
orrecipe[thumbor_ng]
Cookbook Advanced Attributes
default['thumbor_ng']['proxy']
(default:nginx
): thumbor service front end proxy, currently only supports nginxdefault['thumbor_ng']['storage']['type']
(default:file
): thumbor storage typedefault['thumbor_ng']['init_style']
(default:upstart
): thumbor service manager, options: initd upstartdefault['thumbor_ng']['notify_restart']
(default:true
): notify thumbor service on a resource changedefault['thumbor_ng']['setup_user']
(default:true
): setup user for thumbor servicedefault['thumbor_ng']['monit']['enable']
(default:false
): enables monit checks for nginx and thumbor service using cookbook -monit-ng
<del>
default['thumbor_ng']['queue']['type']
(default:redis
): thumbor detector queue type, option complete setup not tested yet </del>
Cookbook Core Attributes
default['thumbor_ng']['version']
(default:6.1.5
): Thumbor release versiondefault['thumbor_ng']['workers']
(default:node['cpu']['total']
): # of thumbor processes, default utilizes all CPU coresdefault['thumbor_ng']['base_port']
(default:9000
): thumbor service base port to spawn multiple processesdefault['thumbor_ng']['key']
(default: ``): thumbor secret key file content<del>
default['thumbor_ng']['log_dir']
(default:/var/log/thumbor
): thumbor logs directory, not yet tested </del>default['thumbor_ng']['service_name']
(default:thumbor
): thumbor service namedefault['thumbor_ng']['install_method']
(default:pip
): thumbor install methoddefault['thumbor_ng']['listen_address']
(default:127.0.0.1
): inet for thumbor service, change it with cautiondefault['thumbor_ng']['binary']
(default:/usr/local/bin/thumbor
): thumbor binary location for thumbor servicedefault['thumbor_ng']['upstart_respawn']
(default:true
): respawn service if goes downdefault['thumbor_ng']['conf_file']
(default:/etc/thumbor.conf
): thumbor configuration filedefault['thumbor_ng']['key_file']
(default:/etc/thumbor.key
): thumbor key filedefault['thumbor_ng']['group']
(default:thumbor
): thumbor service groupdefault['thumbor_ng']['user']
(default:thumbor
): thumbor service userdefault['thumbor_ng']['user_home']
(default:nil
): thumbor service user home directorydefault['thumbor_ng']['pip_dependencies']
(default:['remotecv', 'graphicsmagick-engine', 'opencv-engine']
): thumbor pip dependencies, user may add custom pip packages
Cookbook apt Repositories Attributes
default['thumbor_ng']['apt']['thumbor']['uri']
(default:http://ppa.launchpad.net/thumbor/ppa/ubuntu
): repo uridefault['thumbor_ng']['apt']['thumbor']['distribution']
(default:node['lsb']['codename']
): repo distributiondefault['thumbor_ng']['apt']['thumbor']['keyserver']
(default:keyserver.ubuntu.com
): repo keyserverdefault['thumbor_ng']['apt']['thumbor']['components']
(default:[main]
): repo componentsdefault['thumbor_ng']['apt']['thumbor']['key']
(default:68DFB11CCBEC8F27
): repo keydefault['thumbor_ng']['apt']['thumbor']['deb_src']
(default:false
): whether to fetch sourcedefault['thumbor_ng']['apt']['thumbor']['action']
(default:add
): apt_repository resource actiondefault['thumbor_ng']['apt']['multiverse']['uri']
(default:http://archive.ubuntu.com/ubuntu
): repo uridefault['thumbor_ng']['apt']['multiverse']['distribution']
(default:node['lsb']['codename']
): repo distributiondefault['thumbor_ng']['apt']['multiverse']['keyserver']
(default:keyserver.ubuntu.com
): repo keyserverdefault['thumbor_ng']['apt']['multiverse']['components']
(default:[main multiverse restricted universe]
): repo componentsdefault['thumbor_ng']['apt']['multiverse']['key']
(default:40976EAF437D05B5
): repo keydefault['thumbor_ng']['apt']['multiverse']['deb_src']
(default:false
): whether to fetch sourcedefault['thumbor_ng']['apt']['multiverse']['action']
(default:add
): apt_repository resource action
Cookbook thumbor Service Ulimit Attributes
default['thumbor_ng']['limits']['memlock']
(default:unlimited
): thumbor service memory limitdefault['thumbor_ng']['limits']['nofile']
(default:48000
): thumbor service file limitdefault['thumbor_ng']['limits']['nproc']
(default:unlimited
): thumbor service proc limit
Cookbook nginx Attributes
default['nginx']['default_site_enabled']
(default:false
): disable default nginx sitedefault['nginx']['worker_connections']
(default:4096
): nginx worker connectionsdefault['thumbor_ng']['nginx']['port']
(default:80
): nginx portdefault['thumbor_ng']['nginx']['server_name']
(default:node['fqdn']
): nginx thumbor vhost server namedefault['thumbor_ng']['nginx']['client_max_body_size']
(default:10M
): nginx thumbor vhost client max bodydefault['thumbor_ng']['nginx']['proxy_read_timeout']
(default:300
): nginx thumbor vhost proxy read timeoutdefault['thumbor_ng']['nginx']['proxy_cache']['enabled']
(default:false
): enable proxy cache in nginx thumbor vhostdefault['thumbor_ng']['nginx']['proxy_cache']['path']
(default:/var/www/thumbor_cache
): nginx thumbor vhost proxy cache locationdefault['thumbor_ng']['nginx']['proxy_cache']['key_zone']
(default:thumbor_cache
): nginx thumbor vhost proxy cache key zonedefault['thumbor_ng']['nginx']['vhost']['cookbook']
(default:thumbor_ng
): nginx thumbor vhost template cookbook namedefault['thumbor_ng']['nginx']['vhost']['template']
(default:nginx.thumbor.vhost.erb
): nginx thumbor vhost template namedefault['thumbor_ng']['nginx']['vhost']['variables']
(default:{}
): nginx thumbor vhost template variablesdefault['thumbor_ng']['nginx']['enable_status']
(default:false ): enable nginx
/nginx_status`
For more nginx attributes, check out nginx cookbook
Cookbook monit Attributes
Monit checks for thumbor
and nginx
(or haproxy
or varnish
).
For more monit checks attributes & configuration, check out monit-ng cookbook
Cookbook thumbor Default Configuration Attributes
default['thumbor_ng']['options']['FILE_STORAGE_ROOT_PATH']
(default:/var/lib/thumbor/file_storage
): thumbor file storage locationdefault['thumbor_ng']['options']['RESULT_STORAGE_FILE_STORAGE_ROOT_PATH']
(default:/var/lib/thumbor/result_storage
): thumbor result file storage location
Cookbook thumbor File Storage Purge Cron Attributes
default['thumbor_ng']['cron']['minute']
(default:0
): cron attributedefault['thumbor_ng']['cron']['hour']
(default:03
): cron attributedefault['thumbor_ng']['cron']['day']
(default:*
): cron attributedefault['thumbor_ng']['cron']['month']
(default:*
): cron attributedefault['thumbor_ng']['cron']['user']
(default:root
): cron attributedefault['thumbor_ng']['cron']['path']
(default:nil
): cron attributedefault['thumbor_ng']['cron']['shell']
(default:nil
): cron attributedefault['thumbor_ng']['cron']['mailto']
(default:nil
): cron attributedefault['thumbor_ng']['cron']['home']
(default:nil
): cron attributedefault['thumbor_ng']['cron']['action']
(default::delete
): disable by default
Cookbook Dependencies
apt
python
nginx
ulimit
monit-ng
TODO
- Add support for RHEL platform family
- Add HAProxy frontend proxy
- Add Varnish frontend proxy
Contributing
- Fork the repository on Github
- Create a named feature branch (like
add_component_x
) - Write your change
- Write tests for your change (if applicable)
- Run the tests (
rake
), ensuring they all pass - Write new resource/attribute description to
README.md
- Write description about changes to PR
- Submit a Pull Request using Github
Copyright & License
Authors:: Virender Khatri and Contributors
<pre>
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.
</pre>
Dependent cookbooks
apt >= 0.0.0 |
python >= 0.0.0 |
nginx >= 0.0.0 |
ulimit >= 0.0.0 |
monit-ng >= 0.0.0 |
cron >= 1.2.0 |
Contingent cookbooks
There are no cookbooks that are contingent upon this one.
thumbor_ng CHANGELOG
This file is used to list changes made in each version of the thumbor_ng cookbook.
0.4.3
Virender Khatri - bump thumbor version to 6.1.5
Virender Khatri - fix rubocop
Virender Khatri - add issue_url and source_url
0.4.1
- Virender Khatri - bump thumbor version to 5.0.6
0.4.0
Virender Khatri - bump thumbor version to 5.0.4
Virender Khatri - removed redisio dependency
0.3.7
Virender Khatri - bump thumbor version to 5.0.3
Virender Khatri - fix rubocop error
0.3.5
- Virender Khatri - disable nginx status by default, added optional attribute
0.3.3
Virender Khatri - bump thumbor version to v4.12.2
Richard Lee - PR #10, added nginx status
0.3.1
Virender Khatri - added gifsicle package for gif images
Virender Khatri - bump thumbor version to v4.8.6
Virender Khatri - temporarily fix to keep travis status green
0.2.8
- Richard Lee - PR #9, made pip dependencies configurable via attribute
node['thumbor_ng']['pip_dependencies']
0.2.7
Richard Lee - PR #8, added pip package for opencv-engine
Virender Khatri - bump thumbor version to 4.8.0
0.2.5
Virender Khatri - added cron job for purging thumbor file storage
Virender Khatri - bump thumbor version to 4.7.1
0.2.3
Virender Khatri - fixing ulimit for nginx, issue #4
Virender Khatri - updated thumbor nginx vhost to probable cause of 499 errors
0.2.1
Virender Khatri - fixed thumbor service over writes worker logs issue
Virender Khatri - fixed thumbor service ulimit, added to worker upstart init
Virender Khatri - added key for saucy thumbor ppa
Virender Khatri - added logrotate resource for nginx, required for custom log, perhaps nginx cookbook
would be the right place to fix this.
0.1.7
Virender Khatri - added travis ci support
Virender Khatri - fixed foodcritic
0.1.5
Virender Khatri - bump thumbor version to 4.6.0
Virender Khatri - added log level attribute
default['thumbor_ng']['log_level']
Virender Khatri - added support for ubuntu 14.04
Virender Khatri - filtered packages dependecnies for ubuntu 12+
Virender Khatri - thumbor service config file classified for
node['platform_family']
Virender Khatri - Removed default attributes with default values
0.1.0
- Virender Khatri - First commit
Check the Markdown Syntax Guide for help with Markdown.
The Github Flavored Markdown page describes the differences between markdown on github and standard markdown.
Collaborator Number Metric
0.4.2 failed this metric
Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.
Contributing File Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Foodcritic Metric
0.4.2 failed this metric
FC066: Ensure chef_version is set in metadata: thumbor_ng/metadata.rb:1
FC069: Ensure standardized license defined in metadata: thumbor_ng/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
No Binaries Metric
0.4.2 passed this metric
Testing File Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.4.2 failed this metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file
Foodcritic Metric
0.4.2 failed this metric
FC066: Ensure chef_version is set in metadata: thumbor_ng/metadata.rb:1
FC069: Ensure standardized license defined in metadata: thumbor_ng/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
No Binaries Metric
0.4.2 passed this metric
Testing File Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.4.2 failed this metric
FC069: Ensure standardized license defined in metadata: thumbor_ng/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any
0.4.2 passed this metric
Testing File Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file
Version Tag Metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number
0.4.2 failed this metric
0.4.2 failed this metric
Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number