
Completed
Posted
Paid on delivery
PostgreSQL High Availability with Docker and HAProxy (Reads and Writes) Overview: Set up a highly available PostgreSQL system using Docker containers on two computers. The system should ensure: The Primary Node runs on Computer 1 (handles both read and write operations). The Secondary Node runs on Computer 2 (read-only replica). Reads and writes should always be directed to the currently active node—whether that is the original Primary Node or the newly promoted Primary Node after failover. If the Primary Node goes down, the Secondary Node should automatically promote itself to Primary. HAProxy should handle the traffic routing so that the application only needs to connect to one host and port for both reads and writes, with the proxy determining which node is currently the Primary. Automatic failover and failback must occur seamlessly, ensuring no data loss. 1. System Setup Primary Node: Runs on Computer 1 and handles both read and write operations. Secondary Node: Runs on Computer 2 and is initially read-only. Docker Containers: Use Docker Compose to configure the services for the PostgreSQL nodes and HAProxy. 2. PostgreSQL Setup Streaming Replication: Set up PostgreSQL Streaming Replication between the Primary Node and Secondary Node to ensure data is synchronized. Failover Mechanism: Use Patroni (or similar) to automatically promote the Secondary Node to Primary if the Primary Node fails. The failover process should be automatic and transparent, with minimal disruption to the database. The Secondary Node will become the Primary Node in case of failure, and the new Primary should immediately start accepting writes. Role Reversion: When the Primary Node comes back online, it should resync with the new Primary and revert to the Secondary role without causing any data loss. 3. HAProxy for Active Node Detection HAProxy Setup: HAProxy will be configured to check the role of each PostgreSQL node (Primary or Secondary). HAProxy will always route read and write traffic to the active node. If the current Primary Node fails and the Secondary Node promotes itself to Primary, HAProxy will seamlessly reroute all traffic (reads and writes) to the newly promoted Primary without requiring changes from the application. Health Check Configuration: Set up HAProxy to perform health checks to determine if a node is still the Primary or if the Secondary Node has been promoted. For this, HAProxy can use e.g. PostgreSQL's replication status or Patroni's API to confirm the role of the node before routing traffic. Read/Write Traffic Routing: HAProxy will route write queries to the active Primary Node—whether it's the original Primary Node or the promoted Secondary Node. In case of failover, HAProxy will automatically detect the role change and route all future writes to the new Primary. 4. Failover & Failback Promotion: When the Primary Node goes down, the Secondary Node will automatically promote itself to Primary using Patroni or another failover mechanism. HAProxy will detect the role change and route all write traffic to the new Primary Node. Failback: When the Primary Node comes back online, it will synchronize with the new Primary Node (which was the Secondary before the failure) and revert to the Secondary role. HAProxy will reroute write traffic to the Primary Node and leave read traffic (if configured) to the Secondary Node. 5. Docker Configuration Docker Compose: Use Docker Compose to define the services for both PostgreSQL nodes and the HAProxy container. Configure HAProxy to listen on a single port (e.g., 5432) and forward traffic to the correct node based on the health check results. Set up networking between the HAProxy container and the PostgreSQL containers so that HAProxy can perform health checks and traffic routing.
Project ID: 38944852
23 proposals
Remote project
Active 1 yr ago
Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
23 freelancers are bidding on average €216 EUR for this job

Hi, I have done similar task for Mongodb with docker. Also i have created postgresql cluster multiple times earlier. So I can implement postgresql replication within docker container on multiple node. Thanks Ashish A.
€250 EUR in 7 days
4.5
4.5

Hello Lasse, I appreciate the opportunity to assist you with setting up a highly available PostgreSQL database system using Docker containers across two computers. Given the critical nature of data integrity and availability in your project, I'm confident in our ability to establish a robust architecture that meets your specifications. We will implement the primary and secondary nodes as per your requirements, ensuring seamless failover and failback with Patroni or a similar solution to manage promotions without data loss. Our experience with Docker and PostgreSQL will ensure that both nodes remain in sync throughout the process. Additionally, we will integrate health checks and a backup strategy to guarantee that your data remains secure and recoverable at all times. With over 5 years of experience in similar projects, I will take every necessary step to establish a fail-safe environment for your database. Could you please clarify your preferred method for monitoring the health checks and replication status during the setup? Thanks, Rashid
€250 EUR in 8 days
3.7
3.7

