[WIP] Ergo IRCd + Gamja for chat
This commit is contained in:
parent
0488fb0eae
commit
6bf2f0ee99
4 changed files with 59 additions and 17 deletions
20
ergo/config.yml
Normal file
20
ergo/config.yml
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
network:
|
||||||
|
name: live.umm.gay
|
||||||
|
|
||||||
|
server:
|
||||||
|
name: chat.live.umm.gay
|
||||||
|
|
||||||
|
listeners:
|
||||||
|
"127.0.0.1:3002":
|
||||||
|
websocket: true
|
||||||
|
|
||||||
|
websockets:
|
||||||
|
allowed-origins:
|
||||||
|
- "https://chat.live.umm.gay"
|
||||||
|
- "https://live.umm.gay"
|
||||||
|
|
||||||
|
casemapping: "permissive"
|
||||||
|
enforce-utf8: true
|
||||||
|
|
||||||
|
accounts:
|
||||||
|
authentication-enabled: false
|
6
ergo/gamja-config.json
Normal file
6
ergo/gamja-config.json
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
{
|
||||||
|
"server": {
|
||||||
|
"url": "wss://chat.live.umm.gay/webirc",
|
||||||
|
"auth": "disabled"
|
||||||
|
}
|
||||||
|
}
|
29
nginx/chat-live-umm-gay.conf
Normal file
29
nginx/chat-live-umm-gay.conf
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
map $http_upgrade $connection_upgrade {
|
||||||
|
default upgrade;
|
||||||
|
'' close;
|
||||||
|
}
|
||||||
|
|
||||||
|
server {
|
||||||
|
listen 443 ssl http2;
|
||||||
|
listen [::]:443 ssl http2;
|
||||||
|
|
||||||
|
server_name chat.live.umm.gay;
|
||||||
|
|
||||||
|
ssl_certificate /etc/letsencrypt/live/chat.live.umm.gay/fullchain.pem;
|
||||||
|
ssl_certificate_key /etc/letsencrypt/live/chat.live.umm.gay/privkey.pem;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
root /srv/www/chat.live.umm.gay;
|
||||||
|
}
|
||||||
|
|
||||||
|
location /webirc {
|
||||||
|
proxy_pass http://127.0.0.1:3002/;
|
||||||
|
|
||||||
|
proxy_http_version 1.1;
|
||||||
|
proxy_read_timeout 600s;
|
||||||
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
|
proxy_set_header Connection "Upgrade";
|
||||||
|
proxy_set_header X-Forwarded-For $remote_addr;
|
||||||
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
|
}
|
||||||
|
}
|
|
@ -1,8 +1,3 @@
|
||||||
map $http_upgrade $connection_upgrade {
|
|
||||||
default upgrade;
|
|
||||||
'' close;
|
|
||||||
}
|
|
||||||
|
|
||||||
server {
|
server {
|
||||||
listen 443 ssl http2;
|
listen 443 ssl http2;
|
||||||
listen [::]:443 ssl http2;
|
listen [::]:443 ssl http2;
|
||||||
|
@ -12,19 +7,11 @@ server {
|
||||||
ssl_certificate /etc/letsencrypt/live/live.umm.gay/fullchain.pem;
|
ssl_certificate /etc/letsencrypt/live/live.umm.gay/fullchain.pem;
|
||||||
ssl_certificate_key /etc/letsencrypt/live/live.umm.gay/privkey.pem;
|
ssl_certificate_key /etc/letsencrypt/live/live.umm.gay/privkey.pem;
|
||||||
|
|
||||||
location / {
|
|
||||||
proxy_pass http://127.0.0.1:3000/;
|
|
||||||
}
|
|
||||||
|
|
||||||
location ^~ /api/wish-server/ {
|
location ^~ /api/wish-server/ {
|
||||||
proxy_pass http://127.0.0.1:3001/;
|
proxy_pass http://127.0.0.1:3001/;
|
||||||
|
}
|
||||||
|
|
||||||
proxy_http_version 1.1;
|
location ^~ / {
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_pass http://127.0.0.1:3000/;
|
||||||
proxy_set_header Connection $connection_upgrade;
|
|
||||||
proxy_set_header Host $host;
|
|
||||||
proxy_connect_timeout 1d;
|
|
||||||
proxy_send_timeout 1d;
|
|
||||||
proxy_read_timeout 1d;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue