forked from chef-boneyard/cookbooks
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cookbook for installing/configuring 7-zip file archiver
- Loading branch information
Showing
4 changed files
with
132 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
Description | ||
=========== | ||
|
||
[7-Zip](http://www.7-zip.org/) is a file archiver with a high compression ratio. This cookbook installs the full 7-zip suite of tools (GUI and CLI). | ||
|
||
Requirements | ||
============ | ||
|
||
Platform | ||
-------- | ||
|
||
* Windows XP | ||
* Windows Vista | ||
* Windows Server 2003 R2 | ||
* Windows 7 | ||
* Windows Server 2008 (R1, R2) | ||
|
||
Cookbooks | ||
--------- | ||
|
||
* windows | ||
|
||
Attributes | ||
========== | ||
|
||
* `node['7-zip']['home']` - location to install 7-zip files to. default is `%SYSTEMDRIVE%\7-zip` | ||
|
||
Usage | ||
===== | ||
|
||
default | ||
------- | ||
|
||
Downloads and installs 7-zip to the location specified by `node['7-zip']['home']`. Also ensures `node['7-zip']['home']` is in the system path. | ||
|
||
Changes/Roadmap | ||
=============== | ||
|
||
## 1.0.0: | ||
|
||
* initial release | ||
|
||
License and Author | ||
================== | ||
|
||
Author:: Seth Chisamore (<[email protected]>) | ||
|
||
Copyright:: 2011, Opscode, 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. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# | ||
# Author:: Seth Chisamore (<[email protected]>) | ||
# Cookbook Name:: 7-zip | ||
# Attribute:: default | ||
# | ||
# Copyright:: Copyright (c) 2011 Opscode, 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. | ||
# | ||
|
||
if kernel['machine'] =~ /x86_64/ | ||
default['7-zip']['url'] = "http://downloads.sourceforge.net/sevenzip/7z920-x64.msi" | ||
default['7-zip']['checksum'] = "62df458bc521001cd9a947643a84810ecbaa5a16b5c8e87d80df8e34c4a16fe2" | ||
default['7-zip']['package_name'] = "7-Zip 9.20 (x64 edition)" | ||
else | ||
default['7-zip']['url'] = "http://downloads.sourceforge.net/sevenzip/7z920.msi" | ||
default['7-zip']['checksum'] = "fe4807b4698ec89f82de7d85d32deaa4c772fc871537e31fb0fccf4473455cb8" | ||
default['7-zip']['package_name'] = "7-Zip 9.20" | ||
end | ||
|
||
default['7-zip']['home'] = "#{ENV['SYSTEMDRIVE']}\\7-zip" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
maintainer "Opscode, Inc." | ||
maintainer_email "[email protected]" | ||
license "Apache 2.0" | ||
description "Installs/Configures the 7-zip file archiver" | ||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) | ||
version "1.0.0" | ||
supports "windows" | ||
|
||
depends "windows", ">= 1.2.2" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# | ||
# Author:: Seth Chisamore (<[email protected]>) | ||
# Cookbook Name:: 7-zip | ||
# Recipe:: default | ||
# | ||
# Copyright 2011, Opscode, 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. | ||
# | ||
|
||
windows_package node['7-zip']['package_name'] do | ||
source node['7-zip']['url'] | ||
checksum node['7-zip']['checksum'] | ||
options "INSTALLDIR=\"#{node['7-zip']['home']}\"" | ||
action :install | ||
end | ||
|
||
# update path | ||
windows_path node['7-zip']['home'] do | ||
action :add | ||
end |