Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DietPi-Software | Moonlight: Game streaming client for Sunshine and NVIDIA GameStream #6303

Merged
merged 24 commits into from
Apr 29, 2023
Merged
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions dietpi/dietpi-software
Original file line number Diff line number Diff line change
Expand Up @@ -966,6 +966,12 @@ Available commands:
aSOFTWARE_AVAIL_G_HW_ARCH[$software_id,1]=0
aSOFTWARE_AVAIL_G_HW_ARCH[$software_id,2]=0
aSOFTWARE_AVAIL_G_HW_ARCH[$software_id,10]=0
#------------------
software_id=206
aSOFTWARE_NAME[$software_id]='Moonlight'
aSOFTWARE_DESC[$software_id]='Game streaming client for Sunshine and NVIDIA GameStream'
aSOFTWARE_CATX[$software_id]=5
aSOFTWARE_DOCS[$software_id]='https://github.com/moonlight-stream/moonlight-embedded/wiki'
mtekman marked this conversation as resolved.
Show resolved Hide resolved

MichaIng marked this conversation as resolved.
Show resolved Hide resolved
# Social & Search
#--------------------------------------------------------------------------------
Expand Down Expand Up @@ -11103,6 +11109,34 @@ _EOF_
modprobe binfmt_misc 2> /dev/null && G_EXEC systemctl restart systemd-binfmt
fi

if To_Install 206 # Moonlight
then
## Install script adapted from
## - https://dl.cloudsmith.io/public/moonlight-game-streaming/moonlight-embedded/setup.deb.sh

# APT deps
aDEPS=('apt-transport-https' 'ca-certificates' 'debian-keyring' 'debian-archive-keyring' 'gnupg')

mtekman marked this conversation as resolved.
Show resolved Hide resolved
# Install paths
local gpg_keyring_path="/usr/share/keyrings/moonlight-game-streaming-moonlight-embedded-archive-keyring.gpg"
local repo_path="/etc/apt/sources.list.d/moonlight-game-streaming-moonlight-embedded.list"

# APT key
local base_url="https://dl.cloudsmith.io/public/moonlight-game-streaming/moonlight-embedded"
local gpg_url="$base_url/gpg.5AEE46706CF0453E.key"
G_CHECK_URL "$gpg_url"
G_EXEC eval "curl -1sLf '$gpg_url' | gpg --dearmor > '$gpg_keyring_path'"

# APT list
local repo_url="$base_url/deb/raspbian"
G_EXEC eval "echo 'deb [signed-by=$gpg_keyring_path] $repo_url $G_DISTRO_NAME main' > $repo_path"
G_EXEC eval "echo 'deb-src [signed-by=$gpg_keyring_path] $repo_url $G_DISTRO_NAME main' >> $repo_path"
mtekman marked this conversation as resolved.
Show resolved Hide resolved
G_AGUP

# Install the client
G_AGI moonlight-embedded
fi

if To_Install 27 # TasmoAdmin
then
# Install required PHP modules
Expand Down Expand Up @@ -12689,6 +12723,15 @@ If no WireGuard (auto)start is included, but you require it, please do the follo
[[ -d '/usr/lib/x86_64-linux-gnu' ]] && G_EXEC rmdir --ignore-fail-on-non-empty /usr/lib/x86_64-linux-gnu
fi

if To_Uninstall 206 # Moonlight
then
G_AGP moonlight-embedded
local gpg_keyring_path="/usr/share/keyrings/moonlight-game-streaming-moonlight-embedded-archive-keyring.gpg"
local repo_path="/etc/apt/sources.list.d/moonlight-game-streaming-moonlight-embedded.list"
[[ -f "$gpg_keyring_path" ]] && G_EXEC rm "$gpg_keyring_path"
[[ -f "$repo_path" ]] && G_EXEC rm "$repo_path"
mtekman marked this conversation as resolved.
Show resolved Hide resolved
fi

if To_Uninstall 119 # CAVA
then
G_AGP cava
Expand Down