As someone with extensive experience in both Docker and PostgreSQL, I bring unique insights on how to optimize your high availability PostgreSQL system. Having successfully implemented similar projects, I understand the intricate balancing act required for effective Read/Write management, seamless failover, and active node detection. In fact, as a full-stack developer, I'm well-versed in all facets of your project including Docker-Compose configurations and HAProxy setup. One of my key strengths is understanding the specific interplay between tools like Patroni, HAProxy, and PostgreSQL itself; an understanding crucial to maintaining data integrity while ensuring efficient read/write traffic routing. In past projects, I've incorporated automatic failover mechanisms that are both automated yet non-disruptive to cater precisely to your needs. Moreover, my grasp on Docker networking and service definition will guarantee optimal simulations of Computer 1 - hosting your Primary Node & handling read/write operations and Computer 2 – running Secondary Node. My track record developing high-quality websites and mobile applications further underscores my commitment to delivering work with the highest level of integrity and efficiency. Let's build a robust PostgreSQL system - together!
€250 EUR in 7 days
3.5
3.5

Hello Dear! Good Day! Hope you are doing fine. This is Toriqul Islam . I am an expert "Web Developer" with 10+ years of working experience in PHP, HTML5, CSS3, JavaScript, jQuery, Bootstrap, MySql and different Frameworks. Hire me and you don't have to worry about your website problems again! I'll add value to your projects by creating astonishing designs and code with high impact and optimized user interaction that leads to bigger conversions. WHAT PROBLEMS CAN I HELP YOU SOLVE? Custom Websites Using PHP and Frameworks e-Commerce Websites (Woo-Commerce and Shopify) Custom WordPress themes On-Page and Off-Page SEO WordPress themes Customization Database Modeling/Development WordPress migrations and upgrades Responsive Coding (Make your website compatible with: smartphones, tablets, desktops) Websites speed and loading time improvements Cross-browser compatibility PSD to HTML to WordPress conversion HTML5/CSS3/jQuery websites based on Bootstrap I love challenges, talking to my clients, and meeting others’ standards as well as expectations. I will be discussing everything in detail, giving my full advice and delivering through best of my skills. You are cordially welcome to discuss your project. Thank You! Best Regards, Toriqul Islam
€140 EUR in 3 days
2.0
2.0

Hello Lasse B., I am Maryam Abbas, a PostgreSQL expert with 4 years of experience. I have carefully reviewed your requirements for setting up a highly available PostgreSQL database system using Docker containers. To ensure data integrity and seamless failover, I propose to configure PostgreSQL Streaming Replication between the Primary and Secondary Nodes. By implementing Patroni for automatic failover, the Secondary Node can promote itself to Primary in case of Primary Node failure, with data always kept in sync. Using Docker Compose, proper networking, and health checks, we will establish a robust system that guarantees no data loss during failover, failback, or restarts. You can view my portfolio at https://www.freelancer.pk/u/maryam951 and start a chat to discuss this project further. Best regards, Maryam Abbas
€75 EUR in 5 days
0.0
0.0

Hello Lasse B. Hope you are doing well! This is Efan , I checked your project detail carefully. I am pretty much experienced with PostgreSQL and Docker for over 8 years, I can update you shortly. Cheers Efan
€100 EUR in 2 days
0.0
0.0

I propose implementing a robust PostgreSQL High Availability setup using Docker containers on two separate computers. By designating Computer 1 as the Primary Node for read and write operations and Computer 2 as the Secondary Node for read-only replication, we can ensure seamless failover processes. Utilizing Docker and Docker Compose to manage PostgreSQL containers and replication, along with implementing failover mechanisms like Patroni, will guarantee data integrity even during node failures or restarts. The system's ability to automatically promote the Secondary Node to Primary in case of Primary Node unavailability, and vice versa, will maintain data synchronization and prevent any loss throughout the transition phases. To further clarify the scope of the project, could you provide details on the specific hardware specifications of Computer 1 and Computer 2? Additionally, do you have any preferences for monitoring tools or backup strategies to be integrated into the PostgreSQL setup? Your insights on these aspects will help tailor the implementation to meet your exact requirements and ensure a seamless PostgreSQL High Availability solution.
€250 EUR in 4 days
0.0
0.0

