lede-packages-rs

git clone git://archive.git.mtrnord.blog/MTRNord/lede-packages-rs.git
Log | Files | Refs | README | LICENSE

icecast.init (467B)


      1 #!/bin/sh /etc/rc.common
      2 
      3 # Startup script
      4 # Copyright (C) 2015 OpenWrt.org
      5  
      6 USE_PROCD=1
      7 START=90
      8 STOP=15
      9 
     10 start_service() {
     11 	user_exists icecast 87 || user_add icecast 87
     12 	group_exists icecast 87 || group_add icecast 87
     13 	
     14 	[ -d /var/log/icecast ] || {
     15 		mkdir -m 0755 -p /var/log/icecast
     16 		chown icecast:icecast /var/log/icecast
     17 	}
     18 
     19 	procd_open_instance
     20 	procd_set_param command /usr/bin/icecast -c /etc/icecast.xml
     21 	procd_set_param respawn
     22 	procd_close_instance
     23 }