Search
Close this search box.

How to Install Zammad Ticketing System on Debian 12

Table of Contents

If you’re looking to streamline your customer support with an efficient ticketing system, Zammad is a powerful, open-source solution worth considering. In this guide, we’ll walk you through the steps to install Zammad on Debian 12, helping you get your support system up and running quickly. Whether you’re new to Zammad or simply upgrading, this guide will ensure you have everything set up smoothly. Let’s dive in!

 

To start, make sure you’ve created a VPSie account if you haven’t already. Next, proceed by deploying an Debian 12 server configured to meet your specific needs.

Once the server is deployed, SSH into the command line interface. Before installing any packages, it’s essential to update your Debian operating system to ensure all existing packages are up to date. Open a terminal and run the following command:

sudo apt update && sudo apt upgrade -y

Install Dependencies

Start by running the following command to install the essential packages required for managing the repository. Elasticsearch requires Java to run. However, the latest versions come bundled with their own Java runtime. To ensure all dependencies are met, install the following packages:

sudo apt install curl apt-transport-https ca-certificates gnupg -y

 

Import the GPG key to verify the authenticity of the Elasticsearch packages.

wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo gpg --dearmor -o /usr/share/keyrings/elasticsearch-keyring.gpg

 

Create a new APT source list file for Elasticsearch.

echo "deb [signed-by=/usr/share/keyrings/elasticsearch-keyring.gpg] https://artifacts.elastic.co/packages/8.x/apt stable main" | sudo tee /etc/apt/sources.list.d/elasticsearch.list

 

Update the package list.

sudo apt update

 

After updating the repository, install the dependencies for Zammad by running the following command.

sudo apt install libimlib2 elasticsearch postgresql postgresql-common redis-server nginx nodejs locales -y

 

Run the following command to start and enable Elasticsearch.

sudo systemctl start elasticsearch
sudo systemctl enable elasticsearch
sudo systemctl status elasticsearch

 

You can verify the installation of each package by checking their versions or statuses:

 

PostgreSQL:

psql --version
sudo systemctl is-enabled postgresql

 

Redis:

redis-server --version
sudo systemctl is-enabled redis

 

Nginx:

nginx -v
sudo systemctl is-enabled nginx

 

Node.js:

node -v

 

Locales:

locale -a

 

Each command should return version information or a status indicating the service is active and check whether the services is enabled to start automatically at boot time

Set-up Dependencies

Open the PostgreSQL configuration file postgresql.conf for editing. This file is usually located in the PostgreSQL data directory.

sudo nano /etc/postgresql/15/main/postgresql.conf


Note: The version number (15) and directory path may vary depending on your PostgreSQL version and installation location.


Then, locate the max_connections parameter in the configuration file. If the parameter is commented out (preceded by #), uncomment it by removing the # symbol. Then, set the value to 2000:

max_connections = 2000

After making the changes, save the file and exit the editor:


Apply the changes by restarting the PostgreSQL service:

sudo systemctl restart postgresql

 

Next, configure Elasticsearch by installing the ingest-attachment plugin needed for Zammad. Use the following elasticsearch-plugin command:

 

Use the elasticsearch-plugin command to install the ingest-attachment plugin. This command needs to be run as the root user or with sudo.

sudo /usr/share/elasticsearch/bin/elasticsearch-plugin install ingest-attachment

 

After the plugin is installed, restart the Elasticsearch service to load the new plugin.

sudo systemctl restart elasticsearch

 

You can verify that the plugin is installed correctly by listing all installed plugins.

sudo /usr/share/elasticsearch/bin/elasticsearch-plugin list

 

Lastly, verify that the Elasitcsearch is running using curl.

curl -X GET 'http://localhost:9200'

 

Now, Set up default locale to en_US.UTF-8. First, you need to generate the en_US.UTF-8 locale if it isn’t already available.

sudo locale-gen en_US.UTF-8

 

Then set up the default locale to en_US.UTF-8 by adding a new configuration to the /etc/default/locale file.

echo "LANG=en_US.UTF-8" > /etc/default/locale

 

Apply the changes to your current session:

source /etc/default/locale

 

Check the current locale settings to confirm that en_US.UTF-8 is set as the default.

locale

Install Zammad

To install Zammad using packages from the official Zammad repository, follow these steps:

 

 

Download and add the Zammad GPG key to your system:

curl -fsSL https://dl.packager.io/srv/zammad/zammad/key | \
gpg --dearmor | tee /etc/apt/trusted.gpg.d/pkgr-zammad.gpg> /dev/null

 

 

Create a new file for the Zammad repository:

echo "deb [signed-by=/etc/apt/trusted.gpg.d/pkgr-zammad.gpg] https://dl.packager.io/srv/deb/zammad/zammad/stable/debian 12 main"| \
tee /etc/apt/sources.list.d/zammad.list > /dev/null

 

 

Update your package list to include the new Zammad repository:

sudo apt update

 

 

Now the Zammad repository is added and your system is ready to install Zammad from it. You can install Zammad with the following command:

sudo apt install zammad

 

 

Once the installation is complete, Run the following Zammad commands to set up integration with Elasticsearch and rebuild the search index:

sudo zammad run rake searchindex:rebuild

 

 

Afterward, run the following command to restart all Zammad services. Zammad includes several services such as zammad, zammad-web, zammad-worker, and zammad-websocket.

sudo systemctl restart zammad zammad-web zammad-worker zammad-websocket
 

To check the status of Zammad and its related services, use the following commands:

sudo systemctl status zammad
sudo systemctl status zammad-web
sudo systemctl status zammad-worker
sudo systemctl status zammad-websocket

 

 

These commands will show you whether each service is active and running, or if there are any issues that need to be addressed.

Configure Nginx Web Server

By default, Zammad generates an Nginx server block configuration located at /etc/nginx/sites-available/zammad.conf. To set up Zammad for production, you need to modify the domain configuration and secure it with HTTPS.

 

 

First, open the configuration file with the nano editor:

sudo nano /etc/nginx/sites-available/zammad.conf

 

 

Update the server_name option with your domain or ip:

server_name {your_ip/your_domain};

 

Save the file and exit the editor.

 

 

Next, verify the Nginx configuration syntax and restart the Nginx service for the changes to take effect:

sudo nginx -t
sudo systemctl restart nginx

 

Ensure the Nginx syntax test is successful before proceeding.

Access Zammad Web UI

Open your web browser and navigate to the Zammad installation URL http://{your-domain/ip}

 

Once you access the web interface, click on Set up a new system to start the installation process.

zammad

Create your Administrator Account.

Enter your organization name and click Next.

You can configure email notification later, click Skip for now.

Click Skip for connecting channel configuration.

You should be able to access the Zammad administration dashboard now.


Setting up Zammad on Debian 12 is a straightforward process that can significantly enhance your customer support capabilities. Whether you’re running a small business or a larger enterprise, Zammad’s features will help streamline your support operations and provide a better experience for both your team and your customers. Enjoy exploring Zammad and its powerful tools your support system is now ready to make a positive impact!

Make a Comment
{{ reviewsTotal }}{{ options.labels.singularReviewCountLabel }}
{{ reviewsTotal }}{{ options.labels.pluralReviewCountLabel }}
{{ options.labels.newReviewButton }}
{{ userData.canReview.message }}
Share on
Facebook
Twitter
LinkedIn
Print
VPSie Cloud service

Fast and Secure Cloud VPS Service

Try FREE
For a month

The First 1 orders gets free discount today! Try Sign up on VPSie to get a chance to get the discount.