Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Running weechat on a remote server behind nginx

Install package

yum install epel-release
yum install weechat

Configure weechat

$ weechat
> /relay add weechat 9001

Configure nginx to proxy the requests to /weechat

map $http_upgrade $connection_upgrade {
    default upgrade;
    '' close;

upstream weechat {

server {
    listen       443 ssl;
    server_name  _;

    ssl_certificate /etc/letsencrypt/live/;
    ssl_certificate_key /etc/letsencrypt/live/;

    location /weechat {
        proxy_pass http://weechat;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
        proxy_read_timeout 8h;

Glowing Bear


Specify your server name, port 443 and relay password.

Now you can use it as if you were in Weechat itself (/server add, /connect, etc.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment