If you’re looking to set up a lightweight, open-source help desk system on your Ubuntu server, installing FreeScout with Nginx is a solid choice. FreeScout offers a user-friendly interface and essential features for customer support, and pairing it with Nginx ensures fast, efficient web serving. This guide walks you through each step to get FreeScout running smoothly on your Ubuntu Linux machine, including preparing your environment, installing necessary components, configuring Nginx, and securing your setup.
What You’ll Need
- Ubuntu Linux server (preferably Ubuntu 20.04 LTS or newer)
- Root or sudo user privileges
- Domain name pointed to your server’s IP address (optional but recommended)
- Basic knowledge of Linux command line
- Internet connection for downloading packages
Step-by-Step
- Update your system packages
- Install necessary dependencies
- Install and configure a web server (Nginx)
- Install and configure a database server (MySQL/MariaDB)
- Download the latest FreeScout release
- Configure PHP settings (if needed)
- Configure Nginx for FreeScout
- Complete the FreeScout installation via web interface
- Secure your installation (optional but recommended)
sudo apt update && sudo apt upgrade -y
sudo apt install unzip git php php-cli php-mbstring php-zip php-common php-gd php-curl php-xml php-mysql php-bcmath php-ldap php-imap php-xmlrpc php-soap php-intl php-bcmath php-mbstring php-zip php-xml php-gd php-curl php-mysql -y
sudo apt install nginx -y
# Enable Nginx to start on boot
sudo systemctl enable nginx
# Start Nginx
sudo systemctl start nginx
sudo apt install mysql-server -y
# Run security script
sudo mysql_secure_installation
# Log into MySQL to create a database and user for FreeScout
sudo mysql -u root -p
CREATE DATABASE freescout;
CREATE USER 'freescoutuser'@'localhost' IDENTIFIED BY 'your_password_here';
GRANT ALL PRIVILEGES ON freescout.* TO 'freescoutuser'@'localhost';
FLUSH PRIVILEGES;
EXIT;
cd /var/www
sudo git clone https://github.com/freescout-helpdesk/freescout.git
sudo chown -R www-data:www-data freescout
sudo nano /etc/php/7.4/fpm/php.ini
# Ensure these settings are enabled and set appropriately
memory_limit = 256M
upload_max_filesize = 50M
post_max_size = 50M
max_execution_time = 300
# Restart PHP FPM
sudo systemctl restart php7.4-fpm
sudo nano /etc/nginx/sites-available/freescout
# Add the following configuration:
server {
listen 80;
server_name yourdomain.com;
root /var/www/freescout/public;
index index.php index.html index.htm;
location / {
try_files $uri /index.php$is_args$args;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
location ~ /\.ht {
deny all;
}
}
# Enable the site
sudo ln -s /etc/nginx/sites-available/freescout /etc/nginx/sites-enabled/
# Test configuration and reload Nginx
sudo nginx -t
sudo systemctl reload nginx
Open your browser and navigate to http://yourdomain.com
Follow the on-screen instructions to complete the setup:
- Enter database details
- Set admin account credentials
- Configure email settings (SMTP)
# Install Certbot for SSL certificates
sudo apt install certbot python3-certbot-nginx -y
# Obtain SSL certificate
sudo certbot --nginx -d yourdomain.com
# Follow prompts to enable HTTPS
Common Mistakes
- Not updating the system packages before starting the installation, leading to dependency issues.
- Forgetting to set correct permissions on the FreeScout directory, which can cause web server access issues.
- Using incorrect PHP version in configuration files; ensure the PHP version matches what is installed.
- Misconfiguring the Nginx server block, resulting in 404 errors or improper routing.
- Not securing your site with SSL, leaving data vulnerable.
Tips
- Always back up your database and configuration files before major changes.
- Use a domain name instead of IP addresses for easier access and SSL setup.
- Regularly update FreeScout and server packages to keep security patches current.
- Configure email settings early to test notification delivery.
- Consider setting up a firewall (like UFW) to restrict access to only necessary ports.
Troubleshooting
Website Not Loading or Nginx Errors
First, check if Nginx is running properly with sudo systemctl status nginx. Review your server block configuration for typos or incorrect paths. Use sudo nginx -t to test configuration syntax. Restart Nginx after making changes with sudo systemctl reload nginx. If errors persist, examine the error logs at /var/log/nginx/error.log.
Database Connection Issues
If FreeScout cannot connect to the database, verify your database credentials in the configuration file. Ensure the database server is running (sudo systemctl status mysql) and that user privileges are correctly assigned. Check for errors in the database logs.
PHP Errors or White Screen
Verify PHP-FPM is running with sudo systemctl status php7.4-fpm. Check PHP error logs at /var/log/php7.4-fpm.log. Make sure your PHP configuration meets FreeScout requirements. Increasing memory limits or execution time may help resolve issues.
SSL/TLS Certificate Problems
If HTTPS isn’t working after Certbot, ensure your domain DNS records are correct and propagated. Review Certbot logs and Nginx configuration. Restart Nginx after SSL setup. If problems persist, try re-running Certbot or manually configuring SSL certificates.
Frequently Asked Questions
1. Can I install FreeScout without a domain name?
Yes, you can access FreeScout via your server’s IP address, but using a domain name is recommended for SSL and ease of access.
2. How do I update FreeScout to the latest version?
Navigate to the FreeScout directory, pull the latest changes with git pull, and follow the upgrade instructions in the documentation.
3. Is FreeScout secure for handling customer data?
When properly configured with HTTPS, strong passwords, and regular updates, FreeScout is secure. Always keep your server and software current.
4. How do I add email accounts for support tickets?
Configure email accounts in the FreeScout admin panel by providing SMTP settings for outgoing mail and IMAP/POP3 for incoming support emails.
5. Can I run FreeScout alongside other web applications on the same server?
Yes, but ensure proper Nginx virtual host configurations and port management to avoid conflicts.
6. What are the recommended server specifications?
A basic setup can run on a server with 1-2 GB RAM and a modest CPU, but for higher traffic, consider scaling resources accordingly.
Following this guide will help you successfully deploy FreeScout with Nginx on Ubuntu Linux, providing a reliable support platform tailored to your needs. Remember to maintain your server security and keep your software up to date for optimal performance and safety.
Related
- How to Hide Your Facebook Story from Someone Easily
- How To Hide or Show Files and Icons on Desktop in Windows 10/11
- How to Hide Specific Desktop Icons in Windows 11 Easily