Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

RSS

nginx_simplecgi (3) Versions 0.2.0

Provides SimpleCGI for NGINX

Berkshelf/Librarian
Policyfile
Knife
cookbook 'nginx_simplecgi', '~> 0.2.0'
cookbook 'nginx_simplecgi', '~> 0.2.0', :supermarket
knife cookbook site install nginx_simplecgi
knife cookbook site download nginx_simplecgi
README
Dependencies
Changelog
Quality

nginx_simplecgi cookbook

Build Status Cookbook Version

This cookbook provides CGI support for NGINX via SimpleCGI.

Requirements

Platforms

  • Debian/ Ubuntu
  • RHEL based platforms (CentOS, Redhat, etc)

Chef

  • Chef 12.1+

Cookbooks

  • chef_nginx
  • perl
  • runit
  • yum-epel

Usage

Attributes

  • node['nginx_simplecgi']['cgi'] -> Enable CGI dispatch
  • node['nginx_simplecgi']['php'] -> Enable PHP dispatch
  • node['nginx_simplecgi']['php_cgi_bin'] -> PHP executable path for CGI
  • node['nginx_simplecgi']['init_type'] -> Init style for dispatchers
  • node['nginx_simplecgi']['dispatcher_directory'] -> Directory to contain socket and pid files
  • node['nginx_simplecgi']['dispatcher_processes'] -> Number of dispatcher processes for handling requests

Template Helper

A template method helper, dispatch is provided to add the require location block into your nginx configuration files:

<%= nginx_dispatch(:cgi) %>

The default call will output:

  location ~ ^/cgi-bin/.*\.cgi$ {
    gzip off;
    fastcgi_pass  unix:/var/run/nginx/cgiwrap-dispatch.sock;
    fastcgi_index index.cgi;
    fastcgi_param SCRIPT_FILENAME /usr/lib$fastcgi_script_name;
    fastcgi_param QUERY_STRING     $query_string;
    fastcgi_param REQUEST_METHOD   $request_method;
    fastcgi_param CONTENT_TYPE     $content_type;
    fastcgi_param CONTENT_LENGTH   $content_length;
    fastcgi_param GATEWAY_INTERFACE  CGI/1.1;
    fastcgi_param SERVER_SOFTWARE    nginx;
    fastcgi_param SCRIPT_NAME        $fastcgi_script_name;
    fastcgi_param REQUEST_URI        $request_uri;
    fastcgi_param DOCUMENT_URI       $document_uri;
    fastcgi_param DOCUMENT_ROOT      $document_root;
    fastcgi_param SERVER_PROTOCOL    $server_protocol;
    fastcgi_param REMOTE_ADDR        $remote_addr;
    fastcgi_param REMOTE_PORT        $remote_port;
    fastcgi_param SERVER_ADDR        $server_addr;
    fastcgi_param SERVER_PORT        $server_port;
    fastcgi_param SERVER_NAME        $server_name;
  }

Available options:

  • :pattern -> change the pattern nginx matches
  • :cgi_bin_dir -> change the prefix directory of the local cgi-bin
  • :dispatcher -> use a custom dispatcher (socket or tcp based)
  • :custom -> string to be appended within the location block

The method will also accept a block that will be eval'd and the result appended within the location block.

License and Author

Author:: Chris Roberts (chrisroberts.code@gmail.com)

Copyright:: Chris Roberts

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.

nginx_simplecgi CHANGELOG

This file is used to list changes made in each version of the nginx_simplecgi cookbook.

0.2.0 (2017-07-18)

  • Support for Bluepill has been removed. If you require Bluepill use the 0.1.X release
  • This cookbook now requires Chef 12.1 or later
  • The nginx dependency has been replaced with chef_nginx which is being actively maintained
  • node.set usage has been replaced with a node.override to avoid setting attributes permanently on the node
  • Fixed the PHP socket being spawned with an incorrect name in Upstart
  • Added the Apache 2.0 license file
  • Support for CentOS 5 has been removed as CentOS 5 is EOL
  • Package installs now use multi-package installation to speed up Chef runs
  • Initial support for Amazon Linux on Chef 13 has been added
  • The cheffile has been removed and replaced with Berkshelf
  • The suggestion to use the yum-epel cookbook has been changed to a hard requirement as 'suggests' in metadata is deprecated
  • A chefignore file has been added to limit the files that are uploaded to the Chef server
  • New metadata fields for issues_url, source_url, and chef_version have been added
  • This changelog has been added to track changes to the cookbook going forward
  • Add symbols in node attributes have been replaced with strings to pass Foodcritic FC001 rule
  • Resolved all cookstyle and foodcritic warnings
  • Test dependencies have been removed from the Gemfile as testing should be done via ChefDK
  • A delivery local mode config file has been added for testing
  • Added testing with Travis CI
  • Added a basic chefspec to test the converge

Collaborator Number Metric
            

0.2.0 passed this metric

Contributing File Metric
            

0.2.0 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

License Metric
            

0.2.0 passed this metric

Publish Metric
            

0.2.0 passed this metric

Supported Platforms Metric
            

0.2.0 passed this metric

Testing File Metric
            

0.2.0 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.2.0 passed this metric