We can safely say that expecting SSH connectivity from a server is definitely not inconceivable. That means that as long as you have Python installed, and you have an SSH server running on the hosts you wish to configure, you can run Ansible with no problem. To avoid a single point of failure, Ansible was created.Īnsible, like Puppet and Chef, sports a declarative, domain-specific language, but in contrast to them, Ansible follows a “push-based” method. Also, the configuration of these clients is still quite complex, and if the master node which stores the configurations is down, all we can do is to fall back to the old command line / bash script method if we need to quickly update our servers. However, one could argue that the need for a preconfigured client makes them a bit clumsy. It is also convenient that they apply the desired configuration automatically after spinning up the machines. Using their domain-specific language was definitely clearer and more self-documenting than writing bash scripts. When new machines are spun up, they need to have a configured client that pulls the configuration definitions from the server and applies it to itself. This means that you define the configuration – using their respective domain-specific language- which is stored on a server. Both of them were responses to the widespread adoption of using clusters of virtual machines that need to be configured together.īoth Puppet and Chef follow the so-called “pull-based” method of configuration management. What are these declarative approaches?įirst, Puppet was born, then came Chef. This is the idea behind the Infrastructure as Code (IaC) concept: handling the state of infrastructure through idempotent changes, defined with an easily readable, domain-specific language. To alleviate the pain caused by the drawbacks of defining our server configurations by bash scripts, we needed a declarative way to apply idempotent changes to the servers’ state, meaning that it does not matter how many times we run our script, it should always result in reaching the exact same expected state. The script might run successfully, simply break, or things could completely go haywire. There’s also the question of what happens if someone SSH-s into the server, configures something through the command line, then later someone would try to run a script, expecting the old state. When relying on bash scripts, implementation details or small differences between machine states can break the configuration process. However, the problem with bash scripts is that they are quite difficult to read, but more importantly, using bash scripts is a completely imperative way. Since the dawn of complex Linux server architectures, the way of configuring servers was either by using the command line, or by using bash scripts. Okay, let’s start with understanding the IaC Concept! What is Infrastructure as Code?
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |