maak chat.bitlair.nl

This commit is contained in:
Kyan Wanschers 2025-04-27 19:50:53 +02:00
parent 5ab22d0e96
commit c267c51e1e
9 changed files with 295 additions and 0 deletions

View file

@ -0,0 +1,58 @@
"use strict";
module.exports = {
public: false,
port: 9000,
bind: "0.0.0.0",
reverseProxy: true,
lockNetwork: true,
maxHistory: 10000,
leaveMessage: "Doei!",
defaults: {
name: "Smurfnet",
password: "",
rejectUnauthorized: true,
nick: "",
username: "",
realname: "",
join: "#bitlair",
},
messageStorage: ["sqlite", "text"],
fileUpload: {
enable: true,
},
networks: {
Smurfnet: {
host: "irc.smurfnet.ch",
port: 6697,
tls: true,
rejectUnauthorized: false,
},
"Libera.Chat": {
host: "irc.libera.chat",
port: 6697,
tls: true,
rejectUnauthorized: true,
},
OFTC: {
host: "irc.oftc.net",
port: 6697,
tls: true,
rejectUnauthorized: true,
},
},
identd: {
enable: false,
},
ldap: {
enable: true,
url: "{{ thelounge_ldap_url }}",
primaryKey: "uid",
searchDN: {
rootDN: "{{ thelounge_ldap_rootDN }}",
rootPassword: "{{ thelounge_ldap_rootPassword }}",
filter: "{{ thelounge_ldap_filter }}",
base: "{{ thelounge_ldap_base }}",
},
},
};

View file

@ -0,0 +1,5 @@
# {{ ansible_managed }}
Package: nodejs
Pin: origin deb.nodesource.com
Pin-Priority: 1000

View file

@ -0,0 +1,3 @@
# {{ ansible_managed }}
deb [arch=amd64 signed-by=/usr/share/keyrings/nodesource.gpg] https://deb.nodesource.com/node_{{ nodejs_version }} nodistro main

View file

@ -0,0 +1,28 @@
diff --git a/package.json b/package.json
index 2991a6ec..dac43f16 100644
--- a/package.json
+++ b/package.json
@@ -84,9 +84,7 @@
"ua-parser-js": "1.0.33",
"uuid": "8.3.2",
"web-push": "3.4.5",
- "yarn": "1.22.17"
- },
- "optionalDependencies": {
+ "yarn": "1.22.17",
"sqlite3": "5.1.7"
},
"devDependencies": {
diff --git a/server/plugins/auth/ldap.ts b/server/plugins/auth/ldap.ts
index e6093b0f..d30b9a1c 100644
--- a/server/plugins/auth/ldap.ts
+++ b/server/plugins/auth/ldap.ts
@@ -134,7 +134,7 @@ const ldapAuth: AuthHandler = (manager, client, user, password, callback) => {
// auth plugin API
function callbackWrapper(valid: boolean) {
if (valid && !client) {
- manager.addUser(user, null, false);
+ manager.addUser(user, null, true);
}
callback(valid);

View file

@ -0,0 +1,17 @@
[Unit]
Description=The Lounge (IRC client)
After=network-online.target
Wants=network-online.target
[Service]
User=thelounge
Group=thelounge
Type=simple
Environment=THELOUNGE_HOME=/var/local/thelounge
ExecStart=/usr/local/bin/thelounge start
ProtectSystem=yes
ProtectHome=yes
PrivateTmp=yes
[Install]
WantedBy=multi-user.target