initialize generic rms-software repository

Add the reusable RMS core application (server, web UI, plugins, tests, tools) with generic defaults, GPL licensing, and maintainer context documentation so deployments can consume this repo as software source independent of station-specific overlays.
This commit is contained in:
2026-03-16 03:31:08 +01:00
commit e1a4ce0b8b
58 changed files with 20611 additions and 0 deletions

View File

@@ -0,0 +1,32 @@
async function createPlugin(ctx) {
return {
async execute(action, input) {
if (action !== "send_challenge") {
throw new Error(`Unknown action: ${action}`);
}
const payload = input && input.payload ? input.payload : {};
const recipient = input && input.recipient ? String(input.recipient) : "";
if (!recipient) {
throw new Error("recipient missing");
}
const entry = {
at: new Date().toISOString(),
via: "rms.auth.otp_email",
to: recipient,
from: String(ctx.getSetting("from", ctx.env.SMTP_FROM || "noreply@arcg.at")),
subject: String(payload.subject || "ARCG OTP"),
text: String(payload.text || ""),
html: String(payload.html || "")
};
await ctx.appendMailOutbox(entry);
return { ok: true, delivered: true, transport: "otp-email-plugin" };
},
async health() {
return { ok: true };
}
};
}
module.exports = {
createPlugin
};