Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion Berksfile
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
site :opscode
source "https://supermarket.getchef.com"

cookbook 'nginx', '~> 2.7.4'
cookbook 'deployers', :path => './site-cookbooks/deployers'
cookbook 'custom-apt-install', :path => './site-cookbooks/custom-apt-install'
cookbook 'rvm', '~> 0.9.2'
cookbook 'redisio', '~> 2.2.4'
cookbook 'locale', '~> 1.0.2'
43 changes: 43 additions & 0 deletions Berksfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
DEPENDENCIES
custom-apt-install
path: site-cookbooks/custom-apt-install
deployers
path: site-cookbooks/deployers
locale (~> 1.0.2)
nginx (~> 2.7.4)
redisio (~> 2.2.4)
rvm (~> 0.9.2)

GRAPH
apt (2.6.0)
bluepill (2.3.1)
rsyslog (>= 0.0.0)
build-essential (2.1.2)
chef_gem (0.1.0)
custom-apt-install (0.1.0)
deployers (0.1.0)
java (1.28.0)
locale (1.0.2)
nginx (2.7.4)
apt (~> 2.2)
bluepill (~> 2.3)
build-essential (~> 2.0)
ohai (~> 2.0)
runit (~> 1.2)
yum-epel (~> 0.3)
ohai (2.0.1)
redisio (2.2.4)
build-essential (>= 0.0.0)
ulimit (>= 0.1.2)
rsyslog (1.12.2)
runit (1.5.10)
build-essential (>= 0.0.0)
yum (~> 3.0)
yum-epel (>= 0.0.0)
rvm (0.9.2)
chef_gem (>= 0.0.0)
java (>= 0.0.0)
ulimit (0.3.2)
yum (3.4.1)
yum-epel (0.5.2)
yum (~> 3.0)
9 changes: 9 additions & 0 deletions data_bags/deployers/apps.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"id": "apps",
"name": "apps",
"password": "xxx",
"ssh_keys": [
"xxx",
"xxx"
]
}
9 changes: 9 additions & 0 deletions data_bags/deployers/ubuntu.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"id": "ubuntu",
"name": "ubuntu",
"password": "xxx",
"ssh_keys": [
"xxx",
"xxx"
]
}
46 changes: 46 additions & 0 deletions environments/staging.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"name": "staging",
"description": "staging env",
"json_class": "Chef::Environment",
"chef_type": "environment",
"default_attributes": {
"rvm" : {
"default_ruby" : "ruby-2.0.0-p594",
"user_default_ruby" : "ruby-2.0.0-p594",
"rubies" : [ "ruby-2.0.0-p594" ],
"user_rubies" : [ "ruby-2.0.0-p594" ],
"global_gems" : [
{ "name" : "rails" },
{ "name" : "bundler" },
{ "name" : "mysql2" },
{ "name" : "mini_magick" },
{ "name" : "passenger", "version" : "4.0.53" },
{ "name" : "therubyracer" }
]
},
"nginx" : {
"install_method" : "source",
"dir" : "/opt/nginx/conf",
"source" : {
"prefix" : "/opt/nginx",
"modules" : [
"nginx::http_ssl_module",
"nginx::http_gzip_static_module",
"nginx::passenger"
]
},
"passenger" : {
"version": "4.0.53",
"ruby" : "/usr/local/rvm/rubies/ruby-2.0.0-p594/bin/ruby",
"root" : "/usr/local/rvm/gems/ruby-2.0.0-p594@global/gems/passenger-4.0.53"
}
},
"locale" : {
"lang" : "zh_TW.UTF-8",
"lc_all" : "zh_TW.UTF-8"
}
},
"override_attributes": {

}
}
12 changes: 12 additions & 0 deletions nodes/template.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"name": "template",
"environment": "staging",
"run_list": [
"recipe[deployers::ubuntu]", "recipe[deployers::apps]",
"recipe[custom-apt-install]",
"recipe[rvm::system]", "recipe[rvm::gem_package]",
"recipe[nginx]",
"recipe[redisio]","recipe[redisio::enable]",
"recipe[locale]"
]
}
13 changes: 13 additions & 0 deletions site-cookbooks/custom-apt-install/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
custom-apt-install CHANGELOG
============================

This file is used to list changes made in each version of the custom-apt-install cookbook.

0.1.0
-----
- [your_name] - Initial release of custom-apt-install

- - -
Check the [Markdown Syntax Guide](http://daringfireball.net/projects/markdown/syntax) for help with Markdown.

The [Github Flavored Markdown page](http://github.github.com/github-flavored-markdown/) describes the differences between markdown on github and standard markdown.
68 changes: 68 additions & 0 deletions site-cookbooks/custom-apt-install/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
custom-apt-install Cookbook
===========================
TODO: Enter the cookbook description here.

e.g.
This cookbook makes your favorite breakfast sandwich.

Requirements
------------
TODO: List your cookbook requirements. Be sure to include any requirements this cookbook has on platforms, libraries, other cookbooks, packages, operating systems, etc.

e.g.
#### packages
- `toaster` - custom-apt-install needs toaster to brown your bagel.

Attributes
----------
TODO: List your cookbook attributes here.

e.g.
#### custom-apt-install::default
<table>
<tr>
<th>Key</th>
<th>Type</th>
<th>Description</th>
<th>Default</th>
</tr>
<tr>
<td><tt>['custom-apt-install']['bacon']</tt></td>
<td>Boolean</td>
<td>whether to include bacon</td>
<td><tt>true</tt></td>
</tr>
</table>

Usage
-----
#### custom-apt-install::default
TODO: Write usage instructions for each cookbook.

e.g.
Just include `custom-apt-install` in your node's `run_list`:

```json
{
"name":"my_node",
"run_list": [
"recipe[custom-apt-install]"
]
}
```

Contributing
------------
TODO: (optional) If this is a public cookbook, detail the process for contributing. If this is a private cookbook, remove this section.

e.g.
1. Fork the repository on Github
2. Create a named feature branch (like `add_component_x`)
3. Write your 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: TODO: List authors
7 changes: 7 additions & 0 deletions site-cookbooks/custom-apt-install/metadata.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name 'custom-apt-install'
maintainer 'YOUR_COMPANY_NAME'
maintainer_email 'YOUR_EMAIL'
license 'All rights reserved'
description 'Installs/Configures custom-apt-install'
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md'))
version '0.1.0'
Loading