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

windows_print (1) Versions 0.1.0

Installs/Configures print

Berkshelf/Librarian
Policyfile
Knife
cookbook 'windows_print', '~> 0.1.0'
cookbook 'windows_print', '~> 0.1.0', :supermarket
knife cookbook site install windows_print
knife cookbook site download windows_print
README
Dependencies
Quality

windows_print Cookbook

This cookbook installs Windows Print and Document Services, handles driver, port, and printer installation.

Requirements

Platform

  • Windows Server 2008 R2
  • Windows Server 2012
  • Windows Server 2012 R2

Cookbooks

Usage

windows_print::default

The windows_print::default recipe installs the required roles and features to support a windows print server.

{
  "name":"my_node",
  "run_list": [
    "recipe[windows_print]"
  ]
}

windows_print::distributed_scan_server

The windows_print::distributed_scan_server recipe installs the required role to support a windows distributed scan server.

{
  "name":"my_node",
  "run_list": [
    "recipe[windows_print::distributed_scan_server]"
  ]
}

windows_print::internet_printing

The windows_print::internet_printing recipe installs the required roles and features to support a windows print server internet printing including IIS. This action will install all require features from windows_print::default.

{
  "name":"my_node",
  "run_list": [
    "recipe[windows_print::internet_printing]"
  ]
}

windows_print::lpd_service

The windows_print::lpd_service recipe installs the required role to install a line printer daemon service.

{
  "name":"my_node",
  "run_list": [
    "recipe[windows_print::lpd_service]"
  ]
}

Resource/Provider

'driver'

Installs printer driver from inf file.

Actions

  • :install: Installs a printer driver
  • :delete: Removes a printer driver

Attribute Parameters

  • driver_name: name attribute. Name of the print driver.
  • inf_path: Full path to the inf file.
  • inf_file: Name of the inf file.
  • version: Default "Type 3 - User Mode" Options: "Type 3 - User Mode" or "Type 2 - Kernel Mode"
  • environment: Chipset of the driver being installed. Default "x64" Options: "x86", "x64" or "Itanium".

Examples

# Install HP LaserJet 9050 PS driver
windows_print_driver "HP LaserJet 9050 PS" do
  action :install
  inf_path "c:\\9050 x64"      
  inf_file "hpc9050v.inf"
end

# Delete HP LaserJet 9050 PS driver
windows_print_driver "HP LaserJet 9050 PS" do
  action :delete
end

'port'

Allows creation of ports based on name rather than IP Address.

Actions

  • :create: Installs a printer port
  • :delete: Removes a printer port

Attribute Parameters

  • port_name: name attribute. Name of the port.
  • ipv4_address: IPv4 address of the printer port

Examples

# Install PrinterPort1 port @ 10.0.0.50
windows_print_port "PrinterPort1" do
  action :create
  ipv4_address "10.0.0.50"
end

# Deletes PrinterPort1 port
windows_print_port "PrinterPort1" do
  action :delete
end

'printer'

Allows creation of printer objects. Handles port and driver creation if not present.

Actions

  • :create: Creates a printer
  • :delete: Deletes a printer

Attribute Parameters

  • printer_name: name attribute. Name of the printer. Required
  • driver_name: Name of the print driver. Required
  • port_name: Name of the port. Required
  • share_name: Shared printer object name.
  • location: Location field for printer object.
  • comment: Comments section for printer object.
  • ipv4_address: IPv4 address of the printer port
  • inf_path: Full path to the inf file.
  • inf_file: Name of the inf file.
  • version: Default "Type 3 - User Mode" Options: "Type 3 - User Mode" or "Type 2 - Kernel Mode"
  • environment: Chipset of the driver being installed. Default "x64" Options: "x86", "x64" or "Itanium".

Examples

# Create HP LaserJet
windows_print_printer "HP LaserJet" do
  action :create
  driver_name "HP LaserJet"
  port_name "HP LaserJet"
end

# Create HP LaserJet, create driver, create port
windows_print_printer "HP LaserJet" do
  action :create
  driver_name "HP LaserJet"
  port_name "HP LaserJet"
  ipv4_address "10.0.0.50"
  inf_path "C:\\chef\\cookbooks\\windows_print\\files\\default\\HP Universal Printing PCL 6 (v5.4)\\x64"
  inf_file "hpcu118u.inf"
  environment "x64"
end

# Create HP LaserJet and share as "HP Printer"
windows_print_printer "HP LaserJet" do
  action :create
  driver_name "HP LaserJet"
  port_name "HP LaserJet"
  comment ""
  ipv4_address "10.0.0.50"
  inf_path "C:\\chef\\cookbooks\\windows_print\\files\\default\\HP Universal Printing PCL 6 (v5.4)\\x64"
  inf_file "hpcu118u.inf"
  share_name "HP Printer"
  environment "x64"
end

# Deletes HP LaserJet
windows_print_port "HP LaserJet" do
  action :delete
end

Contributing

  1. Fork the repository on Github
  2. Create a named feature branch (like add_component_x)
  3. Write you change
  4. Write tests for your change (if applicable)
  5. Run the tests, ensuring they all pass
  6. Submit a Pull Request using Github

License and Authors

Authors:: Derek Groh (dgroh@arch.tamu.edu)

Dependent cookbooks

windows >= 0.0.0

Contingent cookbooks

There are no cookbooks that are contingent upon this one.

Collaborator Number Metric
            

0.1.0 failed this metric

Failure: Cookbook has 0 collaborators. A cookbook must have at least 2 collaborators to pass this metric.

Contributing File Metric
            

0.1.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

Foodcritic Metric
            

0.1.0 failed this metric

FC059: LWRP provider does not declare use_inline_resources: windows_print/providers/driver.rb:1
FC059: LWRP provider does not declare use_inline_resources: windows_print/providers/port.rb:1
FC059: LWRP provider does not declare use_inline_resources: windows_print/providers/printer.rb:1
FC064: Ensure issues_url is set in metadata: windows_print/metadata.rb:1
FC065: Ensure source_url is set in metadata: windows_print/metadata.rb:1
FC066: Ensure chef_version is set in metadata: windows_print/metadata.rb:1
FC067: Ensure at least one platform supported in metadata: windows_print/metadata.rb:1
Run with Foodcritic Version 11.1.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any

License Metric
            

0.1.0 passed this metric

No Binaries Metric
            

0.1.0 passed this metric

Publish Metric
            

0.1.0 passed this metric

Supported Platforms Metric
            

0.1.0 failed this metric

windows_print should declare what platform(s) it supports.

Testing File Metric
            

0.1.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.1.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 include a tag that matches this cookbook version number