Skip to main content
This page outlines the baseline requirements for running Dietrich Development RedM scripts. It covers server environment, frameworks, database, and configuration prerequisites.
This document focuses on requirements only. For installation steps, see Installation & Configuration and Quickstart.

1. Server environment

Supported OS

Windows Server 2019/2022 or modern Linux distributions (Ubuntu 20.04+). Keep the OS updated.

RedM server build

Use a recent stable RedM build. Avoid outdated artifacts to ensure API compatibility.

Hardware

Minimum: 2 vCPU, 4 GB RAM for testing. Production varies by player count and scripts.

Network

Stable connection, open required ports (default RedM), and low latency for remote DB access.

2. Software dependencies

  • oxmysql (latest) for database access
  • A framework (optional, but recommended): VORP or RSG
  • Git or similar for version control (recommended)
  • Editor with Lua/MDX support
Some scripts may require additional resources (UI packs, inventories, maps). Refer to each script’s page.

3. Framework compatibility

Our scripts include a frameworkBridge.lua to support multiple frameworks:
  • VORP (vorp_core)
  • RSG (rsg-core)
  • Custom (implemented by you)
You can explicitly set the framework in your config.lua:
Config.Framework = "vorp" -- or "rsg" / "custom"
If neither VORP nor RSG is detected and you do not set a framework, the bridge defaults to custom. In that case, implement the required functions in frameworkBridge.lua (player data, money, items, notifications).

4. Database configuration (oxmysql)

Ensure a reachable MySQL/MariaDB instance and configure the connection string in server.cfg:
set mysql_connection_string "mysql://user:password@host/database?charset=utf8mb4"
Basic connectivity test:
local ok = MySQL.query.await("SELECT 1 as ok")
print(ok and ok[1] and ok[1].ok)
Use parameter placeholders (?) for all queries and avoid string concatenation to prevent injection vulnerabilities.

5. File and folder conventions

Recommended layout:
server-data/
  resources/
    [core]/
      vorp_core
      rsg-core
    [deps]/
      oxmysql
    [custom]/
      my_script_name/
        client.lua
        server.lua
        config.lua
        frameworkBridge.lua
The folder name must match the name you use in server.cfg.

6. server.cfg order

Start dependencies before your scripts:
ensure oxmysql
ensure vorp_core   # if used
ensure rsg-core    # if used

ensure my_script_name
The order matters. Frameworks and shared libraries must be started before dependent scripts.

7. Permissions and security

  • Run the RedM process with least-required OS permissions
  • Restrict database user to the specific schema and statements needed
  • Avoid exposing database ports to the internet without firewall rules or VPN
  • Validate all client-sent data on the server

8. Verification checklist

  • RedM server starts without errors
  • oxmysql connects successfully
  • Required framework detected or Config.Framework is set
  • Script folder name and ensure entry match exactly
  • No warnings in console after joining the server

9. Troubleshooting requirements

Check the connection string, credentials, and that the DB is reachable from the host. Verify firewall rules and SSL if applicable.
Ensure the framework resource is started before your script or set Config.Framework explicitly.
Confirm the folder name matches the ensure entry. Check for syntax errors and missing dependencies.
For performance tuning and deeper debugging, see Performance Tips and Debugging & Troubleshooting.
I