@tip{You could also utilize the `~/.bash_profile` or `~/.bashrc` files to set up the `DISPLAY` variable.}
@seealso{ See [Remote SSH Headless Setup](md_docs_2guides.html#remote-ssh-headless-setup)
on how to set up a headless streaming server without autologin and dummy plugs (X11 + NVidia GPUs)}
### Configuration
Sunshine is configured via the web ui, which is available on [https://localhost:47990](https://localhost:47990)
by default. You may replace *localhost* with your internal ip address.
@attention{Ignore any warning given by your browser about "insecure website". This is due to the SSL certificate
being self-signed.}
@caution{If running for the first time, make sure to note the username and password that you created.}
1. Add games and applications.
2. Adjust any configuration settings as needed.
3. In Moonlight, you may need to add the PC manually.
4. When Moonlight requests for you insert the pin:
- Login to the web ui
- Go to "PIN" in the Navbar
- Type in your PIN and press Enter, you should get a Success Message
- In Moonlight, select one of the Applications listed
### Arguments
To get a list of available arguments, run the following command.
@tabs{
@tab{ General | @code{.bash}
sunshine --help
@endcode }
@tab{ AppImage | @code{.bash}
./sunshine.AppImage --help
@endcode }
@tab{ Flatpak | @code{.bash}
flatpak run --command=sunshine dev.lizardbyte.app.Sunshine --help
@endcode }
}
### Shortcuts
All shortcuts start with `Ctrl+Alt+Shift`, just like Moonlight.
*`Ctrl+Alt+Shift+N`: Hide/Unhide the cursor (This may be useful for Remote Desktop Mode for Moonlight)
*`Ctrl+Alt+Shift+F1/F12`: Switch to different monitor for Streaming
### Application List
* Applications should be configured via the web UI
* A basic understanding of working directories and commands is required
* You can use Environment variables in place of values
*`$(HOME)` will be replaced by the value of `$HOME`
*`$$` will be replaced by `$`, e.g. `$$(HOME)` will be become `$(HOME)`
*`env` - Adds or overwrites Environment variables for the commands/applications run by Sunshine.
This can only be changed by modifying the `apps.json` file directly.
### Considerations
* On Windows, Sunshine uses the Desktop Duplication API which only supports capturing from the GPU used for display.
If you want to capture and encode on the eGPU, connect a display or HDMI dummy display dongle to it and run the games
on that display.
* When an application is started, if there is an application already running, it will be terminated.
* If any of the prep-commands fail, starting the application is aborted.
* When the application has been shutdown, the stream shuts down as well.
* For example, if you attempt to run `steam` as a `cmd` instead of `detached` the stream will immediately fail.
This is due to the method in which the steam process is executed. Other applications may behave similarly.
* This does not apply to `detached` applications.
* The "Desktop" app works the same as any other application except it has no commands. It does not start an application,
instead it simply starts a stream. If you removed it and would like to get it back, just add a new application with
the name "Desktop" and "desktop.png" as the image path.
* For the Linux flatpak you must prepend commands with `flatpak-spawn --host`.
### HDR Support
Streaming HDR content is officially supported on Windows hosts and experimentally supported for Linux hosts.
* General HDR support information and requirements:
* HDR must be activated in the host OS, which may require an HDR-capable display or EDID emulator dongle
connected to your host PC.
* You must also enable the HDR option in your Moonlight client settings, otherwise the stream will be SDR
(and probably overexposed if your host is HDR).
* A good HDR experience relies on proper HDR display calibration both in the OS and in game. HDR calibration can
differ significantly between client and host displays.
* You may also need to tune the brightness slider or HDR calibration options in game to the different HDR brightness
capabilities of your client's display.
* Some GPUs video encoders can produce lower image quality or encoding performance when streaming in HDR compared
to SDR.
* Additional information:
@tabs{
@tab{ Windows |
- HDR streaming is supported for Intel, AMD, and NVIDIA GPUs that support encoding HEVC Main 10 or AV1 10-bit profiles.
- We recommend calibrating the display by streaming the Windows HDR Calibration app to your client device and saving an HDR calibration profile to use while streaming.
- Older games that use NVIDIA-specific NVAPI HDR rather than native Windows HDR support may not display properly in HDR.
}
@tab{ Linux |
- HDR streaming is supported for Intel and AMD GPUs that support encoding HEVC Main 10 or AV1 10-bit profiles using VAAPI.
- The KMS capture backend is required for HDR capture. Other capture methods, like NvFBC or X11, do not support HDR.
- You will need a desktop environment with a compositor that supports HDR rendering, such as Gamescope or KDE Plasma 6.
@seealso{[Arch wiki on HDR Support for Linux](https://wiki.archlinux.org/title/HDR_monitor_support) and
[Reddit Guide for HDR Support for AMD GPUs](https://www.reddit.com/r/linux_gaming/comments/10m2gyx/guide_alpha_test_hdr_on_linux)}
}
}
### Tutorials and Guides
Tutorial videos are available [here](https://www.youtube.com/playlist?list=PLMYr5_xSeuXAbhxYHz86hA1eCDugoxXY0).
Guides are available [here](guides.md).
@admonition{Community! |
Tutorials and Guides are community generated. Want to contribute? Reach out to us on our discord server.}