Ansible Tower and Postgres Reference Architectures

February 11, 2021

At EDB, we are always seeking ways to innovate and integrate with other products. In this blog post, we will be discussing the EDB Postgres Reference Architectures and deploying them using “edb-ansible” Scripts or ”edb-postgres” Ansible Collection with Redhat’s Ansible Tower.

 

EDB Postgres Reference Architectures

The Postgres Reference Architectures provide different types of core architectures for cluster deployments. They help simplify and serve as a reference for different implementations of nodes sizes and technologies involved. For example:

Reference Architecture

Components

Further detailed at:

https://github.com/EnterpriseDB/postgres-deployment

EDB-RA-1

1 Postgres Node, 1 Backup Server and 1 PEM Monitoring Server

EDB-RA-2

3 Postgres Nodes, 1 Backup Server and 1 PEM Monitoring Server

EDB-RA-3

3 Postgres Nodes, 1 Backup Server, 3 PgPool Nodes and 1 PEM Monitoring Server



The Postgres Reference Architectures have been added as options in the “EDB Postgres Deployment Scripts,” “edb-ansible” GitHub Repository and the “edb-postgres” Ansible Collection.

Illustrated below is a diagram showing the “edb-ansible” GitHub Repository and the “edb-postgres” Ansible Collection possible target clouds.


What is Ansible Tower and where does it come into play?

How do the Postgres Reference Architectures come into play with Ansible Tower? The answer: “The Postgres Reference Architectures are utilized by the “edb-ansible” GitHub Repository and the “edb-postgres” Ansible Collection to configure the target clouds.”

Many organizations utilize Ansible as part of their DevOps initiatives, but others have added to their toolset: Ansible Tower. Ansible Tower adds more capabilities—to mention a few: User Interface, API, Command Line Interface, Dashboard, Jobs, Projects, Templates, Scheduling, etc. Because of all these extra capabilities, not only did it make sense but it was also the logical choice to integrate our “edb-postgres” Collection/”edb-ansible” GitHub Repository with Ansible Tower.

That said, because of the differences between Ansible and Ansible Tower there is the need to create additional components and setup for a successful execution of a “Template.” 

The required components are: 

  • 2 Inventories
  • 2 Credentials
  • 2 Projects
  • 1 Template


A high-level overview and additional details are included in the diagram below:

Based on Red Hat Ansible User guide.

As illustrated, it is not a complex structure just a bit different from what one is used to with Ansible. A benchmark on a basic single node installation of Ansible Tower with 2 Processors yielded a 40 minutes completion, larger configurations of Ansible Tower with double or more processors will reduce the time in half or more. 


A successful execution just like in Ansible will be identifiable by the play results displaying: “failed=0” across all the nodes.

Authentication credentials for the cluster are setup by the Playbook execution. What happens if you need to authenticate with credentials into the Cluster? The recommended option would be to reset your password, as detailed in this blog posting: “Postgres, Passwords and Installers”.

 

Up Next

So how do we setup and execute a job in Ansible Tower? Those topics will be answered in the next series of blog postings detailing how to configure each of the Ansible Tower components.

Stay tuned for the next blog topics to be discussed in this series, which include:

  • Configuring Inventories for “edb-ansible” Scripts on Ansible Tower
  • Configuring Credentials for “edb-ansible” Scripts on Ansible Tower
  • Configuring Projects for “edb-ansible” Scripts on Ansible Tower
  • Configuring Templates for “edb-ansible” Scripts on Ansible Tower


To learn more ways to automate the deployment of reference architectures, check our our on-demand webinar! 
 

Share this

More Blogs