From 71db00dd69eace9c34fbc56449ba03d4bce6c2b3 Mon Sep 17 00:00:00 2001 From: Ted Hess Date: Sun, 15 Nov 2015 13:28:55 -0500 Subject: [PATCH] icecast: Improve OOB experience - new defaults, add user & group ids Signed-off-by: Ted Hess --- multimedia/icecast/Makefile | 3 ++- multimedia/icecast/files/icecast.init | 15 ++++++++--- .../020-icecast_config_for_openwrt.patch | 25 +++++++++++++++++++ 3 files changed, 39 insertions(+), 4 deletions(-) create mode 100644 multimedia/icecast/patches/020-icecast_config_for_openwrt.patch diff --git a/multimedia/icecast/Makefile b/multimedia/icecast/Makefile index 1b0766e7e..fa0f7d24d 100644 --- a/multimedia/icecast/Makefile +++ b/multimedia/icecast/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=icecast PKG_VERSION:=2.4.2 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_LICENSE:=GPL-2.0 PKG_MAINTAINER:=André Gaul @@ -29,6 +29,7 @@ define Package/icecast CATEGORY:=Multimedia DEPENDS:=+libcurl +libxml2 +libxslt +libogg +libopenssl TITLE:=A streaming media server for Ogg/Vorbis and MP3 audio streams + USERID:=icecast=87:icecast=87 URL:=http://www.icecast.org/ endef diff --git a/multimedia/icecast/files/icecast.init b/multimedia/icecast/files/icecast.init index 355e4b716..96b36e188 100755 --- a/multimedia/icecast/files/icecast.init +++ b/multimedia/icecast/files/icecast.init @@ -1,12 +1,21 @@ #!/bin/sh /etc/rc.common -# Example script -# Copyright (C) 2014 OpenWrt.org + +# Startup script +# Copyright (C) 2015 OpenWrt.org USE_PROCD=1 -START=99 +START=90 STOP=15 start_service() { + user_exists icecast 87 || user_add icecast 87 + group_exists icecast 87 || group_add icecast 87 + + [ -d /var/log/icecast ] || { + mkdir -m 0755 -p /var/log/icecast + chown icecast:icecast /var/log/icecast + } + procd_open_instance procd_set_param command /usr/bin/icecast -c /etc/icecast.xml procd_set_param respawn diff --git a/multimedia/icecast/patches/020-icecast_config_for_openwrt.patch b/multimedia/icecast/patches/020-icecast_config_for_openwrt.patch new file mode 100644 index 000000000..d3282f2ed --- /dev/null +++ b/multimedia/icecast/patches/020-icecast_config_for_openwrt.patch @@ -0,0 +1,25 @@ +--- a/conf/icecast.xml.in ++++ b/conf/icecast.xml.in +@@ -61,7 +61,7 @@ + It affects mainly the urls generated by Icecast for playlists and yp + listings. You MUST configure it properly for YP listings to work! + --> +- localhost ++ OpenWrt + + + +@@ -234,11 +234,9 @@ + + + 0 +- + +