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

The Role of Brand Mascots in Driving Website Engagement and Growth

In an era where websites serve as the front door to most businesses, driving and maintaining user engagement is more critical than ever. Yet, many websites face challenges such as high bounce rates, short session durations, and low user retention. Visitors often leave after just a few clicks, failing to engage deeply with the content or take desired actions, such as signing up, making a purchase, or sharing the site with others. The root of the problem often lies in a lack of emotional connection and interactivity. Generic designs and impersonal experiences make it difficult for businesses to stand out and hold visitors' attention.

The Role of Brand Mascots in Driving Website Engagement and Growth

AI in Gaming: Elevating Player Experiences with Intelligent Agents

AI and games have been fundamentally intertwined from their inception, pushing one another to new frontiers. Games, with their precise rules and narrow subdomains, provide the perfect arena for game AI to excel. This blog offers a glimpse into one of our attempts at creating a multi-agent game and explores the complexities involved in designing a multi-agent system in the world of AI in gaming.

AI in Gaming: Elevating Player Experiences with Intelligent Agents

Refining and Creating Data Visualizations with LIDA and AI Fortune Cookie

Data visualization and storytelling are critical for making sense of today’s data-rich world. Whether you’re an analyst, a researcher, or a business leader, translating raw data into actionable insights often hinges on effective tools. Two innovative platforms that elevate this process are Microsoft’s LIDA and our RAG-enhanced data visualization platform using gen AI, AI Fortune Cookie. While LIDA specializes in refining and enhancing infographics, Fortune Cookie transforms disparate datasets into cohesive dashboards with the power of natural language prompts. Together, they form a powerful combination for visual storytelling and data-driven decision-making.

Refining and Creating Data Visualizations with LIDA and AI Fortune Cookie

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
The Role of Brand Mascots in Driving Website Engagement and Growth

The Role of Brand Mascots in Driving Website Engagement and Growth

In an era where websites serve as the front door to most businesses, driving and maintaining user engagement is more critical than ever. Yet, many websites face challenges such as high bounce rates, short session durations, and low user retention. Visitors often leave after just a few clicks, failing to engage deeply with the content or take desired actions, such as signing up, making a purchase, or sharing the site with others. The root of the problem often lies in a lack of emotional connection and interactivity. Generic designs and impersonal experiences make it difficult for businesses to stand out and hold visitors' attention.

AI in Gaming: Elevating Player Experiences with Intelligent Agents

AI in Gaming: Elevating Player Experiences with Intelligent Agents

AI and games have been fundamentally intertwined from their inception, pushing one another to new frontiers. Games, with their precise rules and narrow subdomains, provide the perfect arena for game AI to excel. This blog offers a glimpse into one of our attempts at creating a multi-agent game and explores the complexities involved in designing a multi-agent system in the world of AI in gaming.

Refining and Creating Data Visualizations with LIDA and AI Fortune Cookie

Refining and Creating Data Visualizations with LIDA and AI Fortune Cookie

Data visualization and storytelling are critical for making sense of today’s data-rich world. Whether you’re an analyst, a researcher, or a business leader, translating raw data into actionable insights often hinges on effective tools. Two innovative platforms that elevate this process are Microsoft’s LIDA and our RAG-enhanced data visualization platform using gen AI, AI Fortune Cookie. While LIDA specializes in refining and enhancing infographics, Fortune Cookie transforms disparate datasets into cohesive dashboards with the power of natural language prompts. Together, they form a powerful combination for visual storytelling and data-driven decision-making.

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.

Additional

Your Random Walk Towards AI Begins Now