add recipes: git vim zlib zsh
This commit is contained in:
parent
6391d3c883
commit
0f3ba09614
5
Vagrantfile
vendored
5
Vagrantfile
vendored
@ -32,8 +32,13 @@ Vagrant::Config.run do |config|
|
||||
# to this Vagrantfile), and adding some recipes and/or roles.
|
||||
config.vm.provision :chef_solo do |chef|
|
||||
chef.cookbooks_path = "cookbooks"
|
||||
chef.add_recipe "vim"
|
||||
chef.add_recipe "zsh"
|
||||
chef.add_recipe "zlib"
|
||||
chef.add_recipe "git"
|
||||
chef.add_recipe "apt"
|
||||
chef.add_recipe "wordpress"
|
||||
# chef.add_recipe "custom"
|
||||
|
||||
chef.json.merge!(
|
||||
"mysql" => {
|
||||
|
54
cookbooks/git/README.md
Normal file
54
cookbooks/git/README.md
Normal file
@ -0,0 +1,54 @@
|
||||
Description
|
||||
===========
|
||||
|
||||
Installs git and optionally sets up a git server as a daemon under runit.
|
||||
|
||||
Changes
|
||||
=======
|
||||
|
||||
## v0.9.0:
|
||||
|
||||
* Current public release.
|
||||
|
||||
Requirements
|
||||
============
|
||||
|
||||
## Platform:
|
||||
|
||||
* Debian/Ubuntu
|
||||
* ArchLinux
|
||||
|
||||
## Cookbooks:
|
||||
|
||||
* runit
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
This cookbook primarily installs git core packages. It can also be
|
||||
used to serve git repositories.
|
||||
|
||||
include_recipe "git::server"
|
||||
|
||||
This creates the directory /srv/git and starts a git daemon, exporting
|
||||
all repositories found. Repositories need to be added manually, but
|
||||
will be available once they are created.
|
||||
|
||||
License and Author
|
||||
==================
|
||||
|
||||
Author:: Joshua Timberman (<joshua@opscode.com>)
|
||||
|
||||
Copyright:: 2009, 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.
|
@ -2,7 +2,7 @@ maintainer "Opscode, Inc."
|
||||
maintainer_email "cookbooks@opscode.com"
|
||||
license "Apache 2.0"
|
||||
description "Installs git and/or sets up a Git server daemon"
|
||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.rdoc'))
|
||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
||||
version "0.9.0"
|
||||
recipe "git", "Installs git"
|
||||
recipe "git::server", "Sets up a runit_service for git daemon"
|
||||
|
50
cookbooks/vim/README.md
Normal file
50
cookbooks/vim/README.md
Normal file
@ -0,0 +1,50 @@
|
||||
Description
|
||||
===========
|
||||
|
||||
Installs vim.
|
||||
|
||||
Requirements
|
||||
============
|
||||
|
||||
## Platform:
|
||||
|
||||
* Ubuntu/Debian
|
||||
* Red Hat/CentOS/Fedora/Scientific
|
||||
* ArchLinux
|
||||
|
||||
Attributes
|
||||
==========
|
||||
|
||||
* `node[:vim][:extra_packages]` - An array of extra packages related to vim to install (like plugins). Empty array by default.
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
Put `recipe[vim]` in a run list, or `include_recipe 'vim'` to ensure that vim is installed on your systems.
|
||||
|
||||
If you would like to install additional vim plugin packages, include their package names in the `node[:vim][:extra_packages]` attribute. Verify that your operating sytem has the package available.
|
||||
|
||||
Changes
|
||||
=======
|
||||
|
||||
## v1.0.2:
|
||||
|
||||
* Fixes COOK-598 (RHEL platforms support).
|
||||
|
||||
License and Author
|
||||
==================
|
||||
|
||||
Author:: Joshua Timberman <joshua@opscode.com>
|
||||
|
||||
Copyright 2010, 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
|
20
cookbooks/vim/attributes/default.rb
Normal file
20
cookbooks/vim/attributes/default.rb
Normal file
@ -0,0 +1,20 @@
|
||||
#
|
||||
# Cookbook Name:: vim
|
||||
# Attributes:: default
|
||||
#
|
||||
# Copyright 2010, 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.
|
||||
#
|
||||
|
||||
default[:vim][:extra_packages] = []
|
11
cookbooks/vim/metadata.rb
Normal file
11
cookbooks/vim/metadata.rb
Normal file
@ -0,0 +1,11 @@
|
||||
maintainer "Opscode, Inc."
|
||||
maintainer_email "cookbooks@opscode.com"
|
||||
license "Apache 2.0"
|
||||
description "Installs vim and optional extra packages."
|
||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
||||
version "1.0.2"
|
||||
|
||||
%w{debian ubuntu arch redhat centos fedora scientific}.each do |os|
|
||||
supports os
|
||||
end
|
||||
|
35
cookbooks/vim/recipes/default.rb
Normal file
35
cookbooks/vim/recipes/default.rb
Normal file
@ -0,0 +1,35 @@
|
||||
#
|
||||
# Cookbook Name:: vim
|
||||
# Recipe:: default
|
||||
#
|
||||
# Copyright 2010, 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.
|
||||
#
|
||||
|
||||
# There is no vim package on RHEL/CentOS derivatives
|
||||
# * vim-minimal gives you /bin/vi
|
||||
# * vim-enhanced gives you /usr/bin/vim
|
||||
vim_base_pkgs = value_for_platform(
|
||||
["ubuntu", "debian", "arch"] => { "default" => ["vim"] },
|
||||
["redhat", "centos", "fedora", "scientific"] => { "default" => ["vim-minimal","vim-enhanced"] },
|
||||
"default" => ["vim"]
|
||||
)
|
||||
|
||||
vim_base_pkgs.each do |vim_base_pkg|
|
||||
package vim_base_pkg
|
||||
end
|
||||
|
||||
node[:vim][:extra_packages].each do |vimpkg|
|
||||
package vimpkg
|
||||
end
|
27
cookbooks/zlib/README.md
Normal file
27
cookbooks/zlib/README.md
Normal file
@ -0,0 +1,27 @@
|
||||
Description
|
||||
====
|
||||
|
||||
Installs development package for zlib.
|
||||
|
||||
Requirements
|
||||
====
|
||||
|
||||
Debian, Ubuntu, CentOS, Red Hat, Scientific, Fedora, SUSE.
|
||||
|
||||
License and Author
|
||||
====
|
||||
|
||||
Author:: Joshua Timberman (<joshua@opscode.com>)
|
||||
Copyright:: 2009-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.
|
12
cookbooks/zlib/metadata.rb
Normal file
12
cookbooks/zlib/metadata.rb
Normal file
@ -0,0 +1,12 @@
|
||||
maintainer "Opscode, Inc."
|
||||
maintainer_email "cookbooks@opscode.com"
|
||||
license "Apache 2.0"
|
||||
description "Installs zlib"
|
||||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
|
||||
version "1.0.0"
|
||||
|
||||
recipe "zlib", "Installs zlib development package"
|
||||
|
||||
%w{ centos redhat scientific suse fedora ubuntu debian }.each do |os|
|
||||
supports os
|
||||
end
|
25
cookbooks/zlib/recipes/default.rb
Normal file
25
cookbooks/zlib/recipes/default.rb
Normal file
@ -0,0 +1,25 @@
|
||||
#
|
||||
# Cookbook Name:: zlib
|
||||
# Recipe:: default
|
||||
#
|
||||
# Copyright 2010, 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.
|
||||
#
|
||||
|
||||
package "zlib-devel" do
|
||||
package_name value_for_platform(
|
||||
[ "centos", "redhat", "scientific", "suse", "fedora" ] => { "default" => "zlib-devel" },
|
||||
"default" => 'zlib1g-dev'
|
||||
)
|
||||
end
|
49
cookbooks/zsh/README.md
Normal file
49
cookbooks/zsh/README.md
Normal file
@ -0,0 +1,49 @@
|
||||
Description
|
||||
===========
|
||||
|
||||
Installs zsh package and documentation.
|
||||
|
||||
Changes
|
||||
=======
|
||||
|
||||
## v0.7.1
|
||||
|
||||
* Current public release.
|
||||
|
||||
Requirements
|
||||
============
|
||||
|
||||
## Platform:
|
||||
|
||||
* Ubuntu 10.04+
|
||||
* Debian 6.0+
|
||||
* CentOS 5.7+
|
||||
|
||||
Should work anywhere there's a `zsh` package available in the platform
|
||||
package manager.
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
Whereever you have users who want to use `zsh` as their login shell,
|
||||
use this recipe. For example, add `recipe[zsh]` to a base role applied
|
||||
to all nodes.
|
||||
|
||||
License and Author
|
||||
==================
|
||||
|
||||
Author:: Adam Jacob <adam@opscode.com>
|
||||
|
||||
Copyright:: 2008-2009, 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.
|
11
cookbooks/zsh/metadata.rb
Normal file
11
cookbooks/zsh/metadata.rb
Normal file
@ -0,0 +1,11 @@
|
||||
maintainer "Opscode, Inc."
|
||||
maintainer_email "cookbooks@opscode.com"
|
||||
license "Apache 2.0"
|
||||
description "Installs zsh"
|
||||
version "0.7.1"
|
||||
|
||||
recipe "zsh", "Installs zsh"
|
||||
|
||||
%w{ubuntu debian}.each do |os|
|
||||
supports os
|
||||
end
|
33
cookbooks/zsh/recipes/default.rb
Normal file
33
cookbooks/zsh/recipes/default.rb
Normal file
@ -0,0 +1,33 @@
|
||||
#
|
||||
# Cookbook Name:: zsh
|
||||
# Recipe:: default
|
||||
#
|
||||
# Copyright 2008-2009, 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.
|
||||
#
|
||||
|
||||
package "zsh" do
|
||||
action :install
|
||||
end
|
||||
|
||||
case node[:platform]
|
||||
when "ubuntu","debian"
|
||||
package "zsh-doc" do
|
||||
action :install
|
||||
end
|
||||
when "centos"
|
||||
package "zsh-html" do
|
||||
action :install
|
||||
end
|
||||
end
|
Loading…
Reference in New Issue
Block a user