Installatiegids voor Linux VM
Implementeren naar Linux VM
Deze gids helpt u bij het installeren van chatwoot op Ubuntu 18.04 LTS / 20.04 LTS / 20.10. We hebben een implementatiescript opgesteld die u kunt uitvoeren. Raadpleeg het script en voel je vrij om dienovereenkomstig wijzigingen aan te brengen in OS als u zich op een niet-ultu-systeem bevindt. Gebruik voor Ubuntu 18.04 het volgende script
https://raw.githubusercontent.com/chatwoot/chatwoot/develop/deployment/setup_18.04.sh
Gebruik het volgende script voor Ubuntu 20.04 of Ubuntu 20.10.
https://raw.githubusercontent.com/chatwoot/chatwoot/develop/deployment/setup_20.04.sh
stappen om te installeren
Maak een setup.sh -bestand en kopieer de inhoud uit de bovenstaande link of gebruik de volgende opdrachten
wget -O setup.sh
chmod 755 setup.sh
./setup.sh master
Voer het script uit en het zorgt voor de initiële chatwoot -instelling. Chatwoot -installatie is nu toegankelijk op http: // {your \ _IP \ _Address}: 3000
configureren nginx en laten we coderen
Configureer nginx om als frontend -proxy te dienen.
cd /etc/nginx/sites-enabled
nano yourdomain.com.conf
Gebruik de volgende nginx -configuratie na het vervangen van de jedomein.com in server \ _NAME.
server {
server_name ;
# Point upstream to Chatwoot App Server
set $upstream 127.0.0.1:3000;
# Nginx strips out underscore in headers by default
# Chatwoot relies on underscore in headers for API
# Make sure that the config is turned on.
underscores_in_headers on;
location /.well-known {
alias /var/www/ssl-proof/chatwoot/.well-known;
}
location / {
proxy_pass_header Authorization;
proxy_pass http://$upstream;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_set_header Host $host;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Ssl on; # Optional
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_http_version 1.1;
proxy_set_header Connection “”;
proxy_buffering off;
client_max_body_size 0;
proxy_read_timeout 36000s;
proxy_redirect off;
}
listen 80;
}
Controleer en herlaad uw Nginx -configuratie door de volgende opdracht uit te voeren.
nginx -t
systemctl reload nginx
Voer laten we het SSL -certificaat uit en configureren.
mkdir -p /var/www/ssl-proof/chatwoot/.well-known
certbot --webroot -w /var/www/ssl-proof/chatwoot/ -d yourdomain.com -i nginx
Uw chatwoot -installatie moet nu toegankelijk zijn vanaf de https://ourdomain.com.
de vereiste omgevingsvariabelen configureren
Voor uw chatwoot -installatie om goed te functioneren, moet u enkele van de essentiële omgevingsvariabelen zoals frontend \ _url, mailer en een cloudopslagconfiguratie configureren. Verwijs omgevingsvariabelen voor de volledige lijst. Log in als chatwoot en bewerk het .env -bestand.
# Login as chatwoot user
sudo -i -u chatwoot
cd chatwoot
nano .env
Werk de vereiste omgevingsvariabelen bij en start de chatwoot -server opnieuw en geniet ervan om uw zelf gehoste chatwoot te gebruiken
systemctl restart chatwoot.target