Git Product home page Git Product logo

learn-chef's Introduction

Learning Chef (Sandbox)

This is my chef sandbox, this repository host code of my crash course trying to understand and make Chef-Solo work with Vagrant.

The work done here is a mashup of Chef documentation, Peepcode screencast and recently rubygems-aws recipes.

I've added to the mix Berkshelf so I can manage the recipes without downloading them into my repository.

I haven't scratched the surface of Chef, heck, most likely I have no idea what I'm doing ๐Ÿ˜ƒ

Objectives

Not only be able to understand the mixture of concepts of Chef (recipe, role, knife, data_bags, attributes, templates, ough) but also be able to get my own customized environment.

At this time I'm mixing everything into one single box (app_db) but ideally it should be able to scale and configure different apps servers from db servers.

Questions I have

  • I want to run multiple applications on the same box, should I define each one as a recipe?

  • Each application should have it's own database

I saw database cookbook might offer what I need, but still don't know how to use it (goes along the application? should be a data_bag or attributes?)

  • Applications should be using Nginx + Puma (sockets)

I want each application uses Puma so rolling deploys can be achieved. (While I know unicorn does, I'm not a fan of it, Puma model works better to me).

Getting Started

This repository uses Bundler to manage the Ruby dependencies

gem install bundler
bundle install

Once all the gems (berkshelf, vagrant, chef) are installed, you can install the cookbooks:

berks install

All those will be installed in ~/.berkshelf

Now, you can start the app_db box with chef-solo:

vagrant up app_db

And provision it every time:

vagrant provision app_db

Copyright

As mentioned before: none of the ideas here are originally mine, I bluntly stole code from everywhere (thanks Google!), so feel free to use it as you please, but don't sue me if things don't work.

learn-chef's People

Contributors

luislavena avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.