Giter VIP home page Giter VIP logo

chef-solo-laptop's Introduction

Chef Solo Laptop

This repository contains chef cookbooks and recipes for the provision of my laptop.

Chef

Chef provides a means to provision a (cluster of) machine.

Because we do not want to depend on a chef-server we opt to use the chef-solo instance.

Procedure

In this section the procedure for getting the provision of a laptop up and running is described here. A summary is given below.

Summary

  • Ubuntu (12.04)
  • Git
  • Clone Repository
  • Install Chef Solo
  • Run Chef Solo

Ubuntu

Install the latest version of Ubuntu. When this procudure was described the latest version was Ubuntu 12.04 LTS Precise Pangolin.

Git

Execute the command below to install git.

sudo apt-get install git

Git is used to retrieve this repository which contains all the utility scripts, cookbooks and recipies needed to get started.

The above step is captured into scripts/install-git.sh

Clone Repository

Choose an appropriate directory in which to clone this repository. In that directory execute the following command

git clone git://github.com/dvberkel/chef-solo-laptop.git

This will clone the repository into a directory called chef-solo-laptop.

The command above can be found in the script scripts/clone-repository.sh

Install Chef Solo

Chef Solo need to be installed to run the various cookbooks and recipies. Detailed information can be found on the installation page at Opscode. We will list the commands that need to be executed. These commands are captured into the scripts/chef-solo.sh script. This script can be executed instead of running the commands below.

We are using the Opscode APT repository. This way it is easy to keep Chef up to date. Execute the following command to add the Opscode APT to the source list.

echo "deb http://apt.opscode.com/ `lsb_release -cs`-0.10 main" | sudo tee /etc/apt/sources.list.d/opscode.list

The next step is adding the OpsCode GPG key so the downloads can be verified.

sudo mkdir -p /etc/apt/trusted.gpg.d
gpg --keyserver keys.gnupg.net --recv-keys 83EF826A
gpg --export [email protected] | sudo tee /etc/apt/trusted.gpg.d/opscode-keyring.gpg > /dev/null

Update the index with the following command

sudo apt-get update

And install opscode-keyring to keep the keyring up to date.

sudo apt-get install opscode-keyring # permanent upgradeable keyring

To ensure we use the latest libraries that Chef depends on we have to upgrade the installation.

sudo apt-get upgrade

Finally install chef via apt-get.

sudo apt-get install chef

Because we are only intend to run Chef Solo the Chef Server Url can be set to 'none'. (The install script has these values preseeded.)

Run Chef Solo

Now that Chef Solo is installed we should use it. Execute the following command to provision your laptap.

sudo chef-solo -c solo.rb -j solo.json

This will execute the recipe in cookbooks/basic-setup/recipes/default.rb

The above command can be executed with the scripts/provision.sh script.

Basic Setup

The basic setup for the computer is described in the basic-setup cookbook, in particular in the default recipe.

The documentation about resources is a good place to start understanding the syntax of various elements in the recipes.

chef-solo-laptop's People

Contributors

dvberkel avatar

Watchers

 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.