chef simplified: helpful tips for removing complexity

37
A Simplified Guide to CHEF.IO Remove the complexity of deploying Chef cookbooks, making them easily accessible to everyone

Upload: flexiant

Post on 05-Aug-2015

1.060 views

Category:

Technology


2 download

TRANSCRIPT

A Simplified Guide to

CHEF.IORemove the complexity of deploying Chef cookbooks,

making them easily accessible to everyone

Situation: Deploying a Chef Cookbook to an App in the CloudSituation: Interconnecting Chef RolesSituation: Auto-scaling with Chef

Three Chef Situations to Simplify

Situation 1: Deploying a Chef Cookbook

to an App in the Cloud

• Your goal is to deploy a Chef cookbook to an application in the cloud.

• You have the cookbook from the Chef Supermarket, or your own, which describes an application that is specific to you.

• The Chef cookbook contains all the steps to get your application up and running, so it should be an easy task, right?

It isn’t an easy task.

Guess what?

Steps to Deploying a Chef Cookbook to an App in the Cloud

Phew that’s a lot.

1. Set up a Chef infrastructure, namely a Chef server & a client.

2. Install and set up a Chef server, or alternatively subscribe to Hosted Chef.

3. Make sure your selected cookbook is available on the Chef server, and configure the role for your application properly including specific variables (the “attributes”) that your application needs, for example the password of the database.

4. The Chef client will have to run on the cloud node that will host your application.

5. Create this node on your preferred cloud. 6. Make a choice between cloud providers. 7. Use either the cloud provider’s control panel, API or

maybe Chef knife with an appropriate plugin to create it, with the required compute and storage resources.

8. Install the Chef client on the cloud node, either manually or by utilizing the knife bootstrap command.

9. Assign the cloud node to the role specified earlier, and execute the role to initiate the bootstrap operations.

10.If you need to register your node to extra services like New Relic for monitoring or SumoLogic for machine data analytics, you need to either modify your cookbook or, if you’re not comfortable with it, run custom bootstrap scripts manually.

After all those steps and time, your vanilla cloud node has finally become your desired application.

But you still have more work to do...

Problem: Wasted Time and Resource

• Your application probably needs to serve some kind of web workload, so you have one more step: dig for the IP address that was assigned by the cloud provider and map it to a DNS entry.

(You’ll probably use yet another third party management console)

• Now you need to repeat the last part of this process for every cloud node that needs to be part of that role.

• If you have an array of servers performing the same role, this process needs to be completed manually each time you want to grow the array.

Cut down this time

consuming and resource hungry

process.

Easily Deploy a

Chef Cookbook to an App in

the CloudSOLUTION:

Use to deliver what goes between a cookbook and a fully deployed application in the cloud.

is the fastest way to deploy and automate applications consistently across multiple clouds.

Much of this automation comes from its deep integration with Chef.

1. Select or upload a cookbook2. Create and configure a blueprint from your chosen recipe3. Spin up server from blueprint on chosen cloud provider in

chosen geography– Or spin up multiple identical servers (server array) from same

blueprint, automatically added to the embedded load balancer pool

4. Bootstrap the server(s)5. Automatically install and register agents e.g. New Relic6. Map servers to embedded geo-DNS servers with domain of

choice

Solution: Flexiant Concerto

Chef Cookbook is easily deployed to

an app in the cloud.

Situation 2: Interconnecting Chef Roles

• You need your application to scale to meet unpredictable workload demand.

• With the cloud, you can easily create all the pieces required to build a scalable application.

Problem: Complexity

All of this creates a great deal of complexity that is only going to grow as you continue to scale.

All components need to talk to each other to make sure the application as a whole is going to work. Your application requires a clearly defined topology.

CHEFChef is a big help.

Chef roles automate the application blueprinting, managing the configuration of

the infrastructure components. It significantly reduces the admin overhead

required.

• Even with the help of Chef, interconnecting all the various roles is a big project.

• Chef’s remit doesn’t include the big picture and the whole application topology.

