Skip main navigation

New offer! Get 30% off one whole year of Unlimited learning. Subscribe for just £249.99 £174.99. New subscribers only T&Cs apply

Find out more

IaaS/PaaS/Containers

.
17.1
Now, when we’re configuring standard environments and dealing with infrastructure as code as well as configuration as code, there’s some things we need to think about. And that’s what our target environment is going to be. There are three very common environments at play– as well as others, I suppose. But infrastructure as a service is a big one, platform as a service is another, as well as containers. And I want to talk about those three separately because they are different in the way that we approach both infrastructure as code and configuration as code as well. Let’s start with infrastructure as a service. So with infrastructure as a service, the machines are generally hosted for you.
55.9
Now, this may be in your own data centre or, more likely, out in a cloud environment. And we might choose those infrastructure as the service environments based on our application. Maybe we need access to the underlying infrastructure of some nature. But when we scale this, we’re going to grow it by adding machines on to whatever farm is serving up that application. The key here, though, with infrastructure as a service, we need to have some very sophisticated infrastructure as code and configuration as code tools.
90.4
So for instance, if we want to deploy an entire server farm for our application and make sure that all of the connections are correct, et cetera, we’ll be using something like Chef, or Puppet, or Ansible, SaltStack, ARM templates, Azure Resource Manager templates, or other tools that work both in the cloud and potentially on-premises as well to define what those machines look like. And we have to care about those machines at quite a deep level. We need to care about the operating system, the patching, how the ports are opened, et cetera.
123
So in an IaaS environment, commonly, you will have scripts that sit in version control, but outside of the application, that work to host that application and to coordinate that infrastructure to host the application. Let’s move from IaaS to platform as a service. Now, in platform as a service, we’re working against a hosted platform that kind of defines an infrastructure for us. So for instance, if you’re the Azure platform, you might deploy to an app service. And that website is– you can just deploy the website. All of the scaling and everything is handled for us. Again, you need to determine whether or not your application is supported by a PaaS environment.
165.3
One of the interesting things, however, is that on a platform as a service environment, generally, in the infrastructure as code as well as the configuration as code, is fairly dramatically simplified into some type of configuration file that often sits with the application itself in version control. Not necessarily, but very often. Because once we deploy the application and all of its dependencies, we need to define what that looks like. And platform as a service generally has that baked in to how you spin up an application on that platform. So that’s platform as a service, and it’s a little bit different than we did as infrastructure as a service.
209.3
Generally, it tends to have a lower barrier to entry– a lower bar– and not as much complexity because the tools are baked into the platform itself that are used to scale, and grow, and shrink as necessary as well as secure all of the other things that you might configure in that application. Now let’s take a look at the third, and that third is containers. And containers are predominantly Docker. When we’re talking containers, we’re talking Docker, whether that Docker is running on a Linux machine or coming soon in the Windows world is Containerised Windows as well– both managed by that Docker application. Now, these containers, let’s define them real briefly.
253.3
We can partition our environments in these containers that run on a shared OS, and we can run a lot of containers on one single OS. They tend to be considered much lighter-weight than something like a virtual machine. But when we’re talking the configuration of that machine, we’re talking things like Docker files and those sorts of things that help build that container up from scratch. When we’re talking environments, however, now we want to look across the environment, and we’re looking at other tools like Docker Swarm or something else to orchestrate the multiple Docker containers to create that managed environment. Docker Swarm would be one, Mesosphere DC/OS, Kubernetes, Azure Container Service.
299.3
These are all tools that help us create that infrastructure as code and configuration as code for a container. Now, in all cases, infrastructure as a service, platform as a service, and containers, we’re looking at wanting to make sure that we have that same configuration, similar environments in dev, test, and production. as And that’s why we set up this infrastructure code and configuration as code. Those three tools that we talked about, slightly different approach to each of those, but all very important that we have those core fundamentals in our DevOps pipeline.

In the previous step, we examined database as code. This step describes various types of target environments that we need to think about when we are dealing with Infrastructure as Code and Configuration as Code.

There are three very common environments at play when we consider target environments:

  1. Infrastructure as a Service (IaaS)
  2. Platform as a Service (PaaS)
  3. Containers

Infrastructure as a Service

With Infrastructure as a Service, the machines are generally hosted for you. It is typically an instant computing infrastructure, provisioned and managed over the internet in the cloud. Choosing an Infrastructure as a Service environment depends on the application you are using and scaling is done by adding machines instead of percentage.

The key with Infrastructure as a Service is that you need to have very sophisticated Infrastructure as Code and Configuration as Code tool. You will commonly have scripts that sit in version control, but outside of the application, that work to host that application and coordinate that infrastructure to host the application.

Platform as A Service

In a Platform-as-a-Service, you working against a hosted platform that defines an infrastructure for you. In this environment, Infrastructure as Code and Configuration as Code is fairly dramatically simplified into some type of configuration file that often sits with the application itself in version control.

A benefit of using a Platform as a Service is that the tools required for scaling, shrinking and securing applications and environments, are built into the Platform as a Service.

Containers

You can partition your environments in containers such as Docker and are considered lighter weight than virtual machines. You can run one or multiple containers on a shared OS.

To build your container up, you typically make use of Docker files. To orchestrate multiple Docker containers to create a managed environment, you can use Docker Swarm or something similar. This will help you create Infrastructure as Code and Configuration as Code for your containers.

Join the discussion

Do any of the three options described here appeal to your current projects’ needs? How are you currently handling machine & environment virtualisation?
Use the discussion section below and let us know your thoughts. Try to respond to at least one other post and once you’re happy with your contribution, click the Mark as complete button to check the step off, then you can move to the next step.

In the next step, we will learn about infrastructure as a service environment.

This article is from the free online

Microsoft Future Ready: Fundamentals of DevOps and Azure Pipeline

Created by
FutureLearn - Learning For Life

Reach your personal and professional goals

Unlock access to hundreds of expert online courses and degrees from top universities and educators to gain accredited qualifications and professional CV-building certificates.

Join over 18 million learners to launch, switch or build upon your career, all at your own pace, across a wide range of topic areas.

Start Learning now