PageSourceSearch

https://pocket-relay.pages.dev/assets/js/a383001f.e59947ee.js

js pocket-relay.pages.dev collected 2026-10-03 05:30:35 UTC 31,173 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunkpocket_relay_website=self.webpackChunkpocket_relay_website||[]).push([[7746],{2527:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>l,contentTitle:()=>o,default:()=>c,frontMatter:()=>t,metadata:()=>a,toc:()=>h});var s=i(5893),r=i(1151);const t={sidebar_position:4,pagination_prev:null,pagination_next:null,slug:"configuration"},o="Configuration",a={id:"server/configuration",title:"Configuration",description:"Configure your server",source:"@site/docs/server/4-configuration.md",sourceDirName:"server",slug:"/server/configuration",permalink:"/docs/server/configuration",draft:!1,unlisted:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{sidebar_position:4,pagination_prev:null,pagination_next:null,slug:"configuration"},sidebar:"docs"},l={},h=[{value:"Default Configuration",id:"default-configuration",level:2},{value:"Environment Variable",id:"environment-variable",level:2},{value:"Server Host",id:"server-host",level:2},{value:"Server Port",id:"server-port",level:2},{value:"Reverse Proxy",id:"reverse-proxy",level:2},{value:"QoS",id:"qos",level:2},{value:"Official",id:"official",level:3},{value:"Local",id:"local",level:3},{value:"Custom",id:"custom",level:3},{value:"Disabled",id:"disabled",level:3},{value:"Hamachi",id:"hamachi",level:3},{value:"Dashboard",id:"dashboard",level:2},{value:"Super Admin",id:"super-admin",level:3},{value:"Super Email",id:"super-email",level:4},{value:"Super Password",id:"super-password",level:4},{value:"Disable account registration",id:"disable-account-registration",level:3},{value:"Menu Message",id:"menu-message",level:2},{value:"Galaxy At War",id:"galaxy-at-war",level:2},{value:"Daily Decay",id:"daily-decay",level:3},{value:"Include Promotions",id:"include-promotions",level:3},{value:"Logging",id:"logging",level:2},{value:"Retriever",id:"retriever",level:2},{value:"Enabled",id:"enabled",level:3},{value:"Origin Fetch",id:"origin-fetch",level:3},{value:"Origin Fetch Data",id:"origin-fetch-data",level:3},{value:"Tunnel",id:"tunnel",level:2},{value:"Stricter",id:"stricter",level:3},{value:"Always",id:"always",level:3},{value:"Disabled",id:"disabled-1",level:3},{value:"UDP Tunnel",id:"udp-tunnel",level:2},{value:"UDP Tunnel Port",id:"udp-tunnel-port",level:3},{value:"UDP Tunnel External Port",id:"udp-tunnel-external-port",level:3},{value:"UDP Tunnel Enabled",id:"udp-tunnel-enabled",level:3},{value:"API",id:"api",level:2},{value:"Public games API",id:"public-games-api",level:3},{value:"Hide players from public games",id:"hide-players-from-public-games",level:3}];function d(e){const n={a:"a",admonition:"admonition",blockquote:"blockquote",code:"code",em:"em",h1:"h1",h2:"h2",h3:"h3",h4:"h4",header:"header",hr:"hr",img:"img",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,r.a)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.header,{children:(0,s.jsx)(n.h1,{id:"configuration",children:"Configuration"})}),"\n",(0,s.jsx)(n.p,{children:"Configure your server"}),"\n",(0,s.jsx)(n.admonition,{type:"note",children:(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"Every"}),"time you change the configuration you must restart the server before the changes will be applied"]})}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsxs)(n.p,{children:["The server configuration is loaded from a file named ",(0,s.jsx)(n.strong,{children:"config.json"})," this file is in the same folder as the server executable ",(0,s.jsx)(n.strong,{children:"NOT"})," the data folder."]})}),"\n",(0,s.jsxs)(n.p,{children:["This configuration file will ",(0,s.jsx)(n.strong,{children:"NOT"})," be created for you. You will have to manually create the config.json file on your own."]}),"\n",(0,s.jsx)(n.admonition,{type:"tip",children:(0,s.jsxs)(n.p,{children:["You can now generate a config using the ",(0,s.jsx)(n.a,{href:"/docs/server/configuration-builder",children:"Configuration Builder"})," tool rather than typing out the options manually"]})}),"\n",(0,s.jsx)(n.h2,{id:"default-configuration",children:"Default Configuration"}),"\n",(0,s.jsx)(n.p,{children:"Below is the default configuration, you can omit any of the fields below from the configuration and their default values will be used instead"}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsx)(n.p,{children:"You can find all the descriptions for each of the configuration options under this section"})}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",metastring:"title=config.json",children:'{\n  "host": "0.0.0.0",\n  "port": 80,\n  "reverse_proxy": false,\n  "dashboard": {\n    "super_email": "",\n    "super_password": "",\n    "disable_registration": false\n  },\n  "menu_message": "<font color=\'#B2B2B2\'>Pocket Relay</font> - <font color=\'#FFFF66\'>Logged as: {n}</font>",\n  "galaxy_at_war": {\n    "decay": 0.0,\n    "promotions": true\n  },\n  "logging": "info",\n  "retriever": {\n    "enabled": true,\n    "origin_fetch": true,\n    "origin_fetch_data": true\n  },\n  "tunnel": "stricter",\n  "udp_tunnel": {\n    "port": 9032,\n    "external_port": 9032,\n    "enabled": true\n  },\n  "api": {\n    "public_games": false,\n    "public_games_hide_players": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"environment-variable",children:"Environment Variable"}),"\n",(0,s.jsxs)(n.p,{children:["The server supports the ",(0,s.jsx)(n.code,{children:"PR_CONFIG_JSON"})," environment variable which you can use to directly pass in the server configuration JSON through an environment variable"]}),"\n",(0,s.jsxs)(n.admonition,{type:"note",children:[(0,s.jsx)(n.p,{children:"This variable accepts the raw JSON and not a path to a file. i.e the following"}),(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-env",children:'PR_CONFIG_JSON={"port": 80}\n'})})]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"server-host",children:"Server Host"}),"\n",(0,s.jsxs)(n.blockquote,{children:["\n",(0,s.jsx)(n.p,{children:"Requires upcoming server version v0.5.11"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:"The server host property configures which address the server will listen for connections on, by default\nthe server will listen for connections on any interface using 0.0.0.0, you can change this by specifying\nthe specific IP to listen on."}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "host": "0.0.0.0"\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"server-port",children:"Server Port"}),"\n",(0,s.jsx)(n.p,{children:"The server port property configures which port the server will be running on"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "port": 80\n}\n'})}),"\n",(0,s.jsx)(n.p,{children:"The server port can be any number between 1 and 65536,"}),"\n",(0,s.jsx)(n.admonition,{type:"caution",children:(0,s.jsx)(n.p,{children:"Using any server port below 1024 on Linux will require that you lau
1nch the server using sudo"})}),"\n",(0,s.jsx)(n.admonition,{type:"note",children:(0,s.jsx)(n.p,{children:"Changing this port will require that you specify the port in both the Connection URL and when accessing the dashboard from the browser"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"reverse-proxy",children:"Reverse Proxy"}),"\n",(0,s.jsxs)(n.p,{children:["This property configures whether the server is behind a reverse proxy or not. If you are using\na reverse proxy you should set this to ",(0,s.jsx)(n.code,{children:"true"}),". If you don't set this to ",(0,s.jsx)(n.code,{children:"true"})," and you are using\na reverse proxy clients will ",(0,s.jsx)(n.strong,{children:"NOT"})," be able to connect to each other"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "reverse_proxy": false\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"qos",children:"QoS"}),"\n",(0,s.jsxs)(n.blockquote,{children:["\n",(0,s.jsx)(n.p,{children:"QoS configuration is only present in server v0.5.10 and above"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:"This property configures the QoS server that the game will use"}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsxs)(n.p,{children:["This is important if you are hosting a ",(0,s.jsx)(n.strong,{children:"WAN"}),' server as some users may not be able\nto connect to each-other if you don\'t use the "official" QoS servers due to a current\nserver limitation']})}),"\n",(0,s.jsx)(n.h3,{id:"official",children:"Official"}),"\n",(0,s.jsxs)(n.p,{children:['Specifying the "qos" configuration below will tell clients to use the official QoS server, you will\nlikely want to use this option if you are hosting a ',(0,s.jsx)(n.strong,{children:"WAN"})," server (Theres no reason to use the official server if you are hosting a ",(0,s.jsx)(n.strong,{children:"LAN"})," or ",(0,s.jsx)(n.strong,{children:"Extended LAN"})," network)"]}),"\n",(0,s.jsx)(n.p,{children:"Using the official QoS server fixes a bug that prevents some players from joining each other on your server."}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "qos": {\n    "type": "official"\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"local",children:"Local"}),"\n",(0,s.jsxs)(n.p,{children:['Specifying the "qos" configuration below will tell clients to use the built in QoS server. This works if you are only hosting a ',(0,s.jsx)(n.strong,{children:"LAN"}),"/",(0,s.jsx)(n.strong,{children:"Extended LAN"})," server, if you are creating a ",(0,s.jsx)(n.strong,{children:"WAN"})," server you should use the ",(0,s.jsx)(n.a,{href:"#official",children:"Official"})," QoS server instead"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "qos": {\n    "type": "local"\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"custom",children:"Custom"}),"\n",(0,s.jsx)(n.p,{children:'Specifying the "qos" configuration below will tell clients to use the provided custom QoS server. This is undocumented and only added for future use or a fallback if the official server address becomes unavailable'}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "qos": {\n    "type": "custom",\n    "host": "example.com",\n    "port": 17899\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"disabled",children:"Disabled"}),"\n",(0,s.jsxs)(n.blockquote,{children:["\n",(0,s.jsx)(n.p,{children:"Requires upcoming server version v0.5.11"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:"Specifying the \"qos\" configuration below will tell clients not to use a QoS server at all. This will disable public IP address resolution and can be good if you're only playing locally and don't want clients to resolve their public addresses"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "qos": {\n    "type": "disabled"\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"hamachi",children:"Hamachi"}),"\n",(0,s.jsxs)(n.blockquote,{children:["\n",(0,s.jsx)(n.p,{children:"Requires upcoming server version v0.5.11"}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:'Specifying the "qos" configuration below will treat the networking of clients as one which is within a Hamachi virtual network. You cannot use this option if you want anyone to connect from outside hamachi as they won\'t be able to join other players.'}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "qos": {\n    "type": "hamachi",\n    "host": "25.54.101.58"\n  }\n}\n'})}),"\n",(0,s.jsxs)(n.admonition,{type:"info",children:[(0,s.jsxs)(n.p,{children:['Set the "host" field to be the Hamachi virtual address, visible for the person hosting the Hamachi network (They also need to be running the server), specifically the\n',(0,s.jsx)(n.strong,{children:"IPv4"})," address ",(0,s.jsx)(n.strong,{children:"NOT"})," the IPv6 ",(0,s.jsx)(n.em,{children:"(IPv6 is not supported by Pocket Relay)"})]}),(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{alt:"Hamachi virtual address",src:i(1544).Z+"",width:"144",height:"144"})})]}),"\n",(0,s.jsx)(n.h2,{id:"dashboard",children:"Dashboard"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "dashboard": {\n    "super_email": "[email protected]",\n    "super_password": "password",\n    "disable_registration": false\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"super-admin",children:"Super Admin"}),"\n",(0,s.jsx)(n.p,{children:'For the administrative portion of Pocket Relay (Editing inventories and managing players), you need to assign a "Super Admin" account, this account is capable of managing the server with access to server logs and such, the Server Admin can then give out "Admin" role to other players on the server which is a role with slightly less permissions.'}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsxs)(n.p,{children:["Super admins are ",(0,s.jsx)(n.strong,{children:"NOT"})," separate accounts, they use the accounts that are created on the server so you must either create an account in-game or through the dashboard, in order for the server to give them super admin."]})}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsx)(n.p,{children:"The super admin role is checked and assigned every time the server restarts and when accounts are created"})}),"\n",(0,s.jsx)(n.h4,{id:"super-email",children:"Super Email"}),"\n",(0,s.jsx)(n.p,{children:"The super email field is used to set the email of the account that should be given the super admin role:"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "dashboard": {\n    "super_email": "[email protected]"\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h4,{id:"super-password",children:"Super Password"}),"\n",(0,s.jsxs)(n.p,{children:["This field is optional but it's helpful if you are using an ",(0,s.jsx)(n.strong,{children:"Origin"})," account for your ",(0,s.jsx)(n.strong,{children:"Super Admin"})," as ",(0,s.jsx)(n.strong,{children:"Origin"})," accounts don't have any password unless one is set through the dashboard. This property assigns the password of the ",(0,s.jsx)(n.strong,{children:"Super Admin"})," to the provided password:"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "dashboard": {\n    "super_password": "password"\n  }\n}\n'})}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsx)(n.p,{children:"If the account already exists the password will be applied the next time the server restarts, otherwise it will be applied when the account is created"})}),"\n",(0,s.jsx)(n.admonition,{type:"warning",children:(0,s.jsx)(n.p,{children:"If you don't want to use this then remove the field from your JSON config entirely, don't set it to blank as that will simply assign the user a blank password. (This has been fixed in a yet to be released version so is a problem for now)"})}),"\n",(0,s.jsx)(n.h3,{id:"disable-account-registration",children:"Disable account registration"}),"\n",(0,s.jsx)(n.p,{children:"You can use this property to disable registering accounts through the dashboard (Only allow player to create account in-game) this can be useful if you are running a public server and don't want people who aren't using the server creating accounts"}),"\n",(0,s.jsxs)(n.p,{children:["The default for this is ",(0,s.jsx)(n.code,{children:"false"})," which allows users to create accounts through the dashboard. Setting this to ",(0,s.jsx)(n.code,{children:"true"})," will prevent this behavior."]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "dashboard": {\n    "disable_registration": false\n  }\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"menu-message",children:"Menu Message"}),"\n",(0,s.jsx)(n.p,{children:"The menu message configuration contains the message that will be displayed on the Main Menu within Mass Effect 3."}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:"{\n  \"menu_message\"
1: \"<font color='#B2B2B2'>Pocket Relay</font> - <font color='#FFFF66'>Logged as: {n}</font>\"\n}\n"})}),"\n",(0,s.jsx)(n.p,{children:"The menu message can make use of the font element to change the color of the text contained with. This uses hex color codes"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-html",children:'<font color="#FFFFFF">Something</font>\n'})}),"\n",(0,s.jsx)(n.p,{children:"The menu message also has some placeholder variables that you can use. The server will replace the placeholders before sending the message to the client"}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"Placeholder"}),(0,s.jsx)(n.th,{children:"Description"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"{v}"})}),(0,s.jsx)(n.td,{children:"The server version number"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:(0,s.jsx)(n.code,{children:"{n}"})}),(0,s.jsx)(n.td,{children:"The player account name"})]})]})]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"galaxy-at-war",children:"Galaxy At War"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "galaxy_at_war": {\n    "decay": 0.0,\n    "promotions": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"daily-decay",children:"Daily Decay"}),"\n",(0,s.jsx)(n.p,{children:"In the default server configuration your Galaxy At War progress will not decay at all, this is because \u201cdecay\u201d is set to 0.0 which doesn\u2019t decay at all."}),"\n",(0,s.jsx)(n.admonition,{title:"Example",type:"info",children:(0,s.jsx)(n.p,{children:"0.5 = -1% for each galaxy at war area over each day passed that the player wasn\u2019t active for"})}),"\n",(0,s.jsx)(n.p,{children:"Setting this to 0.0 will prevent any decay from happening"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "galaxy_at_war": {\n    "decay": 0.0\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"include-promotions",children:"Include Promotions"}),"\n",(0,s.jsx)(n.p,{children:"This property determines whether your total character promotions is included as a Galaxy At War asset:"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "galaxy_at_war": {\n    "promotions": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"logging",children:"Logging"}),"\n",(0,s.jsx)(n.p,{children:"This logging configuration tells the server what level of logging it should show in both the log file and the program output."}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "logging": "info"\n}\n'})}),"\n",(0,s.jsx)(n.admonition,{type:"tip",children:(0,s.jsx)(n.p,{children:'For normal usage you should ideally leave the server in "info" logging mode, as the "debug" mode can cause the server log file to become quite large.'})}),"\n",(0,s.jsx)(n.admonition,{type:"caution",children:(0,s.jsxs)(n.p,{children:["Server log files can contain personal access tokens, so it is recommend you do ",(0,s.jsx)(n.strong,{children:"NOT"})," post them publicly anywhere, only sharing them with\nthe ",(0,s.jsx)(n.strong,{children:"Pocket Relay"})," developer if you need to debug an issue"]})}),"\n",(0,s.jsx)(n.p,{children:"The server log file is stored in the following file:"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{children:"data/server.log\n"})}),"\n",(0,s.jsx)(n.p,{children:"The following is a list of available logging levels"}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsx)(n.p,{children:"Every level inherits all the logging from the level below it i.e debug inherits all logging from info and warn"})}),"\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{children:"Level"}),(0,s.jsx)(n.th,{children:"Description"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:"debug"}),(0,s.jsx)(n.td,{children:"Shows all logging including debug messages"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:"info"}),(0,s.jsx)(n.td,{children:"Shows informational logging, warning and error logging"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:"warn"}),(0,s.jsx)(n.td,{children:"Only shows warning and error logs"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:"error"}),(0,s.jsx)(n.td,{children:"Only shows error logs"})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{children:"off"}),(0,s.jsx)(n.td,{children:"Doesn\u2019t show any logs"})]})]})]}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"retriever",children:"Retriever"}),"\n",(0,s.jsx)(n.p,{children:"The retriever section contains settings for how the server will handle needing to reach out to the official servers for data"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "retriever": {\n    "enabled": true,\n    "origin_fetch": true,\n    "origin_fetch_data": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"enabled",children:"Enabled"}),"\n",(0,s.jsx)(n.admonition,{type:"caution",children:(0,s.jsxs)(n.p,{children:["If you disable this setting players using an ",(0,s.jsx)(n.strong,{children:"Origin"})," account will not be able to connect to your server without ",(0,s.jsx)(n.a,{href:"../client/origin-unlinking",children:"Unlinking from Origin"})]})}),"\n",(0,s.jsxs)(n.p,{children:["This setting determines whether fetching data from the official servers is allowed or not. Setting this to fal
1se will disable both ",(0,s.jsx)(n.a,{href:"#origin-fetch",children:"Origin Fetch"})," and ",(0,s.jsx)(n.a,{href:"#origin-fetch-data",children:"Origin Fetch Data"})]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "retriever": {\n    "enabled": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"origin-fetch",children:"Origin Fetch"}),"\n",(0,s.jsx)(n.admonition,{type:"caution",children:(0,s.jsxs)(n.p,{children:["If you disable this setting players using an ",(0,s.jsx)(n.strong,{children:"Origin"})," account will not be able to connect to your server without ",(0,s.jsx)(n.a,{href:"../client/origin-unlinking",children:"Unlinking from Origin"})]})}),"\n",(0,s.jsxs)(n.p,{children:["This setting determines whether the server is allowed to use the official server to authenticate ",(0,s.jsx)(n.strong,{children:"Origin"})," accounts."]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "retriever": {\n    "origin_fetch": true,\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"origin-fetch-data",children:"Origin Fetch Data"}),"\n",(0,s.jsxs)(n.p,{children:["This setting determines whether the server should also fetch and copy over the player data of ",(0,s.jsx)(n.strong,{children:"Origin"})," accounts when creating them for the first time."]}),"\n",(0,s.jsx)(n.p,{children:"The player data is only copied over when the account is first authenticated, future logins won\u2019t cause the data to be loaded account."}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "retriever": {\n    "origin_fetch_data": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"tunnel",children:"Tunnel"}),"\n",(0,s.jsxs)(n.blockquote,{children:["\n",(0,s.jsxs)(n.p,{children:["New server connection tunneling is included in server version >= v0.6.0-beta and client version >= 0.4.0\nfor details about tunneling see ",(0,s.jsx)(n.a,{href:"https://github.com/PocketRelay/Server/issues/64",children:"https://github.com/PocketRelay/Server/issues/64"})]}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:'Server network tunneling allows the clients to tunnel the game connection through the server by using the server\nas a relay. This is enabled by default and set to "Stricter". Tunneling helps to avoid common pitfalls and connection\nissues that are encountered with stricter NATs'}),"\n",(0,s.jsx)(n.h3,{id:"stricter",children:"Stricter"}),"\n",(0,s.jsx)(n.p,{children:'Using the "stricter" option will only tunnel connections when they are of a NAT type stricter than "Open" which is the\nbest default as people playing with "Open" NAT get the best latency from having a direct connection and those who have\na stricter NAT who aren\'t normally able to play are now able to play'}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "tunnel": "stricter"\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"always",children:"Always"}),"\n",(0,s.jsxs)(n.p,{children:["This option ",(0,s.jsx)(n.em,{children:"always"}),' tunnels connections through the server. This can be good if you\'re looking to increase user privacy\nsince it will hide the IP address of hosts from other players (They are normally exposed on the official servers), at the\ncost of additional latency that "Open" NAT players might not normally get']}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "tunnel": "always"\n}\n'})}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsx)(n.p,{children:"When using this option you can choose to disable the QoS server entirely as it is not used when\ntunneling is forced"})}),"\n",(0,s.jsx)(n.h3,{id:"disabled-1",children:"Disabled"}),"\n",(0,s.jsx)(n.p,{children:"This option disabled tunneling, using this option may prevent those with stricter NATs from hosting games entirely"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "tunnel": "disabled"\n}\n'})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h2,{id:"udp-tunnel",children:"UDP Tunnel"}),"\n",(0,s.jsxs)(n.blockquote,{children:["\n",(0,s.jsx)(n.p,{children:'This is a new tunnel implementation for server versions >=0.7.0-beta which will perform better than the previous tunnel in multiple scenarios. It will respect the "Tunnel" option above but has some additional configuration below'}),"\n"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "udp_tunnel": {\n    "port": 9032,\n    "external_port": 9032\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"udp-tunnel-port",children:"UDP Tunnel Port"}),"\n",(0,s.jsx)(n.p,{children:"The UDP tunnel server requires an additional bound port, this option specifies which port on the system should be used for this server. Ensure you do not have any other services on this port"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "udp_tunnel": {\n    "port": 9032,\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"udp-tunnel-external-port",children:"UDP Tunnel Exter
1nal Port"}),"\n",(0,s.jsxs)(n.p,{children:["If you are running your server behind a reverse proxy you will likely be exposing different ports to the internet or in a situation where the port users have access to is different to the bound port, in order for the UDP tunnel to work properly you will also need to specify the ",(0,s.jsx)(n.code,{children:"external_port"})," this is the\nport that people on the other side of the reverse proxy/port binding will see."]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "udp_tunnel": {\n    "external_port": 9032,\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"udp-tunnel-enabled",children:"UDP Tunnel Enabled"}),"\n",(0,s.jsx)(n.p,{children:"You can disable the UDP tunnel completely by setting this option to false"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "udp_tunnel": {\n    "enabled": true,\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h2,{id:"api",children:"API"}),"\n",(0,s.jsx)(n.p,{children:"The API section handles various API related configurations"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "api": {\n      "public_games": false,\n      "public_games_hide_players": true\n  }\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"public-games-api",children:"Public games API"}),"\n",(0,s.jsxs)(n.p,{children:["Normally, the games API at ",(0,s.jsx)(n.code,{children:"/api/games"})," requires an authentication token to get the list of games. With this\nyou can disable that requirement and allow the games list to be requested without requiring authentication."]}),"\n",(0,s.jsxs)(n.p,{children:["By default players are hidden from the games response when not authenticated but you can get the total players in the\ngame using the ",(0,s.jsx)(n.code,{children:"total_players"})," field in the response for each game."]}),"\n",(0,s.jsxs)(n.p,{children:["To include players in authenticated responses see ",(0,s.jsx)(n.a,{href:"#hide-players-from-public-games",children:"Hide players from public games"})]}),"\n",(0,s.jsx)(n.p,{children:"This option is likely useful if you want to create a discord bot or some other display that doesn't want to deal with auth"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "public_games": false\n}\n'})}),"\n",(0,s.jsx)(n.h3,{id:"hide-players-from-public-games",children:"Hide players from public games"}),"\n",(0,s.jsxs)(n.p,{children:["This option is enabled by default, it controls whether the player list should be hidden from unauthenticated requests to the games API. When ",(0,s.jsx)(n.code,{children:"true"})," the list of players provided by the games API will be ",(0,s.jsx)(n.code,{children:"null"}),"."]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-json",children:'{\n  "public_games_hide_players": true\n}\n'})}),"\n",(0,s.jsxs)(n.admonition,{type:"warning",children:[(0,s.jsxs)(n.p,{children:["This is done for privacy purposes. Accounts created using the in-game account creation screen prior to ",(0,s.jsx)(n.code,{children:"v0.6.1"})," of Pocket Relay would use\ntheir email address as the player name so any accounts that have not changed their username for these sorts of accounts will expose their\nemail in this response (Origin accounts and those created/changed through the dashboard are not affected)"]}),(0,s.jsxs)(n.p,{children:["If your database doesn't contain any of these types of accounts or if it was created with ",(0,s.jsx)(n.code,{children:"v0.6.1"})," or greater (Random name generation was added in ",(0,s.jsx)(n.code,{children:"v0.6.1"})," for in-game account creation) and you don't mind people seeing the names of who's in a game then you can set this to ",(0,s.jsx)(n.code,{children:"false"})," to include the players list"]})]})]})}function c(e={}){const{wrapper:n}={...(0,r.a)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(d,{...e})}):d(e)}},1544:(e,n,i)=>{i.d(n,{Z:()=>s});const s=i.p+"assets/images/config-hamachi-faf75bcff76e8e27b9df5ba08d3212f2.png"},1151:(e,n,i)=>{i.d(n,{Z:()=>a,a:()=>o});var s=i(7294);const r={},t=s.createContext(r);function o(e){const n=s.useContext(t);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function a(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:o(e.components),s.createElement(t.Provider,{value:n},e.children)}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.