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

Select Status

RSS

ark (68) Versions 0.0.16

Provides a custom resource for installing runtime artifacts in a predictable fashion

Policyfile
Berkshelf
Knife
cookbook 'ark', '= 0.0.16', :supermarket
cookbook 'ark', '= 0.0.16'
knife supermarket install ark
knife supermarket download ark
README
Dependencies
Quality -%

<a name="title"></a> chef-ark Build Status

Overview

An ''ark'' is like an archive but ''Kewler''

Does the fetch-unpack-configure-build-install dance. This is a
modified verion of Infochimps awesome install_from cookbook
[http://github.com/infochimps-cookbooks/install_from]. It has been
heavily refactored and extended to meet different use cases.

Given a simple project archive available at a url:

ark 'pig' do
  url 'http://apache.org/pig/pig-0.8.0.tar.gz'
end

this provider will

  • fetch it to to /var/cache/chef/
  • unpack it to the default path (/usr/local/pig-0.8.0)
  • create a symlink for :home_dir (/usr/local/pig) pointing to path
  • add specified binary commands to the enviroment PATH variable

By default, the ark will not run again if the :path is not
empty. Ark provides many actions to accommodate different use cases,
such as :dump, :cherry_pick, :put, and :install_with_make.

At this time ark only handles files available from URLs. It does not
handle local files.

Attributes

Customize the attributes to suit site specific conventions and
defaults.

  • node['ark']['apache_mirror'] - if the URL is an apache mirror, use the attribute as the default.
  • node['ark']['prefix_root'] - default base location if the prefix_root is not passed into the resource.
  • node['ark']['prefix_bin'] - default binary location if the prefix_bin is not passed into the resource.
  • node['ark']['prefix_home'] - default home location if the prefix_home is not passed into the resource.

Resources/Providers

  • ark - does the extract/build/configure dance

Actions

  • :install: extracts the file and creates a 'friendly' symbolic link to the extracted directory path
  • :configure: configure ahead of the install action
  • :install_with_make: extracts the archive to a path, runs make, and make install. It does not run the configure step at this time
  • :dump: strips all directories from the archive and dumps the contained files into a specified path
  • :cherry_pick: extract a specified file from an archive and places in specified path
  • :put: extract the archive to a specified path, does not create any symbolic links
  • :remove: removes the extracted directory and related symlink #TODO
  • :setup_py_build: runs the command "python setup.py build" in the extracted directory
  • :setup_py_install: runs the comand "python setup.py install" in the extracted directory

:put

Extract the archive to a specified path, does not create any symbolic links.

Attribute Parameters for :put

  • path: path to extract to.
    • Default: /usr/local
  • has_binaries: array of binary commands to symlink into /usr/local/bin/, you must specify the relative path.
    • Example: [ 'bin/java', 'bin/javaws' ]
  • append_env_path: boolean, if true, append the ./bin directory of the extracted directory to the global PATH variable for all users.

:dump

Strips all directories from the archive and dumps the contained files into a specified path.

NOTE: This currently only works for zip archives

Attribute Parameters for :dump

  • path: path to dump files to.
  • mode: file mode for app_home, as an integer.
    • Example: 0775
  • creates: if you are appending files to a given directory, ark needs a condition to test whether the file has already been extracted. You can specify with creates, a file whose existence indicates the ark has previously been extracted and does not need to be extracted again.

:cherry_pick

Extract a specified file from an archive and places in specified path.

Relevant Attribute Parameters for :cherry_pick

  • path: directory to place file in.
  • creates: specific file to cherry-pick.

Attribute Parameters

  • name: name of the package, defaults to the resource name.
  • url: url for tarball, .tar.gz, .bin (oracle-specific), .war, and .zip currently supported. Also supports special syntax :name:version:apache_mirror: that will auto-magically construct download url from the apache mirrors site.
  • version: software version, required.
  • checksum: sha256 checksum, used for security .
  • mode: file mode for app_home, is an integer.
  • prefix_root: default prefix_root, for use with :install* actions.
  • prefix_home: default directory prefix for a friendly symlink to the path.
    • Example: /usr/local/maven -> /usr/local/maven-2.2.1
  • prefix_bin: default directory to place a symlink to a binary command.
    • Example: /opt/bin/mvn -> /opt/maven-2.2.1/bin/mvn, where the prefix_bin is /opt/bin
  • path: path to extract the ark to. The :install* actions overwrite any user-provided values for :path.
    • Default: /usr/local/<name>-<version> for the :install, :install_with_make actions
  • home_dir: symbolic link to the path :prefix_root/:name-:version, does not apply to :dump, :put, or :cherry_pick actions.
    • Default: :prefix_root/:name
  • has_binaries: array of binary commands to symlink into /usr/local/bin/, you must specify the relative path.
    • Example: [ 'bin/java', 'bin/javaws' ]
  • append_env_path: boolean, similar to has_binaries but less granular. If true, append the ./bin directory of the extracted directory to. the PATH environment variable for all users, by placing a file in /etc/profile.d/. The commands are symbolically linked into /usr/bin/*. This option provides more granularity than the boolean option.
    • Example: mvn, java, javac, etc.
  • environment: hash of environment variables to pass to invoked shell commands like tar, unzip, configure, and make.
  • strip_leading_dir: by default, ark strips the leading directory from an archive, which is the default for both unzip and tar commands
  • autoconf_opts: an array of command line options for use with the GNU autoconf script.
    • Example: [ '--include=/opt/local/include', '--force' ]
  • make_opts: an array of command line options for use with make.
    • Example: [ '--warn-undefined-variables', '--load-average=2' ]
  • owner: owner of extracted directory.
    • Default: root

Examples

 # install Apache Ivy dependency resolution tool
 ark "ivy" do
   url 'http://someurl.example.com/ivy.tar.gz'
   version '2.2.0'
   checksum '89ba5fde0c596db388c3bbd265b63007a9cc3df3a8e6d79a46780c1a39408cb5'
   action :install
 end

This example copies ivy.tar.gz to
/var/cache/chef/ivy-2.2.0.tar.gz, unpacks its contents to
/usr/local/ivy-2.2.0/ -- stripping the leading directory, and
symlinks /usr/local/ivy to /usr/local/ivy-2.2.0

 ark 'jdk' do
   url 'http://download.example.com/jdk-7u2-linux-x64.tar.gz'
   version '7.2'
   path "/usr/local/jvm/"
   home_dir "/usr/local/jvm/default"
   checksum  '89ba5fde0c596db388c3bbd265b63007a9cc3df3a8e6d79a46780c1a39408cb5'
   append_env_path true
   owner 'foobar'
 end

This example copies jdk-7u2-linux-x64.tar.gz to
/var/cache/chef/jdk-7.2.tar.gz, unpacks its contents to
/usr/local/jvm/jdk-7.2/ -- stripping the leading directory, symlinks
/usr/local/jvm/default to /usr/local/jvm/jdk-7.2, and adds
/usr/local/jvm/jdk-7.2/bin/ to the global PATH for all users. The
user 'foobar' is the owner of the /usr/local/jvm/jdk-7.2 directory

 # install Apache Ivy dependency resolution tool
 # in /resource_name in this case
 # /usr/local/ivy, no symlink created
 # it strips any leading directory if one exists in the tarball

 ark "ivy" do
    url 'http://someurl.example.com/ivy.tar.gz'
    checksum '89ba5fde0c596db388c3bbd265b63007a9cc3df3a8e6d79a46780c1a39408cb5'
    action :put
 end

 # install Apache Ivy dependency resolution tool
 # in /home/foobar/ivy
 # it does strip any leading directory if one exists

 ark "ivy" do
   path "/home/foobar
   url 'http://someurl.example.com/ivy.tar.gz'
   checksum '89ba5fde0c596db388c3bbd265b63007a9cc3df3a8e6d79a46780c1a39408cb5'
   action :put
 end

# strip all directories and dump files into path specified by
 # the path attribute, you must specify the `creates` attribute
 # in order to keep the extraction from running every time
 # the directory path will be created if it doesn't already exist

 ark "my_jars" do
   url  "http://example.com/bunch_of_jars.zip"
   path "/usr/local/tomcat/lib"
   creates "mysql.jar"
   owner "tomcat"
   action :dump
 end

 # extract specific files from a tarball, currently only handles
 # one named file

 ark 'mysql-connector-java' do
   url 'http://oracle.com/mysql-connector.zip'
   creates 'mysql-connector-java-5.0.8-bin.jar'
   path '/usr/local/tomcat/lib'
   action :cherry_pick
 end

 # build and install haproxy and use alternave values for
 # prefix_root, prefix_home, and prefix_bin

 ark "haproxy" do
   url  "http://haproxy.1wt.eu/download/1.5/src/snapshot/haproxy-ss-20120403.tar.gz"
   version "1.5"
   checksum 'ba0424bf7d23b3a607ee24bbb855bb0ea347d7ffde0bec0cb12a89623cbaf911'
   make_opts [ 'TARGET=linux26' ]
   prefix_root '/opt'
   prefix_home '/opt'
   prefix_bin  '/opt/bin'
   action :install_with_make
 end

 # you can also pass multiple actions to ark and supply the file extension
 # in case the file extension can not be determined by the URL

 ark "test_autogen" do
   url 'https://github.com/zeromq/libzmq/tarball/master'
   extension "tar.gz"
   action [ :configure, :build_with_make ]
 end

 # you can also pass multiple actions to ark and supply the file extension
 # in case the file extension can not be determined by the URL
 ark "test_autogen" do
   url 'https://github.com/zeromq/libzmq/tarball/master'
   extension "tar.gz"
   action [ :configure, :build_with_make ]
 end

License and Author

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.

Dependent cookbooks

This cookbook has no specified dependencies.

Contingent cookbooks

abiquo Applicable Versions
aem Applicable Versions
aerospike-platform Applicable Versions
alfresco Applicable Versions
android-sdk Applicable Versions
ant Applicable Versions
apache_tomcat Applicable Versions
apktool Applicable Versions
archiva Applicable Versions
artifact-deployer Applicable Versions
artifactory Applicable Versions
artifactory_ii Applicable Versions
asdf Applicable Versions
askbot Applicable Versions
atlantis Applicable Versions
aws-codedeploy-agent Applicable Versions
bamboo Applicable Versions
bitbucket_server Applicable Versions
bjn_franz Applicable Versions
bjn_logstash Applicable Versions
caddy Applicable Versions
cassandra-dse Applicable Versions
cassandra-platform Applicable Versions
cdap Applicable Versions
cdo Applicable Versions
chamber-kibana Applicable Versions
chef-nsq Applicable Versions
chef_crowd Applicable Versions
chef_jira Applicable Versions
chgems Applicable Versions
chruby Applicable Versions
chruby-build Applicable Versions
clang Applicable Versions
cockroachdb-platform Applicable Versions
confluence Applicable Versions
consul Applicable Versions
consul-platform Applicable Versions
consul-template Applicable Versions
couch Applicable Versions
crowd Applicable Versions
devopsdance-consul-template Applicable Versions
dkron Applicable Versions
ds_redis Applicable Versions
duosecurity Applicable Versions
elasticsearch Applicable Versions
elasticsearch 0.2.0
elasticsearch 0.2.1
elasticsearch 0.2.2
elasticsearch 0.2.3
elasticsearch 0.2.4
elasticsearch 0.2.5
elasticsearch 0.2.7
elasticsearch 0.3.0
elasticsearch 0.3.1
elasticsearch 0.3.2
elasticsearch 0.3.3
elasticsearch 0.3.4
elasticsearch 0.3.5
elasticsearch 0.3.7
elasticsearch 0.3.8
elasticsearch 0.3.9
elasticsearch 0.3.10
elasticsearch 0.3.11
elasticsearch 0.3.12
elasticsearch 0.3.13
elasticsearch 0.3.14
elasticsearch 1.0.0
elasticsearch 1.0.1
elasticsearch 1.0.2
elasticsearch 1.0.3
elasticsearch 1.2.0
elasticsearch 2.0.0
elasticsearch 2.0.1
elasticsearch 2.1.0
elasticsearch 2.1.1
elasticsearch 2.2.0
elasticsearch 2.2.1
elasticsearch 2.2.2
elasticsearch 2.3.0
elasticsearch 2.3.1
elasticsearch 2.3.2
elasticsearch 2.4.0
elasticsearch 2.4.1
elasticsearch 2.5.0
elasticsearch 3.0.0
elasticsearch 3.0.1
elasticsearch 3.0.2
elasticsearch 3.0.3
elasticsearch 3.0.4
elasticsearch 3.0.5
elasticsearch 3.1.0
elasticsearch 3.1.1
elasticsearch 3.2.0
elasticsearch 3.2.1
elasticsearch 3.2.2
elasticsearch 3.3.0
elasticsearch 3.3.1
elasticsearch 3.4.0
elasticsearch 3.4.1
elasticsearch 3.4.2
elasticsearch 3.4.3
elasticsearch 3.4.4
elasticsearch 3.4.5
elasticsearch 3.4.6
elasticsearch 3.4.7
elasticsearch 3.4.8
elasticsearch 3.4.9
elasticsearch 3.4.10
elasticsearch 4.0.0
elasticsearch 4.0.1
elasticsearch 4.0.2
elasticsearch 4.0.3
elasticsearch 4.0.4
elasticsearch 4.0.5
elasticsearch 4.0.6
elasticsearch 4.1.0
elasticsearch 4.2.0
elasticsearch 4.3.0
elasticsearch 5.0.0
elasticsearch 5.1.0
elasticsearch 5.1.1
elasticsearch 5.1.2
elasticsearch 5.1.3
elasticsearch 5.1.4
elasticsearch 5.1.5
elasticsearch 5.1.6
elasticsearch 5.1.7
elasticsearch 5.1.8
elasticsearch 5.1.9
elasticsearch 5.1.10
elk Applicable Versions
ellk Applicable Versions
embulk Applicable Versions
et_gradle Applicable Versions
etcd Applicable Versions
fasd Applicable Versions
fish-shell Applicable Versions
flyway Applicable Versions
flyway-cli Applicable Versions
gallery Applicable Versions
gatling Applicable Versions
gcc-arm-embedded Applicable Versions
gdal Applicable Versions
git Applicable Versions
gobgp Applicable Versions
gogs Applicable Versions
golang Applicable Versions
gqlplus Applicable Versions
gradle Applicable Versions
grafana Applicable Versions
graylog Applicable Versions
graylog2 Applicable Versions
groovy Applicable Versions
haproxy-ng Applicable Versions
hashicorp-vault Applicable Versions
hipsnip-mongodb Applicable Versions
idea Applicable Versions
imply-platform Applicable Versions
java_wrapper Applicable Versions
jboss-eap Applicable Versions
jboss7 Applicable Versions
jira Applicable Versions
jmeter Applicable Versions
jmxtrans Applicable Versions
karaf Applicable Versions
kibana Applicable Versions
kibana5 Applicable Versions
kibana5-gm Applicable Versions
kibana_lwrp Applicable Versions
kloudspeaker Applicable Versions
kubelet Applicable Versions
librenms Applicable Versions
librenms-ng Applicable Versions
logstash Applicable Versions
lxd Applicable Versions
lxmx_oh_my_zsh Applicable Versions
magentostack Applicable Versions
mattermost Applicable Versions
mattermost-cookbook Applicable Versions
maven Applicable Versions
maxdb Applicable Versions
mcrouter Applicable Versions
mediawiki Applicable Versions
microfocus Applicable Versions
mozilla-firefox Applicable Versions
msodbcsql Applicable Versions
mx Applicable Versions
mysql_connector Applicable Versions
nagios_v_shell Applicable Versions
netdevops Applicable Versions
nexus Applicable Versions
nexus3 Applicable Versions
ngrok Applicable Versions
nodejs Applicable Versions
nomad Applicable Versions
oauth2_proxy Applicable Versions
oh_my_zsh Applicable Versions
omni_ruby Applicable Versions
open_resty Applicable Versions
opencv Applicable Versions
opengrok Applicable Versions
openhab Applicable Versions
opsview Applicable Versions
opsworks_ruby Applicable Versions
oracle-client Applicable Versions
packer Applicable Versions
paramount Applicable Versions
peopletools Applicable Versions
ping-exporter Applicable Versions
play Applicable Versions
postfixadmin Applicable Versions
postgresql_studio Applicable Versions
prometheus Applicable Versions
prometheus-platform Applicable Versions
prosody Applicable Versions
pulledpork Applicable Versions
puncha-kibana Applicable Versions
q2a Applicable Versions
rackmonkey Applicable Versions
rainloop Applicable Versions
redis2 Applicable Versions
riemann2 Applicable Versions
roundcube Applicable Versions
ruby_install Applicable Versions
sbp_packer Applicable Versions
scala Applicable Versions
seafile Applicable Versions
shinken Applicable Versions
simple-cerebro Applicable Versions
simple-hazelcast Applicable Versions
simple-kibana Applicable Versions
simple-logstash Applicable Versions
simple-nexus Applicable Versions
sips-office-server Applicable Versions
snapraid Applicable Versions
sockd Applicable Versions
solr Applicable Versions
solr_app Applicable Versions
spark-platform Applicable Versions
spinen-artifactory Applicable Versions
spinen-grails Applicable Versions
sshpass Applicable Versions
stash Applicable Versions
storm-platform Applicable Versions
strongdm Applicable Versions
sublime-text Applicable Versions
taurus Applicable Versions
terraform Applicable Versions
tomcat-all Applicable Versions
tuxedo Applicable Versions
ut_workstation Applicable Versions
vault-cli Applicable Versions
vertx Applicable Versions
vmwaretools Applicable Versions
vsphere_perl_sdk Applicable Versions
vsts_agent Applicable Versions
zabbix Applicable Versions
zarafa Applicable Versions
zfs_linux Applicable Versions
zookeeper Applicable Versions
zookeeper-platform Applicable Versions

No quality metric results found