Config Options & Environment Variables
Complete guide on configuring product options, resource limits, and environment variables for BetterPterodactyl in Paymenter.
Config Options allow your customers to tailor their servers during checkout (such as selecting RAM, choosing a server location, picking software versions, or adding backup slots) and upgrade those resources later from their client portal.
1. How Config Options Work in Paymenter
When you create a Config Option in Paymenter (Admin Area → Configuration → Config Options), the Environment Variable (env_variable) field determines which server setting or game egg variable is controlled on Pterodactyl.
Config Options have two levels:
Level 1: General Tab (The Parent Setting)
- Name: The label shown to your customer (e.g.
Server RAM,Location,Minecraft Version). - Environment Variable: The configuration key recognized by the extension (e.g.
memory,location,MC_VERSION). - Type: The form control displayed to the customer:
Select: Dropdown menu (one choice from a list). Supports pricing and upgrades.Radio: Radio button list (one choice from a list). Supports pricing and upgrades.Slider: Visual stepped slider bar. Supports pricing and upgrades.Checkbox: On/Off toggle. Supports pricing (maximum 1 child option).Number: Numeric input field where the customer types a number.Text: Freeform text box where the customer types text (e.g. license keys or server names).
- Upgradable: (For
Select,Radio,Slider) When checked, existing clients can upgrade or downgrade this resource later without losing their server. - Products: Select which product(s) offer this option.
Level 2: Options Tab (The Choices)
(Applies to Select, Radio, Slider, and Checkbox)
- Name: What the customer sees on the button or dropdown (e.g.
4 GB RAM,Germany (Frankfurt)). - Environment Variable: The exact value sent to Pterodactyl (e.g.
4096,1,paper.jar). - Pricing: Additional charge for this choice (Free, Recurring, or One-Time).
Note for Text & Number Types: When using
TextorNumber, no items are needed under the "Options" tab. The customer types their value directly during checkout, and Paymenter automatically sends their input to the parent's Environment Variable.
2. Complete Reference of Supported Variables
A. Server Hardware & Limits
| Environment Variable | Description | Value Format & Unit | Upgradable? |
|---|---|---|---|
memory | Maximum RAM allocated to the server | Number in MiB (1024 = 1 GB, 2048 = 2 GB, 4096 = 4 GB). Set to 0 for unlimited. | Yes |
cpu | CPU limit | Percentage (100 = 1 core, 200 = 2 cores, 400 = 4 cores). Set to 0 for unlimited. | Yes |
disk | Disk storage space | Number in MiB (5120 = 5 GB, 10240 = 10 GB, 51200 = 50 GB). Set to 0 for unlimited. | Yes |
swap | Swap memory allocation | Number in MiB (512, 1024). Set to 0 to disable swap, -1 for unlimited swap. | Yes |
io | Disk Block I/O priority weight | Number between 10 and 1000 (Pterodactyl default is 500). | Yes |
cpu_pinning | Pin container to specific host CPU threads | Comma-separated list or ranges (e.g. 0, 0,1, 0,2-4,6). Leave empty for default. | Yes |
B. Feature Limits & Addons
| Environment Variable | Description | Value Format | Upgradable? |
|---|---|---|---|
databases | Number of allowed MySQL/MariaDB databases | Whole number (0, 1, 2, 5). | Yes |
backups | Number of allowed server backup slots | Whole number (0, 1, 3, 5). | Yes |
additional_allocations | Extra ports allocated beyond the primary port | Whole number (0, 1, 2, 4). | Yes |
splits | Allowed sub-server splits (ServerSplitter addon) | Whole number (0, 1, 2). | Yes |
reverse_proxies | Allowed reverse proxies (ReverseProxy addon) | Whole number (0, 1). | Yes |
C. Server Deployment & Location
| Environment Variable | Description | Value Format | Where to Find It in Pterodactyl |
|---|---|---|---|
location (or location_ids) | Target datacenter location | Numeric Location ID (1, 2), or multiple comma-separated IDs (1,2). | Pterodactyl Admin → Locations (see ID column) |
node | Forces deployment onto one specific node | Numeric Node ID (1, 2). Leave empty for automatic node balancing. | Pterodactyl Admin → Nodes (see ID column) |
D. Nest & Egg Software Settings
| Environment Variable | Description | Value Format | Notes |
|---|---|---|---|
egg_id | Selects which Egg to use | Numeric Egg ID (1, 2, 3). | Allows clients to switch server types (Paper, Forge, Purpur, Bedrock). Upgradable! |
nest_id | Selects Nest ID (Pterodactyl 1.x) | Numeric Nest ID (1, 2). | Used on Pterodactyl 1.x installations. |
startup | Custom startup command override | Command string (e.g. java -Xms128M -Xmx{{SERVER_MEMORY}}M -jar {{SERVER_JARFILE}}). | Overrides the egg's default startup command. |
skip_scripts | Skip running the egg's install script | 1 (skip install scripts) or 0 (run scripts). | Useful for instant setups without running initial bash scripts. |
dedicated_ip | Require a dedicated IP address | 1 (dedicated unshared IP) or 0 (shared IP). | Server allocation will be placed on an unshared IP address. |
oom_killer | Linux Out-Of-Memory killer | 1 (enable OOM killer) or 0 (disable OOM killer). | When enabled, processes exceeding memory limits are terminated by the host OS. |
start_on_completion | Auto-start server upon creation | 1 (auto-boot) or 0 (leave offline). | Automatically starts server container after installation completes. |
E. Server Naming
| Environment Variable | Description | Value Format |
|---|---|---|
servername (or server_name) | Custom display name for the server | Text string (e.g. My Survival World, Community Discord Bot). |
F. Port Array Schemes
| Environment Variable | Description | Value Format | Example |
|---|---|---|---|
port_array | Map specific ports to egg variables | Valid JSON string with SERVER_PORT | {"SERVER_PORT": 25565, "RCON_PORT": 25575} |
G. Dynamic Egg Environment Variables (Game Settings)
Every egg in Pterodactyl defines custom environment variables. Any of these variables can be set as the Environment Variable in Paymenter!
To find the exact variable names for your egg:
- In Pterodactyl Admin, go to Nests → Eggs → Click on your Egg.
- Scroll to the Variables section.
- Look at the Environment Variable column (e.g.,
MC_VERSION,SERVER_JARFILE,BEDROCK_VERSION,FIVEM_LICENSE).
Common Egg Variables
- Minecraft (Paper / Spigot / Purpur / Vanilla):
SERVER_JARFILE: Name of the jar file (e.g.server.jar,paper.jar,purpur.jar).MC_VERSION: Minecraft version (e.g.latest,1.20.4,1.19.4,1.16.5).BUILD_NUMBER: Software build number (e.g.latest).
- Minecraft Bedrock:
BEDROCK_VERSION: Bedrock version (e.g.latest,1.20.50.03).
- FiveM:
FIVEM_LICENSE: FiveM server license key from Cfx.re Keymaster.SERVER_HOSTNAME: FiveM server display name.
- Rust:
RUST_BRANCH: Game branch (release,staging).SERVER_SEED: World generation seed number.WORLD_SIZE: Map size in meters (e.g.3000,4000).
- Source Engine (CS2 / TF2 / GMod):
SRCDS_MAP: Default starting map (e.g.de_dust2).SRCDS_TOKEN: Steam Game Server Login Token (GSLT).
- Discord Bots (NodeJS / Python):
BOT_JS_FILE: Main executable script (e.g.index.js,main.py).AUTO_UPDATE:0(off) or1(on).GIT_ADDRESS: Git repository clone URL.
3. Step-by-Step Creation Examples
Example 1: RAM / Memory Dropdown (With Pricing & Upgrades)
Create a dropdown where customers choose their RAM allocation and can upgrade it anytime.
- Navigate to Admin Area → Configuration → Config Options and click Create.
- General Tab:
- Name:
Server RAM - Description:
Select how much memory your server needs. - Environment Variable:
memory - Type:
Select(orSlider) - Upgradable: Checked (allows clients to upgrade later!)
- Products: Select your game server product(s).
- Name:
- Options Tab:
- Click Add Option:
- Name:
2 GB RAM - Environment Variable:
2048 - Pricing: Base price (e.g., Free / $0.00)
- Name:
- Click Add Option:
- Name:
4 GB RAM - Environment Variable:
4096 - Pricing: Recurring (e.g., +$4.00 / month)
- Name:
- Click Add Option:
- Name:
8 GB RAM - Environment Variable:
8192 - Pricing: Recurring (e.g., +$12.00 / month)
- Name:
- Click Add Option:
- Click Create to save.
Example 2: Server Location Selector (Datacenter / City)
Allow clients to pick which datacenter hosts their server.
- Check your Location IDs in Pterodactyl Admin → Locations (e.g. Frankfurt is
1, New York is2). - In Paymenter, go to Config Options → Create.
- General Tab:
- Name:
Server Location - Description:
Choose the location closest to your players. - Environment Variable:
location - Type:
Select(orRadio) - Products: Select your product(s).
- Name:
- Options Tab:
- Click Add Option:
- Name:
Frankfurt, Germany - Environment Variable:
1
- Name:
- Click Add Option:
- Name:
New York, USA - Environment Variable:
2
- Name:
- Click Add Option:
- Click Create to save.
Example 3: Extra Backups Addon
Sell optional backup slots to clients.
- Go to Config Options → Create.
- General Tab:
- Name:
Backup Slots - Description:
Automated server backup snapshots. - Environment Variable:
backups - Type:
Select - Upgradable: Checked
- Products: Select your product(s).
- Name:
- Options Tab:
- Option 1: Name:
1 Backup (Included), Environment Variable:1, Price: Free. - Option 2: Name:
3 Backups, Environment Variable:3, Price: +$1.00 / month. - Option 3: Name:
5 Backups, Environment Variable:5, Price: +$2.50 / month.
- Option 1: Name:
- Click Create to save.
Example 4: Dedicated IP (Checkbox Option)
Add a simple one-click checkbox for a dedicated IP address.
- Go to Config Options → Create.
- General Tab:
- Name:
Dedicated IP - Description:
Assign an exclusive, dedicated IP to your server. - Environment Variable:
dedicated_ip - Type:
Checkbox - Products: Select your product(s).
- Name:
- Options Tab:
- Click Add Option (Checkbox supports 1 child option):
- Name:
Dedicated IP Address - Environment Variable:
1 - Pricing: Recurring +$3.00 / month.
- Name:
- Click Add Option (Checkbox supports 1 child option):
- Click Create to save.
Example 5: FiveM License Key (Text Input)
Collect a customer's license key during order checkout.
- Go to Config Options → Create.
- General Tab:
- Name:
FiveM License Key - Description:
Enter your key from keymaster.fivem.net. - Environment Variable:
FIVEM_LICENSE - Type:
Text - Products: Select your FiveM product(s).
- Name:
- (No entries needed under the Options tab — customers type their key directly into a text field at checkout).
- Click Create to save.
Example 6: Custom Server Name (Text Input)
Allow customers to give their server a custom name upon order.
- Go to Config Options → Create.
- General Tab:
- Name:
Server Name - Description:
Enter a custom name for your server. - Environment Variable:
servername - Type:
Text - Products: Select your product(s).
- Name:
- Click Create to save.
4. Quick Rule-of-Thumb Checklist
- Exact Spelling:
- Resource variables must be exact lowercase:
memory,cpu,disk,swap,io,databases,backups,additional_allocations,location,node,egg_id. - Egg variables must match the exact case defined in your Pterodactyl egg (usually uppercase:
MC_VERSION,SERVER_JARFILE,FIVEM_LICENSE).
- Resource variables must be exact lowercase:
- Correct Units:
- RAM (
memory), Disk (disk), and Swap (swap) are in MiB (1024= 1 GB). - CPU (
cpu) is in Percentage (100= 1 thread/core). - Toggles (
dedicated_ip,skip_scripts,oom_killer,start_on_completion) use1for Yes and0for No.
- RAM (
- Enable Upgrades:
- Always check the Upgradable box for hardware limits (
memory,cpu,disk,backups,additional_allocations) so customers can upgrade their plans without needing manual support tickets.
- Always check the Upgradable box for hardware limits (