Hello, and welcome to this presentation from Pluralsight. My name is
Andrew Mallett, and I'm going to be your instructor as I help guide
you through the module where we take a look at Implementing Chef for
Configuration Management.
When we look at understanding a little bit about Chef,
we'll find out that it's owned by a company called Progress, and the project is
chef.io. And we've got different products within the suite,
the workstation, which is really the development side of Chef,
the infra server, and the client.
It can also be run in a standalone mode, and much in the same way as we've
been looking at most of the other server client products,
we'll be looking at Chef in a standalone client‑only mode. It's based on
Ruby, and that means that our recipes, which hold our state
configuration, are going to be stored in .rb files.
Now we're going to be working on our Ubuntu 2004 system. Within Ubuntu 2004,
the standard repositories do have the Chef package. So we'll make sure that
we're up to date and then go through and install Chef.
Once we've got that installed, we can use the
chef‑client ‑v to print our version.
Once again, we're going to find that Ruby can be a little bit
chatty, so we're going to divert all of the error messages
through to dev/null so we get a clean output, and we're able to
easily see the client version.
Now I think at this stage we should encourage you to dive out to your
command line so you can follow through and really gain some practical and
hands‑on experience. Making sure that you're working on our Ubuntu system,
we're going to install Chef and check its version. And here we are then at
our wonderful learning environment, the command line.
I've already updated my package cache, so I'm going to go
straight ahead and run my apt install ‑y and then the package
in our standard repositories is chef.
Now we can see we get a dialog box to put in the address of our Chef server.
We're using a standalone environment, so I'm just tabbing through to okay, and
I'm going to allow then that to be left empty. If we ever then transfer back to
a server environment, we could reconfigure the package, or we could go through
and set up our /etc/chef/client.rb.
Now we can see going through the installation, how Ruby based Chef is.
We can see most of the packages are prefaced with Ruby, and
now that our installation is finished,
we can go ahead and run the chef‑client. ‑V is going to give us our version.
Now as we said in the slides, we're going to redirect error messages
because we're going to get a lot of Ruby warnings, but we can
redirect them through to dev/null, and then we can see then our
version, 15.8, clearly on the screen.
So we're up and running. We're at the first stages, if you like,
of learning Chef, and we can progress now by taking a look at some
of our basic recipes, and we're going to be able to create a
recipe that will go through and clone our course Git repository, so I can't wait to see that.