Hello Lasse B., We would like to grab this opportunity and will work till you get 100% satisfied with our work. We are an expert team which have many years of experience on PostgreSQL, Docker Please come over chat and discuss your requirement in a detailed way. Regards
€140 EUR in 7 days
0.0
0.0

Hi Lasse, I would like to grab this opportunity and will work till you get 100% satisfied with my work. As an experienced developer, I can complete your project with my relevant skills and experience in PostgreSQL, Docker. Lets connect in chat so that We discuss further. Regards
€190 EUR in 7 days
0.0
0.0

I am a skilled Python developer and experienced Machine Learning Engineer, capable of delivering solutions tailored to meet your specific requirements. Let me help you achieve your goals with precision and efficiency
€190 EUR in 2 days
2.7
2.7

Hello, how are you doing? I have considerable experience with setting up high availability systems using Docker and PostgreSQL. I have deployed multiple projects that involve automated failover and traffic routing, and I've successfully integrated HAProxy for seamless monitoring and load balancing. I can demo previous work if needed. Let me know if you need any further information or have questions. Thank you!
€250 EUR in 5 days
0.0
0.0

Hi I am proficient in devops engineer have setup custom postgres sql in production for our company i need to start with freelancing so quoting at lower price I
€30 EUR in 7 days
0.0
0.0

Hi Lasse B., I appreciate your detailed project description regarding the setup of a highly available PostgreSQL system with Docker and HAProxy. Your requirement for automatic failover and seamless traffic routing is critical for database stability and availability, and I can provide an efficient solution tailored to your needs. I am Muhammad Haroon, a professional with over 8 years of experience in database management and DevOps practices. My expertise in PostgreSQL, Docker, and high-availability architectures will ensure a robust implementation of your PostgreSQL setup with HAProxy for optimal traffic handling. Please find my previous work relevant to similar projects in my portfolio: https://www.freelancer.com/u/shehzadasalim I am excited about the opportunity to collaborate with you on this project and look forward to discussing it further. Thank you, Regards, Muhammad Haroon
€140 EUR in 3 days
0.0
0.0

Nice to meet you LasseBoenecke, It is a pleasure to communicate with you. My name is Anthony Muñoz, I am the lead engineer for DSPro IT agency and I would like to offer you my professional services. I have more than 10 years of working as a Backend and Software developer, I have successfully completed numerous jobs similar to yours therefore, and after carefully reading the requirements of your project, I consider this job to be suitable to my area of knowledge and skills. I would love to work together to make this project a reality. I greatly appreciate the time provided and I remain pending for any questions or comments. Feel free to contact me. Greetings
€428 EUR in 7 days
0.0
0.0

Hello, Thanks for sharing your job detail and post. After having gone through your job detail, that your PostgreSQL project requires a highly-skilled and experienced professional. Being a renowned expert in Docker, this project aligns perfectly with my skill set. I have a proven track record of delivering robust Dockerized solutions that ensure high availability and scalability. In the past, I have designed and implemented complex Docker environments for various systems, including large-scale databases like MySQL and Oracle. My in-depth understanding of Docker Compose and orchestration tools such as HAProxy will enable me to seamlessly set up a multi-node PostgreSQL cluster, handling both read and write operations while guaranteeing minimum downtime and data loss through automated failover mechanisms. Can we connect here for a quick discussion? PS: My hourly rate is USD-30/hr Thank you!
€30 EUR in 7 days
0.0
0.0

With extensive experience on DevOps, I have multifaceted tech experience with Docker Container and Load balancing with Haproxy.
€210 EUR in 7 days
0.0
0.0

Strande, Germany
Payment method verified
Member since Aug 27, 2021
€250-750 EUR
€250-750 EUR
€30-250 EUR
€30-250 EUR
€30-250 EUR
₹12500-37500 INR
₹750-1250 INR / hour
£20000-50000 GBP
₹37500-75000 INR
$30-250 USD
$30-250 USD
₹400-750 INR / hour
₹12500-37500 INR
$15-25 USD / hour
$30-250 USD
₹12500-37500 INR
₹1500-12500 INR
₹12500-37500 INR
$30-250 USD
₹12500-37500 INR
$15-25 USD / hour
£1500-3000 GBP
$30-250 NZD
$15-25 USD / hour
$1500-3000 USD