commit eaf1eab3ac21081a798a9d24307fbbb4513ceae0 Author: LinuxSquare Date: Tue Nov 5 21:07:04 2024 +0100 Initial Commit diff --git a/APKBUILD b/APKBUILD new file mode 100644 index 0000000..8d3bb9b --- /dev/null +++ b/APKBUILD @@ -0,0 +1,32 @@ +# Maintainer: LinuxSquare +pkgname=pterodactyl-wings +pkgver=1.11.11 +pkgrel=0 +pkgdesc="The server control plane for Pterodactyl Panel" +arch="x86_64" +url="https://pterodactyl.io/" +license="MIT" +optdepends="podman docker" # Install either podman or docker +makedepends="go" +install="$pkgname.post-install" +source="$pkgname-$pkgver.tar.gz::https://github.com/pterodactyl/wings/archive/refs/tags/v${pkgver}.tar.gz pterodactyl-wings.initd" + +build() { + cd "wings-$pkgver" + export CGO_CPPFLAGS="${CPPFLAGS}" + export CGO_CFLAGS="${CFLAGS}" + export CGO_CXXFLAGS="${CXXFLAGS}" + export CGO_LDFLAGS="${LDFLAGS}" + export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw" + go build -o "build/wings" -v wings.go +} + +package() { + install -d 640 "$pkgdir/etc/pterodactyl" + install -D -m 755 "$srcdir/wings-$pkgver/build/wings" "$pkgdir/usr/bin/wings" + install -D -m 755 "$srcdir/$pkgname.initd" "$pkgdir/etc/init.d/$pkgname" +} +sha512sums=" +03ab1d9c9772cb3f492b2536426467fd2bf9bd34d4a450c9924e4e7896e4b1c795bac86e05beaaf79606166d87aaec96c61ee4d9d9e6c8ac7cda9f91dcbfb110 pterodactyl-wings-1.11.11.tar.gz +af30d49a44fab4e45e6dd0cdd9d334f1a5a4364e0e497dc6014073d94b3797e9d2eb1431192f57020dcbc6c84dba9aa36fb7260579d17e17fcf2c39d2a9d264d pterodactyl-wings.initd +" diff --git a/pterodactyl-wings.initd b/pterodactyl-wings.initd new file mode 100644 index 0000000..a060dbd --- /dev/null +++ b/pterodactyl-wings.initd @@ -0,0 +1,14 @@ +#!/sbin/openrc-run +supervisor="supervise-daemon" + +name=$RC_SVCNAME +description="Pterodactyl Wings Daemon" + +command="/usr/bin/wings" +supervise_daemon_args="-d /etc/pterodactyl" +command_user="root" + +depend() { + after podman + need podman +} diff --git a/pterodactyl-wings.post-install b/pterodactyl-wings.post-install new file mode 100644 index 0000000..516aa94 --- /dev/null +++ b/pterodactyl-wings.post-install @@ -0,0 +1,11 @@ +#!/bin/sh + +cat >&2 <