Skip to content

Linux VPS & VPS Windows Setup Guide | NetCloud24 Cachet on Debian 12 VPS Server

Cloud Infrastructure Expert
Linux VPS & VPS Windows Setup Guide | NetCloud24 Cachet on Debian 12 VPS Server

 

How to Install Cachet Status Page System on Debian 12

Cachet is an open-source status page system that helps you communicate incidents and uptime to your users. Follow these steps to install Cachet on your VPS server.

Prerequisites

  • A VPS server running Debian 12
  • Root or sudo access
  • Basic knowledge of the command line

Step 1: Update Your System

First, ensure your system is up to date:

sudo apt update && sudo apt upgrade -y

Step 2: Install Required Packages

Cachet requires PHP and several PHP extensions, along with a web server and a database server. Install the necessary packages:

sudo apt install nginx php8.0-fpm php8.0-cli php8.0-mysql php8.0-curl php8.0-xml php8.0-mbstring git unzip
sudo apt install mariadb-server

Step 3: Configure the Database

  1. Start the MariaDB service:
    sudo systemctl start mariadb
  2. Secure your MariaDB installation:
    sudo mysql_secure_installation
  3. Log in to MariaDB:
    sudo mysql -u root -p
  4. Create a database and user for Cachet:
    CREATE DATABASE cachet;
    CREATE USER 'cachetuser'@'localhost' IDENTIFIED BY 'your_password';
    GRANT ALL PRIVILEGES ON cachet.* TO 'cachetuser'@'localhost';
    FLUSH PRIVILEGES;
    EXIT;

Step 4: Install Cachet

  1. Change to the web root directory:
    cd /var/www/
  2. Clone the Cachet repository:
    git clone https://github.com/CachetHQ/Cachet.git cachet
  3. Change to the Cachet directory:
    cd cachet
  4. Install dependencies using Composer. If you don’t have Composer, you can install it with:
    curl -sS https://getcomposer.org/installer | php
    sudo mv composer.phar /usr/local/bin/composer

    Then, run:

    composer install --no-dev

Step 5: Configure Cachet

  1. Copy the example environment file:
    cp .env.example .env
  2. Open the .env file and set the database details:
    DB_DATABASE=cachet
    DB_USERNAME=cachetuser
    DB_PASSWORD=your_password
  3. Run the migrations:
    php artisan migrate --seed

Step 6: Configure Nginx

Create a new Nginx configuration file:

sudo nano /etc/nginx/sites-available/cachet

Add the following configuration:

server {
    listen 80;
    server_name your_domain.com; # Change to your domain

    root /var/www/cachet/public;
    index index.php index.html index.htm;

    location / {
        try_files $uri $uri/ /index.php?$query_string;
    }

    location ~ \.php$ {
        include snippets/fastcgi-php.conf;
        fastcgi_pass unix:/var/run/php/php8.0-fpm.sock;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include fastcgi_params;
    }
}

Enable the new site and test Nginx configuration:

sudo ln -s /etc/nginx/sites-available/cachet /etc/nginx/sites-enabled/
sudo nginx -t

Restart Nginx:

sudo systemctl restart nginx

Step 7: Complete the Installation

Visit http://your_domain.com in your web browser to complete the installation. Follow the on-screen instructions to set up your Cachet instance.

Conclusion

You have successfully installed the Cachet Status Page System on your Debian 12 VPS server. Now you can communicate status updates effectively with your users!

Windows VPS Deutschland

Windows VPS España

Windows VPS Nederland

Windows VPS Italia

Windows VPS Portugal

VPS Windows Italia

Windows VPS

Windows VPS

Windows VPS Sverige

Windows VPS Norge

Windows VPS

Windows VPS Türkiye

Windows RDS (Remote Desktop Services)

Windows VPS

Explore more

More on this topic

Netcloud24
Netcloud24
Cloud Infrastructure Expert · NetCloud24

Comments are closed.