Jump toUpdate content

How to deploy the Zammad ticketing solution
- compute
- Zammad
- ticket
- support
- chat
- Elasticsearch
Zammad - Overview
Zammad is an open source helpdesk system with features to manage customer communication via several channels including telephone, Facebook, Twitter, chat and emails. The software is completely open-source and released under version 3 of the GNU AFFERO General Public License (GNU AGPLv3).
In this tutorial you will learn how to install Zammad on a Virtual Instance running on Ubuntu 20.04 LTS (Focal Fossa) and take a quick walk through the application. The different steps of this tutorial are:
- You have an account and are logged into the Scaleway console
- You have configured your SSH Key
- You have an Instance running on Ubuntu Focal Fossa (20.04 LTS)
- You have a domain name pointed to your Instance
Installing Elasticsearch
Zammad requires an Elasticsearch database to increase search performance and to support advanced features like reports or searching by email attachment contents. Start by installing the Elasticsearch engine on your Instance.
Connect to your Instance using SSH.
Update the
apt
package manager repository inventory and upgrade the software already installed on the Instance to the latest version available in the repositories:apt update && apt upgrade -y
Install the prerequisites for the installation of Elasticsearch:
apt-get install apt-transport-https locales wget
Add the Elasticsearch repository to the
apt
package manager and install the Elasticsearch GPG key on your instance:echo "deb https://artifacts.elastic.co/packages/7.x/apt stable main" | tee -a /etc/apt/sources.list.d/elastic-7.x.list
wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | apt-key add -Update the
apt
package manager to include the new repository:apt update
Install Elasticsearch using
apt
:apt install elasticsearch
Zammad requires the ingest-attachment plugin for Elasticsearch. Install it by running the following command:
/usr/share/elasticsearch/bin/elasticsearch-plugin install ingest-attachment
Restart
elasticsearch
and enable the service:systemctl restart elasticsearch
systemctl enable elasticsearch
Installing Zammad
Make sure that your system is using a
UTF-8
locale, otherwise the PostgreSQL database engine installation may fail. In this tutorial we use the localeen_US.UTF-8
:locale-gen en_US.UTF-8
echo "LANG=en_US.UTF-8" > /etc/default/localeAdd the Zammad repository to the
apt
package manager and install the Zammad GPG key on your system:sudo wget -O /etc/apt/sources.list.d/zammad.list \
https://dl.packager.io/srv/zammad/zammad/stable/installer/ubuntu/20.04.repo
wget -qO- https://dl.packager.io/srv/zammad/zammad/key | sudo apt-key add -Update the
apt
package manager to activate the new repository and install Zammad:apt update && apt install zammad -y
Configure Zammad with Elasticsearch by running the following two commands:
zammad run rails r "Setting.set('es_url', 'http://localhost:9200')"
zammad run rake searchindex:rebuild
Configuring Nginx
Zammad uses the Nginx web server to serve the application. In the following step you configure the web server application and request a TLS certificate, issued by the Let’s Encrypt certificate authority, to secure the connection to between your users and agents using HTTPS. A domain name pointing to the IP address of your Virtual Cloud Instance is required for this step (A-Record).
Open the Nginx configuration file, generated by Zammad, in a text editor. In this tutorial we use
nano
to edit the file:nano /etc/nginx/sites-enabled/zammad.conf
Note:Please do not rename or move this file. Zammad will regenerate it, if the file is not available.
Look out for the
server {
block and replace the server’s hostnamelocalhost
with your domain name. In this tutorial we usezammad.example.com
:[...]
server {
listen 80;
# replace 'localhost' with your fqdn if you want to use zammad from remote
server_name localhost;
[...]Once edited, save the file by pressing
CTRL
+O
, then leave the editor by pressingCTRL
+X
.Reload the Nginx configuration files to activate the new configuration:
service nginx reload
Install
certbot
, a tool requesting the TLS certificate for the Let’s Encrypt CA and doing all the required Nginx configuration for you:apt install certbot python3-certbot-nginx -y
Run
certbot
:certbot --nginx
Follow the prompts and provide the requested information to certbot. Certbot will automatically request the certificate and reconfigure Nginx for HTTPS connections. For more information refer to our dedicated documentation.
Setting up Zammad
Open a web browser and point it to your Zammad installation (in our tutorial:
https://zammad.example.com
).The interactive setup wizard displays. Click Setup new system to start the configuration of the tool.
Enter the required information for the administrator account and validate the form by clicking Create:
Enter the required information about your organization. You can upload your company logo to customize the installation. Make sure the System URL corresponds with your domain name (
zammad.example.com
in our example):Choose how you want to deliver your emails. You can either use a local mail server, installed on your instance, or use an external mailing service by using SMTP:
Enter the SMTP details of either the local MTA or the information you received from your messaging service.
To configure the email channel, click the Email button and enter the account POP3/IMAP information for your incoming mails.
You have completed the basic installation of Zammad. The agent dashboard displays:
Your users and agents can now communicate efficiently by email and by logging into their helpdesk interface.
Creating additional users
Currently your Zammad application has only the admin user. In the following step we create additional accounts for users and agents.
Zammad proposes three default roles of user accounts:
- Customer: Users who create tickets and ask for help.
- Agent: Your agents who deal with the requests made by your customers.
- Admin: Admin accounts have full control over the Zammad instance and can manage the system.
If required, you can create more detailed roles by adding more and allowing or disallowing features on a more finely granulated level.
From the Zammad dashboard click the cogwheel icon (1) to enter the management section of the system.
In the users section (2) of the management panel, click New user (3) to create a new account.
Enter the account information of the new user and tick the checkbox corresponding to its role on the application. Once all information is provided, click Submit to create the new user account.
Tip:To create a large number of user accounts, you can also use the bulk upload feature to upload a file in the comma separated values (CSV) format. It must be saved as UTF-8.
Creating additional channels
For now, your Zammad instance allows you to communicate with your users by e-mail, but the application provides a wide range of connectors to interact with your customers. You can configure modules for:
- Telegram
- Chat
- SMS (via twilio)
and much more.
Click the cogwheel icon (1) to enter the management section of Zammad.
Scroll down to the Channels section (2) and choose the communication channel you want to configure (3).
The configuration options vary depending on the channel you want to configure.
Conclusion
You have configured a Virtual Cloud Instance with the Zammad ticketing solution, linked it to an Elasticserarch database and configured a secure connection to the instance using HTTPS. You also did a short walkthrough of some of the features of Zammad. For more information on all features of the solution, refer to the official documentation.