mirror of
https://github.com/Misterio77/Foundry.git
synced 2026-09-26 00:51:02 -04:00
minecraft: make librelogin respect forcedhosts
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
{ pkgs, config, ... }: {
|
||||
{ pkgs, config, lib, ... }: let
|
||||
inherit (lib) mapAttrs' replaceStrings nameValuePair;
|
||||
in {
|
||||
services.minecraft-servers.servers.proxy = {
|
||||
symlinks."plugins/LibreLogin.jar" = pkgs.fetchurl rec {
|
||||
pname = "LibreLogin";
|
||||
@@ -33,10 +35,18 @@
|
||||
milliseconds-to-refresh-notification = 10000;
|
||||
minimum-password-length = -1;
|
||||
new-uuid-creator = "MOJANG";
|
||||
# Use the same config as velocity's "try"
|
||||
pass-through.root = config.services.minecraft-servers.servers.proxy.files."velocity.toml".value.servers.try;
|
||||
# Use the same config as velocity's "try" and "forced-hosts
|
||||
pass-through = let
|
||||
velocityCfg = config.services.minecraft-servers.servers.proxy.files."velocity.toml".value;
|
||||
in {
|
||||
root = velocityCfg.servers.try;
|
||||
} // (
|
||||
mapAttrs'
|
||||
(n: nameValuePair (replaceStrings [ "." ] [ "§" ] n))
|
||||
velocityCfg.forced-hosts
|
||||
);
|
||||
ping-servers = true;
|
||||
remember-last-server = false;
|
||||
remember-last-server = true;
|
||||
revision = 3;
|
||||
seconds-to-authorize = -1;
|
||||
session-timeout = 604800;
|
||||
|
||||
Reference in New Issue
Block a user