Skip to content

Conversation

@mcottontensor
Copy link
Collaborator

@mcottontensor mcottontensor commented May 29, 2025

Relevant components:

  • Signalling server
  • Common library
  • Frontend library
  • Frontend UI library
  • Matchmaker
  • Platform scripts
  • SFU

Problem statement:

The current platform scripts don't allow you to pass --peer_options (and possibly some other parameters) to Wilbur because the argument is constructed in the platform scripts themselves and replaces any user passed peer_options.

Solution

The platform scripts now check if any parameter it would normally pass to Wilbur already were passed by the user. If so it skips adding that parameter to the call to Wilbur.

Another change that comes with this is the implementation of an explicit delimeter between script arguments and Wilbur arguments that will be passed directly. Now anything before the -- marker is treated as a script parameter, and if an unknown parameter is found an error is produced (previously unknown parameters would be passed to Wilbur). And anything after the marker is passed directly to Wilbur. This means after this update, users will need to properly separate script parameters and Wilbur parameters with --.

One final change with this PR is that there is a new --peer_options_file parameter for Wilbur. JSON is notoriously bad to pass as a command line argument value due to formatting, escaping, spaces etc. It does not parse well on the command line. To aleviate this, I have added the new --peer_options_file parameter that allows users to provide a JSON file for the peer options. This file is read, parsed and passed in as the peer options for the signalling server..

Fixes #650

Documentation

peer_options was always being built and passed to wilbur with the
platform_scripts. This meant that if you wished to pass your own
peer_options you could not use the platform_scripts.
This fixes that by checking that peer_options has not already been
supplied as a parameter.
Additionally, there is also now a clear delimeter between script
arguments and command arguments.
@changeset-bot
Copy link

changeset-bot bot commented May 29, 2025

🦋 Changeset detected

Latest commit: 39c1013

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@epicgames-ps/wilbur Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Similar to the linux changes this change should allow --peer_options and
--http_root to be passed to the server without being stomped on by the
script.
This is to make it easier to provide JSON data to the peer_options
parameter without having to escape JSON data on the command line.
@mcottontensor mcottontensor changed the title fix(wilbur): Fixing issues with passing arguments to wilbur. (Linux) Fixing argument issues with Wilbur and platform scripts May 30, 2025
@mcottontensor mcottontensor marked this pull request as ready for review May 30, 2025 02:59
Copy link
Contributor

@lukehb lukehb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Slight change to improve error thrown

Co-authored-by: Luke Bermingham <1215582+lukehb@users.noreply.github.com>
@mcottontensor mcottontensor added auto-backport Used to specify we want a PR to auto backport to a branch, must be paired with auto-backport-to-UEX. auto-backport-to-UE5.6 labels May 30, 2025
@mcottontensor mcottontensor merged commit 584617b into EpicGamesExt:master May 30, 2025
10 checks passed
@mcottontensor mcottontensor deleted the wilbur_args_fix branch May 30, 2025 04:29
github-actions bot pushed a commit that referenced this pull request May 30, 2025
* fix(wilbur): Fixing issues with passing arguments to wilbur. (Linux)

peer_options was always being built and passed to wilbur with the
platform_scripts. This meant that if you wished to pass your own
peer_options you could not use the platform_scripts.
This fixes that by checking that peer_options has not already been
supplied as a parameter.
Additionally, there is also now a clear delimeter between script
arguments and command arguments.

* fix(wilbur): Fixing issues with passing arguments. (Windows)

Similar to the linux changes this change should allow --peer_options and
--http_root to be passed to the server without being stomped on by the
script.

* feat(wilbur): Adding --peer_options_file to wilburs cli arguments.

This is to make it easier to provide JSON data to the peer_options
parameter without having to escape JSON data on the command line.

* chore(actions): Updating actions to match the new platform_script args.

* fix(actions): Fixed missing comma in argument list.

* fix(extras): Updating the docker commands for the new arguments.

* chore(changeset): Adding changeset for wilbur.

* Update file not found error message

Co-authored-by: Luke Bermingham <1215582+lukehb@users.noreply.github.com>

---------

Co-authored-by: Luke Bermingham <1215582+lukehb@users.noreply.github.com>
(cherry picked from commit 584617b)
@github-actions
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
UE5.6

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation and see the Github Action logs for details

mcottontensor added a commit that referenced this pull request May 30, 2025
* fix(wilbur): Fixing issues with passing arguments to wilbur. (Linux)

peer_options was always being built and passed to wilbur with the
platform_scripts. This meant that if you wished to pass your own
peer_options you could not use the platform_scripts.
This fixes that by checking that peer_options has not already been
supplied as a parameter.
Additionally, there is also now a clear delimeter between script
arguments and command arguments.

* fix(wilbur): Fixing issues with passing arguments. (Windows)

Similar to the linux changes this change should allow --peer_options and
--http_root to be passed to the server without being stomped on by the
script.

* feat(wilbur): Adding --peer_options_file to wilburs cli arguments.

This is to make it easier to provide JSON data to the peer_options
parameter without having to escape JSON data on the command line.

* chore(actions): Updating actions to match the new platform_script args.

* fix(actions): Fixed missing comma in argument list.

* fix(extras): Updating the docker commands for the new arguments.

* chore(changeset): Adding changeset for wilbur.

* Update file not found error message



---------


(cherry picked from commit 584617b)

Co-authored-by: mcottontensor <80377552+mcottontensor@users.noreply.github.com>
Co-authored-by: Luke Bermingham <1215582+lukehb@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-backport Used to specify we want a PR to auto backport to a branch, must be paired with auto-backport-to-UEX. auto-backport-to-UE5.6

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] - Signalling Server Image start.sh doesn't allow to provide your own peer connection options

2 participants