Linux VM에 대한 설치 안내서

Linux VM에 배포

이 안내서는 Ubuntu 18.04 LTS / 20.04 LTS / 20.10에 ChatWoot를 설치하는 데 도움이됩니다. 우리는 당신이 실행할 배포 스크립트를 준비했습니다. 스크립트를 참조하고 비 untu 시스템에있는 경우 OS에 따라 변경 사항을 자유롭게 변경하십시오. 우분투 18.04의 경우 다음 스크립트를 사용하십시오

    https://raw.githubusercontent.com/chatwoot/chatwoot/develop/deployment/setup_18.04.sh 

Ubuntu 20.04 또는 Ubuntu 20.10의 경우 다음 스크립트를 사용하십시오.

    https://raw.githubusercontent.com/chatwoot/chatwoot/develop/deployment/setup_20.04.sh

설치 단계

setup.sh 파일을 만들고 위의 링크에서 내용을 복사하거나 다음 명령을 사용하십시오.

     wget  -O setup.sh
    chmod 755 setup.sh
    ./setup.sh master 

스크립트를 실행하면 초기 chatwoot 설정을 처리합니다. chatwoot 설치는 이제 http : // {your \ _ip \ _address} : 3000에서 액세스 할 수 있습니다.

nginx를 구성하고 암호화합시다

프론트 엔드 프록시 역할을하도록 nginx를 구성하십시오.

    cd /etc/nginx/sites-enabled
    nano yourdomain.com.conf  

Server \ _name에서 yourdomain.com을 교체 한 후 다음 nginx 구성을 사용하십시오.

    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;
    }  

다음 명령을 실행하여 nginx 구성을 확인하고 다시로드하십시오.

     nginx -t
    systemctl reload nginx 

실행하자 SSL 인증서를 암호화하고 구성하십시오.

     mkdir -p /var/www/ssl-proof/chatwoot/.well-known
    certbot --webroot -w /var/www/ssl-proof/chatwoot/ -d yourdomain.com -i nginx 

chatwoot 설치는 지금 https://yourdomain.com에서 액세스 할 수 있어야합니다.

필요한 환경 변수를 구성합니다

chatwoot 설치가 올바르게 작동하려면 Frontend \ _url, Mailer 및 클라우드 스토리지 구성과 같은 필수 환경 변수를 구성해야합니다. 전체 목록은 환경 변수를 참조하십시오. chatwoot로 로그인하고 .env 파일을 편집하십시오.

    # Login as chatwoot user
    
    sudo -i -u chatwoot
    cd chatwoot
    nano .env  

필요한 환경 변수를 업데이트하고 Chatwoot 서버를 다시 시작하고 자체 호스팅 된 채팅 위트를 사용하여 즐기십시오.

     systemctl restart chatwoot.target
 한국인