O'Reilly logo

Salt Cookbook by Anirban Saha

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 2. Writing Advanced Salt Configurations

In this chapter, you will cover:

  • Writing and retrieving pillar data
  • Using pillar data in states
  • Using grains in states
  • Using conditionals in states and pillars
  • Using Python functions in conditionals
  • Using iterations in states
  • Setting and using variables in states
  • Testing a state run before applying to minions
  • Configuring nodegroups
  • Targeting minions

Introduction

Now that we have gotten our hands dirty with the basics of Salt, in this chapter we are going to dive deep into the advanced configuration of Salt.

One of the notable features of Salt is flexibility, and being based on the dynamic Python language, Salt allows us to incorporate and take advantage of a large number of Python utilities into its configurations. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required