Skip to content

fixes #15 Teamspeak 6 unable to install - #16

Open
Multigestern wants to merge 1 commit into
pelican-eggs:mainfrom
Multigestern:fix/ts6-server
Open

fixes #15 Teamspeak 6 unable to install#16
Multigestern wants to merge 1 commit into
pelican-eggs:mainfrom
Multigestern:fix/ts6-server

Conversation

@Multigestern

Copy link
Copy Markdown

Teamspeak server beta 6.0.0-beta9 and 6.0.0-beta10 are working.

Due to the bad release naming scheme of the ts6 server the pull cannot be completed correctly. I fixed the Startup script.

The added script as oneliner:


set -euo pipefail

REPO="teamspeak/teamspeak6-server"
TARGET_DIR="/mnt/server"

gh_api() {
    curl -sL "$1"
}

if [ -z "${TS_VERSION:-}" ] || [ "${TS_VERSION}" = "latest" ]; then
    echo "► Fetching latest Teamspeak 6 release info from GitHub…"
    RELEASE_JSON="$(gh_api "https://api.github.com/repos/${REPO}/releases/latest")"
else
    echo "► Fetching release info for tag v${TS_VERSION}…"
    RELEASE_JSON="$(gh_api "https://api.github.com/repos/${REPO}/releases/tags/v${TS_VERSION}")"
fi

ASSET_URL="$(echo "$RELEASE_JSON" \
    | jq -r '.assets[]
        | select(.name | test("linux-amd64\\.tar\\.xz$"))
        | .browser_download_url')"

if [ -z "$ASSET_URL" ] || [ "$ASSET_URL" = "null" ]; then
    echo "✗ No linux-amd64 tarball found in this release."
    exit 1
fi

echo "► Downloading and extracting: $ASSET_URL"

echo "► Cleaning target directory…"
rm -f "$TARGET_DIR/tsserver"

cd "$TARGET_DIR"
gh_api "$ASSET_URL" | tar -xvJ

Description

Checklist for all submissions

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you tested and reviewed your changes with confidence that everything works?
  • Did you branch your changes and PR from that branch and not from your master branch?
    • If not, why?:
  • You verify that the start command applied does not use a shell script
    • [x ] If some script is needed then it is part of a current yolk or a PR to add one
  • The egg was exported from the panel

New egg Submissions

  1. Does your submission pass tests (server is connectable)?
  2. Does your egg use a custom docker image?
    • Have you tried to use a generic image?
    • Did you PR the necessary changes to make it work?
  3. Have you added the egg to the main README.md and any other README files in subdirectories of the egg (e.g /game_eggs) according to the alphabetical order?
  4. Have you added a unique README.md for the egg you are adding according to the alphabetical order?
  5. You verify that the start command applied does not use a shell script
    • If some script is needed then it is part of a current yolk or a PR to add one
  6. The egg was exported from the panel

Teamspeak server beta 6.0.0-beta9 and 6.0.0-beta10 are working.

Due to the bad release naming scheme of the ts6 server the pull cannot be completed correctly.
I fixed the Startup script.

The added script as oneliner:
```

set -euo pipefail

REPO="teamspeak/teamspeak6-server"
TARGET_DIR="/mnt/server"

gh_api() {
    curl -sL "$1"
}

if [ -z "${TS_VERSION:-}" ] || [ "${TS_VERSION}" = "latest" ]; then
    echo "► Fetching latest Teamspeak 6 release info from GitHub…"
    RELEASE_JSON="$(gh_api "https://api.github.com/repos/${REPO}/releases/latest")"
else
    echo "► Fetching release info for tag v${TS_VERSION}…"
    RELEASE_JSON="$(gh_api "https://api.github.com/repos/${REPO}/releases/tags/v${TS_VERSION}")"
fi

ASSET_URL="$(echo "$RELEASE_JSON" \
    | jq -r '.assets[]
        | select(.name | test("linux-amd64\\.tar\\.xz$"))
        | .browser_download_url')"

if [ -z "$ASSET_URL" ] || [ "$ASSET_URL" = "null" ]; then
    echo "✗ No linux-amd64 tarball found in this release."
    exit 1
fi

echo "► Downloading and extracting: $ASSET_URL"

echo "► Cleaning target directory…"
rm -f "$TARGET_DIR/tsserver"

cd "$TARGET_DIR"
gh_api "$ASSET_URL" | tar -xvJ
```

@redthirten redthirten left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

You said the egg was exported from the panel, but it was not.

Also, we are in the progress of upgrading all the Eggs to the new YAML format, so if you could export the Egg in this format, that would be great.

Finally, if you don't mind, please use Scramble to provide an updated Pterodactyl Egg as well.

Thank you for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants