The Random Walk Blog

2024-05-25

Deploy Smarter and Effortless: Our Journey with Coolify

Deploy Smarter and Effortless: Our Journey with Coolify

Efficient deployment pipelines are significant for delivering software features swiftly and smoothly. We have experimented with several tools and methods to address the challenges and streamline the deployment processes. Recently, we implemented Coolify, a self-hosted platform that has remarkably simplified our deployment workflows. This blog details our journey from implementing Coolify to experiencing how it simplifies our deployment workflows and enhances our overall development lifecycle.

What is Coolify?

Coolify is an open-source, self-hostable platform that merges the flexibility of cloud services with direct control over managing servers, applications, and databases on your own hardware. It allows you to manage everything through a simple SSH connection. It serves as an alternative to platforms like Heroku, Netlify, and Vercel, but without the vendor lock-in. This ensures that all configurations for your applications and databases are saved on your server, allowing you to manage your resources even if you stop using Coolify. It supports managing various types of hardware, including VPS, Bare Metal, and Raspberry PIs.

Why Coolify?

Before Coolify, our deployment pipeline primarily relied on GitHub Actions and Jenkins. While these tools are powerful and flexible, they require significant time and effort to set up and maintain. We had to create and manage numerous pipelines, configure DNS settings manually, and handle environment-specific deployments. This often led to delays and a higher potential for human error.

Coolify presented itself as an elegant solution to these challenges. It promised to streamline our deployment process, reduce the need for manual configurations, and provide an intuitive interface for managing multiple environments.

Setting Up Coolify

We ensured we had a registered domain with Cloudflare, a remote server from Hetzner that supports SSH access, a prepared Git repository for our app, and optionally created an SSH key for secure server access. This is to enhance our security when accessing the server.

Set Up Our Server on Hetzner

We selected a server location close to our user base. Here’s a brief overview of our server configuration:

Operating System: Ubuntu 22.04

Memory: 8GB RAM

Storage: 100GB SSD

CPU: 4 Cores

Using the IP address provided by Hetzner, we connected to the server via SSH using the following command.

ssh root@<server_ip_address>@

Installing Coolify

We installed Coolify on our server with the following command:

curl -fsSL https://cdn.coollabs.io/coolify/install.sh | bash

The process was straightforward, allowing us to get Coolify up and running quickly.

Accessing and Configuring Coolify

We opened the provided IP address, ported it to our browser, and registered with a strong, unique password. We set up the server by selecting “localhost” and followed the prompts to create and configure our project. To integrate our GitHub repositories with Coolify, we configured the Coolify GitHub app as the source. This setup allowed us to manage different environments for each project effortlessly. It ensured a robust and efficient deployment pipeline, covering development, staging, and production environments.

Configuring Cloudflare

We set the SSL/TLS mode to “Full (strict)” to avoid redirect loops and added an A record in Cloudflare’s DNS management, pointing to our Hetzner server IP for the subdomain.

Finalizing Coolify Configuration

In Coolify settings, we set the instance’s domain to https://coolify.our_domain and redeployed the project to apply the domain changes.

dashboard (2).svg

Redirecting WWW to Non-WWW

We created A and AAAA records for the www subdomain in Cloudflare, pointing to dummy IPs. Then, we set up a redirect rule to direct www traffic to the root domain. With these steps completed, we successfully set up a self-hosted PaaS using Coolify and configured our domain.

Benefits of Using Coolify

Using Coolify has significantly streamlined our deployment process, providing us with numerous benefits.

Reduced Time Spent on DevOps

One of the most significant advantages of using Coolify is that it reduces the time spent on DevOps tasks. Previously, setting up deployment pipelines with GitHub Actions and Jenkins required considerable effort. We connected our GitHub repositories and set up the necessary environments for each project. Coolify’s integration with GitHub made managing our source code and deployment processes easy from a single platform. Its intuitive interface and automation capabilities have significantly reduced the time and effort required for managing deployments.

sources.svg

Simplified DNS Configuration

Configuring DNS settings manually was a tedious task. We used to set up custom domains by manually setting A records on Cloudflare and configuring NGINX. Coolify has simplified this process by handling DNS configurations automatically. This not only saves time but also reduces the potential for configuration errors.

settings.svg

Automatic PR Builds

Coolify’s automatic PR (Pull Request) build feature has been a game-changer for our QA and integration testing processes. When a PR is created, Coolify automatically generates a version of the app with the PR branch and shares a link. This makes it easier for our QA team to test new features and for developers to ensure integration without affecting the main branch.

Empowered Development Teams

With Coolify, we can assign teams and projects, allowing developers to deploy their applications independently. This has empowered our development teams, increasing productivity and reducing bottlenecks.

Managing Environments

Coolify’s environment management capabilities have been particularly beneficial. We can easily create and manage development, staging, and production environments for each project. This has ensured that our deployment processes are consistent and reliable across different stages of development. The ability to manage multiple environments from a single interface has simplified our workflow and reduced the chances of environment-specific issues.

Our experience with Coolify has been transformative, streamlining our deployment processes, reducing manual configurations, and empowering our development teams. By automating many DevOps tasks, Coolify allows us to focus more on innovation and less on managing pipelines. Its user-friendly interface, powerful features, and seamless GitHub integration make it an excellent choice for simplifying deployment workflows and enhancing development processes.

Related Blogs

Refining and Creating Data Visualizations with LIDA

Microsoft’s Language-Integrated Data Analysis (LIDA) is a game-changer, offering an advanced framework to refine and enhance data visualizations with seamless integration, automation, and intelligence. Let’s explore the key features and applications of LIDA, and its transformative impact on the data visualization landscape. LIDA is a powerful library designed to effortlessly generate data visualizations and create data-driven infographics with precision. What makes LIDA stand out is its grammar-agnostic approach, enabling compatibility with various programming languages and visualization libraries, including popular ones like matplotlib, seaborn, altair, and d3. Plus, it seamlessly integrates with multiple large language model providers such as OpenAI, Azure OpenAI, PaLM, Cohere, and Huggingface.

Refining and Creating Data Visualizations with LIDA

Core Web Vitals: How to Improve LCP and CLS for Optimal Site Performance

Optimizing a website for performance is essential to enhance user experience and boost search engine rankings. Two critical metrics from Google’s Core Web Vitals (CWV)—Largest Contentful Paint (LCP) and Cumulative Layout Shift (CLS)—play a significant role in measuring and improving a site’s performance. These metrics outline the key strategies for optimization and highlight the observed impact on both mobile and desktop performance.

Core Web Vitals: How to Improve LCP and CLS for Optimal Site Performance

From Frontend-Heavy to a Balanced Architecture: Enhancing System Efficiency

Building efficient and scalable applications often requires balancing responsibilities between the frontend and backend. When tasks like report generation are managed solely on the frontend, it can lead to performance bottlenecks, scalability issues, and user experience challenges. Transitioning to a balanced architecture can address these limitations while improving overall system efficiency.

From Frontend-Heavy to a Balanced Architecture: Enhancing System Efficiency

From Blinking LEDs to Real-Time AI: The Raspberry Pi’s Role in Innovation

The Raspberry Pi, launched in 2012, has entered the vocabulary of all doers and makers of the world. It was designed as an affordable, accessible microcomputer for students and hobbyists. Over the years, Raspberry Pi has evolved from a modest credit card-sized computer into a versatile platform that powers innovations in fields as diverse as home economics to IoT, AI, robotics and industrial automation. Raspberry Pis are single board computers that can be found in an assortment of variations with models ranging from anywhere between $4 to $70. Here, we’ll trace the journey of the Raspberry Pi’s evolution and explore some of the innovations that it has spurred with examples and code snippets.

From Blinking LEDs to Real-Time AI: The Raspberry Pi’s Role in Innovation

Exploring Different Text-to-Speech (TTS) Models: From Robotic to Natural Voices

