Zammad - Ubuntu Installation

Hi there!

So, I’ve recently started the process of installing Zammad on my Ubuntu VPS instance, but I’ve ran into a problem I think which is a critical.

Running commands like,

zammad run rails r “Setting.set(‘es_url’, ‘http://localhost:9200’)”

Would all error (I suppose), and log this output,


You might be wondering why it’s using the user ‘root’ instead of ‘zamad’, but that’s because I went into the main directory which it installed when using the apt install zammad command and changed the database.yml file to use user root, which obviously still did not work.

Any help on this topic would be greatly appreciated, and I do apologize if I didn’t create this topic in the correct manner, just working on a bit of a tight schedule, and fixing this is my main priority.

Also, I’m using the Nginx setup for the domain, but my domain’s DNS is pointed to Cloudflare, meaning that there is a bit of an interference with HTTPs etc, I’ll add the config I have into a blockquote below this, and if there is anything I should change, please let me know!

upstream zammad-railsserver {
server 127.0.0.1:3000;
}
upstream zammad-websocket {
server 127.0.0.1:6042;
}
server {
listen 80;
listen [::]:80;
server_name admin.espdevrbx.com;
security - prevent information disclosure about server version
server_tokens off;
access_log /var/log/nginx/zammad.access.log;
error_log /var/log/nginx/zammad.error.log;
location /.well-known/ {
root /var/www/html;
}
resolver 8.8.8.8 8.8.4.4;
add_header Strict-Transport-Security “max-age=31536000” always;
location = /robots.txt {
access_log off; log_not_found off;
}
location = /favicon.ico {
access_log off; log_not_found off;
}
root /opt/zammad/public;
access_log /var/log/nginx/zammad.access.log;
error_log /var/log/nginx/zammad.error.log;
client_max_body_size 50M;
location ~ ^/(assets/|robots.txt|humans.txt|favicon.ico|apple-touch-icon.png) {
expires max;
}
location /ws {
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection “Upgrade”;
proxy_set_header CLIENT_IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_read_timeout 86400;
proxy_pass http://zammad-websocket;
}
location / {
proxy_set_header Host $http_host;
proxy_set_header CLIENT_IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
change this line in an SSO setup
proxy_set_header X-Forwarded-User “”;
proxy_read_timeout 180;
proxy_pass http://zammad-railsserver;
gzip on;
gzip_types text/plain text/xml text/css image/svg+xml application/javascript application/x-javascript application/json application/xml;
gzip_proxied any;
}
}

(The formatting was a bit weird, because of the “#”, so I just removed them, but the original commented bits are still in, so don’t worry about those being uncommented in the actual file on the server.)

did you configure the user root with password on you mysql server, with access from localhost? You should have the same password you set in mysql for the user root in your database.yml

Well, I just used root and the server login password, I assume that’s not the correct way? (If I’m reading your message correctly.)

you’ll need to login to your mysql server and set the password, see; MySQL :: MySQL 8.0 Reference Manual :: 13.7.1.10 SET PASSWORD Statement for roo@localhost. The root user of mysql is not the same root users as your server, despite the name being te same.