Reader small image

You're reading from  Infrastructure as Code (IAC) Cookbook

Product typeBook
Published inFeb 2017
PublisherPackt
ISBN-139781786464910
Edition1st Edition
Right arrow
Authors (2):
Stephane Jourdan
Stephane Jourdan
author image
Stephane Jourdan

Stephane Jourdan is a passionate infrastructure engineer, enthusiastic entrepreneur, zealous trainer, and continuous learner, working on innovative infrastructures since the early 2000s. He focuses equally on tools and culture, in environments as different as startups, online audio/video media, e-commerce, and semi-conductors. The common point between all these experiences is that success comes with rigor, technical repeatability, communication, and a shared team culture. He co-founded an infrastructure automation consultancy (https://www.linkedin.com/company/green-alto), a web radio (http://phauneradio.com/), a container/serverless platform for developers (https://www.squarescale.com/), and a sound design studio (http://www.tarabust.com/). When Stephane isn't starting or contributing to new open source projects, he's usually found hiking in remote places with his camera.
Read more about Stephane Jourdan

Pierre Pomès
Pierre Pomès
author image
Pierre Pomès

Pierre Pomès is a senior enthusiastic engineer of open source technologies and a Linux adept since 1994. He has been working in the IT industry for the last twenty years mostly in C development, system administration, and security including PCI-DSS. He is currently an architect and a DevOps team leader for Reservit, an online hotel booking engine. He has also contributed to the pfSense project.
Read more about Pierre Pomès

View More author details
Right arrow

Using cloud-init on AWS, Digital Ocean, or OpenStack


As cloud-init is an initialization system for cloud instances, we need to find a way to send the cloud-config YAML file to the bootstrapping process. On all IaaS providers supporting cloud-init, there's a field where we can paste our file. We'll review how cloud-init works on three important IaaS providers—AWS, Digital Ocean, and OpenStack.

Getting ready

To step through this recipe, you will need an account on Amazon Web Services, Digital Ocean, or some OpenStack deployment, or on all of them if you want to try them all!

How to do it…

To illustrate cloud-init usage, we'll create the simplest cloud-config file on Ubuntu 16.04 and CentOS 7.2, installing packages such as htop, tcpdump, docker, or nmap that aren't usually installed by default on most Linux distributions. This is how a very simple cloud-config file looks:

#cloud-config
# Install packages on first boot
packages:
  - tcpdump
  - docker
  - nmap

Using cloud-init on Amazon Web Services...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Infrastructure as Code (IAC) Cookbook
Published in: Feb 2017Publisher: PacktISBN-13: 9781786464910

Authors (2)

author image
Stephane Jourdan

Stephane Jourdan is a passionate infrastructure engineer, enthusiastic entrepreneur, zealous trainer, and continuous learner, working on innovative infrastructures since the early 2000s. He focuses equally on tools and culture, in environments as different as startups, online audio/video media, e-commerce, and semi-conductors. The common point between all these experiences is that success comes with rigor, technical repeatability, communication, and a shared team culture. He co-founded an infrastructure automation consultancy (https://www.linkedin.com/company/green-alto), a web radio (http://phauneradio.com/), a container/serverless platform for developers (https://www.squarescale.com/), and a sound design studio (http://www.tarabust.com/). When Stephane isn't starting or contributing to new open source projects, he's usually found hiking in remote places with his camera.
Read more about Stephane Jourdan

author image
Pierre Pomès

Pierre Pomès is a senior enthusiastic engineer of open source technologies and a Linux adept since 1994. He has been working in the IT industry for the last twenty years mostly in C development, system administration, and security including PCI-DSS. He is currently an architect and a DevOps team leader for Reservit, an online hotel booking engine. He has also contributed to the pfSense project.
Read more about Pierre Pomès