Problem: Solving

Complexity is No Small Task

Ensure the communication between

roles.

Problem: Ensure the communication between roles.

Phew that’s a lot. Thoughts?

1. Ensure Chef is working and that each node that makes your application is properly associated to its role.

2. Configure roles and back them with the relevant cookbooks from the Chef Supermarket, or write them yourself.

3. Once all roles have been executed and your nodes are up and running, you need to make sure that each node, representing a component of your application, is interconnected with the others.

4. Application servers need to be informed of where the database or the cache layer is, and this requires your understanding of the IP address given by the cloud provider as well as a specific configuration change to each application server. Chef, again, can help. You would simply need to change the role configuration and force the convergence. This will automatically update all affected nodes and establish the required connection.

5. Have your application automatically scale to handle temporary peaks. This is where you have a problem.

6. When all the above needs to happen automatically, service discovery and automatic interconnection of roles is problematic. And the more nodes you have in your application topology, the bigger an issue this becomes.

Solution: Bypass the Manual Steps with Flexiant Concerto1. Select or upload a cookbook2. Automatically– Spin up servers– Install Chef– Execute and converge roles– Map IP address to embedded

geo-DNS service

3. Bootstrap nodes with a click4. Scale the application

automatically:– Spin up servers– Interconnect roles– Include in load balancing

pools

Easily automate the communication of Chef

roles with Flexiant Concerto.

Situation 3: Auto-scaling with Chef

You have deployed a multi-tier web application in the cloud, with each tier made up of a few servers. As demand fluctuates, you’ll either have: • Too little server resource and your

application user’s experience will suffer

• Too much and you are over provisioning and over spending on infrastructure.

 

• Manual application performance tracking to adjust infrastructure manually is a waste of admin resource.

• You need an auto-scaling solution so you select Chef so your application can be easily replicable.

CHEFitself is not enough.

You Need Auto-Scaling

• You Need a Monitoring Solution

• You Need to React to Metrics

• You Need to Scale Up AND Down

• You Need Powerful Auto-scaling for Infrastructure Resources

Solution: Infrastructure is Chef Powered, Apps Easily

Replicable and Auto-Scaled

1. Configure template based on Chef role with New Relic license key

− Concerto monitors application performance

− Generates Apdex score

2. Configure rules within Concerto for the Apdex scores at which to scale out and in

3. Implement Concerto auto-scaling:− When Apdex score goes below scale

out threshold, new servers are spun up to optimize performance

− When Apdex score goes above scale in threshold, surplus servers are killed off to control costs

delivers everything you need for your application to

continue to run successfully and to address the increased demand, thus ensuring that user experience is optimal.

With Flexiant Concerto, prepare your application on

the right foundations like Chef, gathering the most reliable

data with New Relic, allowing you to finely tune your auto-

scaling policy.

Flexiant Concerto gives you an intuitive UI and an API to deliver the orchestration required to transform amazing Chef cookbooks into a fully distributed and scalable application

topology.

Get your job done better by automating repetitive tasks across the best cloud for your project.

Get the Job DoneHate getting locked in to one cloud? Take control by using whatever cloud you want to get the best price, performance or geographical reach based on what you want.

Got an idea? Imagine new products and deploy them quickly to deliver value faster. Use continuous integration/ continuous delivery across multiple clouds to achieve quick application development.

Be Free Imagine and Innovate

What’s the impact Flexiant Concerto has on overall organizational

performance: profitability, market share and productivity?

Low risk

Remove barriers to productivity by automating core and non-core components, consistently across the best cloud for the project/department/business

Low cost

High productivity

Market share

Innovate for your business, not for the technology to run it

No wasted financial resources on in-house development

No vendor lock-in

Don’t waste time and expense

Get cloud freedom today. Build, deploy and manage applications across multiple clouds today with Flexiant Concerto.

Save yourself the wasted time and expense of doing nothing or doing it yourself by using a solution to deploy and automate applications consistently across multiple clouds.