Compare commits
6 Commits
main
...
23e24401f5
| Author | SHA1 | Date | |
|---|---|---|---|
| 23e24401f5 | |||
| 159b1dfcf2 | |||
| 53aef18976 | |||
| 228dcfd674 | |||
| cf7d66de02 | |||
| 51e2429dd4 |
@@ -104,7 +104,6 @@
|
|||||||
domain = "games.alexion.dev";
|
domain = "games.alexion.dev";
|
||||||
protocol = "https";
|
protocol = "https";
|
||||||
port = 80;
|
port = 80;
|
||||||
clientMaxBodySize = "0";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -71,10 +71,7 @@ let
|
|||||||
extraConfig = lib.optionalString (route.clientMaxBodySize != null) ''
|
extraConfig = lib.optionalString (route.clientMaxBodySize != null) ''
|
||||||
client_max_body_size ${route.clientMaxBodySize};
|
client_max_body_size ${route.clientMaxBodySize};
|
||||||
'';
|
'';
|
||||||
locations."/" = {
|
locations."/".proxyPass = mkBackend address port;
|
||||||
proxyPass = mkBackend address port;
|
|
||||||
proxyWebsockets = true;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
{
|
{
|
||||||
config,
|
config,
|
||||||
lib,
|
lib,
|
||||||
pkgs,
|
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
@@ -32,33 +31,13 @@ in
|
|||||||
|
|
||||||
services.romm = {
|
services.romm = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.alexion.romm;
|
|
||||||
group = "storage";
|
group = "storage";
|
||||||
database.createLocally = true;
|
database.createLocally = true;
|
||||||
redis.createLocally = true;
|
redis.createLocally = true;
|
||||||
watcher.enable = true;
|
watcher.enable = true;
|
||||||
extraEnvironment = {
|
|
||||||
HASHEOUS_API_ENABLED = "true";
|
|
||||||
PLAYMATCH_API_ENABLED = "true";
|
|
||||||
ROM_CONVERTO_ENABLED = "false";
|
|
||||||
};
|
|
||||||
inherit (cfg) environmentFile;
|
inherit (cfg) environmentFile;
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.services.romm-worker.serviceConfig.ExecStart =
|
|
||||||
lib.mkForce "${lib.getExe' config.services.romm.package "romm-worker"} scans";
|
|
||||||
|
|
||||||
systemd.tmpfiles.settings."10-romm"."${config.services.romm.dataDir}/config/config.yml"."L+".argument =
|
|
||||||
toString (
|
|
||||||
(pkgs.formats.yaml { }).generate "romm-config.yml" {
|
|
||||||
emulatorjs.auto_save_sync = false;
|
|
||||||
filesystem.structure = {
|
|
||||||
default = "roms/{platform}/{game}";
|
|
||||||
firmware = "bios/{platform}";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
);
|
|
||||||
|
|
||||||
users.users = {
|
users.users = {
|
||||||
romm.uid = config.registry."stable-uid".${config.networking.hostName}.romm;
|
romm.uid = config.registry."stable-uid".${config.networking.hostName}.romm;
|
||||||
redis-romm.uid = config.registry."stable-uid".${config.networking.hostName}."redis-romm";
|
redis-romm.uid = config.registry."stable-uid".${config.networking.hostName}."redis-romm";
|
||||||
|
|||||||
@@ -3,8 +3,8 @@ aliases:
|
|||||||
- "0015"
|
- "0015"
|
||||||
- RomM 5.4 Package
|
- RomM 5.4 Package
|
||||||
date-created: 2026-10-19 19:40
|
date-created: 2026-10-19 19:40
|
||||||
date-modified: 2026-10-21 00:01
|
date-modified: 2026-10-19 19:40
|
||||||
status: closed
|
status: open
|
||||||
area: "[[homelab]]"
|
area: "[[homelab]]"
|
||||||
blocked-by:
|
blocked-by:
|
||||||
- "[[0014-romm-guest]]"
|
- "[[0014-romm-guest]]"
|
||||||
|
|||||||
@@ -4,7 +4,5 @@
|
|||||||
inherit root;
|
inherit root;
|
||||||
};
|
};
|
||||||
|
|
||||||
romm = pkgs.callPackage ./romm.nix { };
|
|
||||||
|
|
||||||
waybar = pkgs.callPackage ./waybar.nix { };
|
waybar = pkgs.callPackage ./waybar.nix { };
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,124 +0,0 @@
|
|||||||
{
|
|
||||||
buildNpmPackage,
|
|
||||||
fetchFromGitHub,
|
|
||||||
lib,
|
|
||||||
python3,
|
|
||||||
romm,
|
|
||||||
}:
|
|
||||||
romm.overrideAttrs (
|
|
||||||
finalAttrs: previousAttrs:
|
|
||||||
let
|
|
||||||
frontend = buildNpmPackage {
|
|
||||||
pname = "romm-frontend";
|
|
||||||
inherit (finalAttrs) version;
|
|
||||||
src = "${finalAttrs.src}/frontend";
|
|
||||||
|
|
||||||
npmDepsHash = "sha256-f5IcpOVv7JYFzUPkZIq5nbT3dS1f/KCSllh8Vkgl1P0=";
|
|
||||||
npmFlags = [ "--ignore-scripts" ];
|
|
||||||
makeCacheWritable = true;
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
runHook preInstall
|
|
||||||
cp -r dist $out
|
|
||||||
chmod u+w $out/assets
|
|
||||||
cp -r assets/. $out/assets/
|
|
||||||
runHook postInstall
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
# RomM 5.4 requires packages absent from the Nixpkgs 5.2 environment.
|
|
||||||
pythonEnv = python3.withPackages (
|
|
||||||
ps: with ps; [
|
|
||||||
aiohttp
|
|
||||||
alembic
|
|
||||||
anyio
|
|
||||||
apprise
|
|
||||||
asyncssh
|
|
||||||
authlib
|
|
||||||
bcrypt
|
|
||||||
colorama
|
|
||||||
croniter
|
|
||||||
cryptography
|
|
||||||
defusedxml
|
|
||||||
email-validator
|
|
||||||
fastapi
|
|
||||||
gunicorn
|
|
||||||
httpx
|
|
||||||
httpx2
|
|
||||||
itsdangerous
|
|
||||||
jinja2
|
|
||||||
joserfc
|
|
||||||
mariadb
|
|
||||||
mutagen
|
|
||||||
mysql-connector-python
|
|
||||||
opentelemetry-distro
|
|
||||||
opentelemetry-exporter-otlp
|
|
||||||
opentelemetry-instrumentation-aiohttp-client
|
|
||||||
opentelemetry-instrumentation-fastapi
|
|
||||||
opentelemetry-instrumentation-httpx
|
|
||||||
opentelemetry-instrumentation-redis
|
|
||||||
opentelemetry-instrumentation-sqlalchemy
|
|
||||||
passlib
|
|
||||||
pillow
|
|
||||||
psycopg
|
|
||||||
pydantic
|
|
||||||
pydash
|
|
||||||
python-dotenv
|
|
||||||
python-magic
|
|
||||||
python-multipart
|
|
||||||
python-socketio
|
|
||||||
pyyaml
|
|
||||||
redis
|
|
||||||
rq
|
|
||||||
rq-scheduler
|
|
||||||
sentry-sdk
|
|
||||||
sqlalchemy
|
|
||||||
starlette
|
|
||||||
streaming-form-data
|
|
||||||
strsimpy
|
|
||||||
ua-parser
|
|
||||||
unidecode
|
|
||||||
uvicorn
|
|
||||||
uvicorn-worker
|
|
||||||
watchfiles
|
|
||||||
yarl
|
|
||||||
zipfile-inflate64
|
|
||||||
zstandard
|
|
||||||
]
|
|
||||||
);
|
|
||||||
in
|
|
||||||
{
|
|
||||||
version = "5.4.0";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "rommapp";
|
|
||||||
repo = "romm";
|
|
||||||
tag = finalAttrs.version;
|
|
||||||
hash = "sha256-oIYEdIAJgXkcqjZtWlWKD/NFiQ3gbo7gxwLhqZOCWpM=";
|
|
||||||
};
|
|
||||||
|
|
||||||
postPatch = previousAttrs.postPatch + ''
|
|
||||||
# Redis 8.0.1 removed this argument.
|
|
||||||
# RomM disables the related maintenance notifications.
|
|
||||||
substituteInPlace backend/handler/redis_handler.py \
|
|
||||||
--replace-fail 'from redis.maint_notifications import MaintNotificationsConfig' "" \
|
|
||||||
--replace-fail ' "maint_notifications_config": MaintNotificationsConfig(enabled=False),' ""
|
|
||||||
'';
|
|
||||||
|
|
||||||
installPhase =
|
|
||||||
lib.replaceStrings
|
|
||||||
[
|
|
||||||
"${previousAttrs.passthru.frontend}"
|
|
||||||
"${previousAttrs.passthru.pythonEnv}"
|
|
||||||
]
|
|
||||||
[
|
|
||||||
"${frontend}"
|
|
||||||
"${pythonEnv}"
|
|
||||||
]
|
|
||||||
previousAttrs.installPhase;
|
|
||||||
|
|
||||||
passthru = previousAttrs.passthru // {
|
|
||||||
inherit frontend pythonEnv;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
)
|
|
||||||
Reference in New Issue
Block a user