Text-to-speech (TTS) technology has evolved significantly in the past few years, enabling one to convert simple text to spoken words with remarkable accuracy and naturalness. From simple robotic voices to sophisticated, human-like speech synthesis, models offer specialized capabilities applicable to different use cases. In this blog, we will explore how different TTS models generate speech from text as well as compare their capabilities, models explored include MARS-5, Parler-TTS, Tortoise-TTS, MetaVoice-1B, Coqui TTS among others. The TTS process generally involves several key steps discussed later in detail: input text and reference audio, text processing, voice synthesis and then the final audio is outputted. Some models enhance this process by supporting few-shot or zero-shot learning, where a new voice can be generated based on minimal reference audio. Let's delve into how some of the leading TTS models perform these tasks.

Exploring Different Text-to-Speech (TTS) Models: From Robotic to Natural Voices
Refining and Creating Data Visualizations with LIDA

Refining and Creating Data Visualizations with LIDA

Microsoft’s Language-Integrated Data Analysis (LIDA) is a game-changer, offering an advanced framework to refine and enhance data visualizations with seamless integration, automation, and intelligence. Let’s explore the key features and applications of LIDA, and its transformative impact on the data visualization landscape. LIDA is a powerful library designed to effortlessly generate data visualizations and create data-driven infographics with precision. What makes LIDA stand out is its grammar-agnostic approach, enabling compatibility with various programming languages and visualization libraries, including popular ones like matplotlib, seaborn, altair, and d3. Plus, it seamlessly integrates with multiple large language model providers such as OpenAI, Azure OpenAI, PaLM, Cohere, and Huggingface.

Core Web Vitals: How to Improve LCP and CLS for Optimal Site Performance

Core Web Vitals: How to Improve LCP and CLS for Optimal Site Performance

Optimizing a website for performance is essential to enhance user experience and boost search engine rankings. Two critical metrics from Google’s Core Web Vitals (CWV)—Largest Contentful Paint (LCP) and Cumulative Layout Shift (CLS)—play a significant role in measuring and improving a site’s performance. These metrics outline the key strategies for optimization and highlight the observed impact on both mobile and desktop performance.

From Frontend-Heavy to a Balanced Architecture: Enhancing System Efficiency

From Frontend-Heavy to a Balanced Architecture: Enhancing System Efficiency

Building efficient and scalable applications often requires balancing responsibilities between the frontend and backend. When tasks like report generation are managed solely on the frontend, it can lead to performance bottlenecks, scalability issues, and user experience challenges. Transitioning to a balanced architecture can address these limitations while improving overall system efficiency.

From Blinking LEDs to Real-Time AI: The Raspberry Pi’s Role in Innovation

From Blinking LEDs to Real-Time AI: The Raspberry Pi’s Role in Innovation

The Raspberry Pi, launched in 2012, has entered the vocabulary of all doers and makers of the world. It was designed as an affordable, accessible microcomputer for students and hobbyists. Over the years, Raspberry Pi has evolved from a modest credit card-sized computer into a versatile platform that powers innovations in fields as diverse as home economics to IoT, AI, robotics and industrial automation. Raspberry Pis are single board computers that can be found in an assortment of variations with models ranging from anywhere between $4 to $70. Here, we’ll trace the journey of the Raspberry Pi’s evolution and explore some of the innovations that it has spurred with examples and code snippets.

Exploring Different Text-to-Speech (TTS) Models: From Robotic to Natural Voices

Exploring Different Text-to-Speech (TTS) Models: From Robotic to Natural Voices

Text-to-speech (TTS) technology has evolved significantly in the past few years, enabling one to convert simple text to spoken words with remarkable accuracy and naturalness. From simple robotic voices to sophisticated, human-like speech synthesis, models offer specialized capabilities applicable to different use cases. In this blog, we will explore how different TTS models generate speech from text as well as compare their capabilities, models explored include MARS-5, Parler-TTS, Tortoise-TTS, MetaVoice-1B, Coqui TTS among others. The TTS process generally involves several key steps discussed later in detail: input text and reference audio, text processing, voice synthesis and then the final audio is outputted. Some models enhance this process by supporting few-shot or zero-shot learning, where a new voice can be generated based on minimal reference audio. Let's delve into how some of the leading TTS models perform these tasks.

Additional

Your Random Walk Towards AI Begins Now