Running Airtime in a special environment.
  • Hello! I administrate a student radio station that has been running for some time on a custom Arch Linux setup (I put together the stack which includes Arch Linux > a ch-rooted Nginx backed php website, a Liquidsoap transcoder, Icecast, and a piece of autodj software called RadioBot that the station bought before I joined.

    Recently the station has expressed interest in using Airtime and I want to get an instance setup so they can test it out and see if it might work better for their purposes.

    Sadly, while opensource, Airtime has tied itself to Apache and Debian. I can't fairly judge the design decision myself as I'm not privy to the considerations or assumption made at the time but it does make my task harder than I anticipated.

    There is nothing that should preclude the possibility of running airtime under Archlinux and Nginx directly, but all of the install scripts and instructions are using debian and Apache specific commands and configuration I am having a hard time understanding.

    I was hoping that there might be a developer or user about who could fill me in on the software and environment/configuration requirements run airtime.
    I'm specifically looking for airtime configuration points so I can get the airtime server running while having it's web front end inside the ch-rooted nginx server. and for software packages I may have to find and compile myself. Silan for example does not have an Archlinux package even in the aur and I suspect some of the ocamla libs may be the same considering the trouble I had to go through to build liquidsoap.
  • 11 Comments sorted by
  • Hello! You're probably better off holding all of your horses for the next major release. The codebase is currently undergoing massive changes behind the scenes. So there's that.

    In the meantime, hold your nose and use Debian 7 on a respectable VPS somewhere. Follow this guide!
  • @Ben Powers
    I am a developer too and I use arch,in fact most people in my Linux group who use debian or its variants are user of Arch.
    In fact if you have learnt arch then especially ubuntu is trivial (like cake walk).
    I still go to Gentoo and Arch for things like sounds cards and testing python.

    You are right in arch most things you need to compile,not so for ubuntu and its variant. but if you want to compile a few things then you might just go with debian.

    there is an Automated script ,just remember to use  apt instead of aptitude.

    Here is the Manual
    https://www.sourcefabric.org/en/home/manuals/

    look for the server section

    and there use to be a demo server you could familiarized yourself with the UI
    I find it I put it here

    https://airtime-demo.sourcefabric.org/login
    Post edited by Voisses Tech at 2016-02-18 14:30:38
    Anyone reading this a find it funny about my grammar , I make no apology ,Go get a translator.
    "The Problem with education today is that it takes a university degree to switch on a light bulb"
    "You learn from your mistakes but wise people learn from others mistakes avoid Making mistakes there is not sufficient rooms to make them"
    "Innuendo","If's","Assumptions" and "Fear" are for politician.Who,What,where,When and How are for those seeking knowledge and care about Humanity.
    "I might be in Mud but that does not Make me a Wild Hog(pig)"
    “Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius — and a lot of courage to move in the opposite direction.”
    "The only thing that remains constant is change itself"
    May the force be with you,until our path or destiny bring us in tandem.
  • Nginx is not officially supported but it works very good on raw nginx.If you chroot it do not knwo the consequence
    Anyone reading this a find it funny about my grammar , I make no apology ,Go get a translator.
    "The Problem with education today is that it takes a university degree to switch on a light bulb"
    "You learn from your mistakes but wise people learn from others mistakes avoid Making mistakes there is not sufficient rooms to make them"
    "Innuendo","If's","Assumptions" and "Fear" are for politician.Who,What,where,When and How are for those seeking knowledge and care about Humanity.
    "I might be in Mud but that does not Make me a Wild Hog(pig)"
    “Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius — and a lot of courage to move in the opposite direction.”
    "The only thing that remains constant is change itself"
    May the force be with you,until our path or destiny bring us in tandem.
  • @Roger Wilco "You're probably better off holding all of your horses for the next major release. The codebase is currently undergoing massive changes behind the scenes."

    So is there a major upgrade comming?
  • @Roger Wilco

    I assume your talking about the 2.6.x branch?

    I was going through the install script in the 2.5 branch to try and translate them into an arch PKGBUILD the majority of it is really easy stuff to convert just have to find appropriate package names int eh arch repos and aur.

    I was looking at both the 2.5 and 2.6 install scripts and their are structured wildly differently. I'm currently having trouble finding the service file that systemd would use and the configuration files that belong in /etc/airtime

    the only real problem I can for see in getting airtime to run is that Arch has moved to PHP 7. That combined with Airtime's use of the no longer maintained APC opcode and data cache might present problems if used with APCu (with it's backwards compatibility module) and xcache as replacements.


    Post edited by Ben Powers at 2016-02-28 20:28:58
  • @Ben

    2.6 has not been officially released and isn't production ready. For the time being, the Airtime team has thrown all of their effort into the .pro SaaS. I highly suggest you take a look at that asap before wasting any more time fiddling with converting crusty 2-3yr old install scripts over to Arch. You're needlessly inventing work for yourself.


    AutoDJ and Rotations evidently went live on the SaaS today!

  • @Roger

    The station already looked into the SaaS option and determined that it wasn't what we wanted.
    as for converting the install scripts? That appears to be easy I've finale researched enough of airtime's structure to figure it out.

    correct me if I'm wrong but this is the basic setup for airtime:

    clone airtime tag from github repo

    copy airtime_mvc, python_apps and utils to /usr/share/airtime 
    install the python modules in python_apps with their setup.py files, let them create scripts in /usr/bin

    create /var/log/airtime and /var/tmp/airtime with correct permissions
    (is /run/airtime necessary to create? on arch and others /run is a tmpfs )

    create /ect/airtime copy airtime_mvc/build/airtime.example.conf to airtime.conf there

    copy the logrotate files

    set /usr/share/airtime/airtime_mvc/public as a webroot with apache/nginx

    then I just have to write systemd service file for the init.d scripts in the install/sysvinit folder of the pypo and media-monitor python apps and put them in /usr/share/systemd/system

    all relatively simple.

    the only things that I can't find provided in the git repo are the man pages or their generation script, the airtime.xpm graphic, the airtime.destop file, and the airtime-launch-browser script. if needed however I can provide those alongside the PKGBUILD for arch.

    It may be worth considering adding thouse things to the git repo in the docs folder or elseware as appropriate.

    Thanks for trying to help but I think I'll have this about wrapped up. I'll provide a link here to the Arch User Repository when I do get this package working.
    Post edited by Ben Powers at 2016-03-03 22:53:12
  • well, I've completed the work on the Arch Linux PKGBUILD that work is available form here https://aur.archlinux.org/packages/airtime/

    unfortunately while airtime is installed I can't seem to get it setup without encountering problems.

    this happens at step 4/5 in the web based airtime setup.
    airtime user was setup in postgres and airtime connected and created the 'airtime' database.
    rabbitmq connected, 
    general webserver settings get accepted

    but when it comes time to enter the default media folder I get the following error 

    "Failed to insert /srv/airtime/stor/ into cc_music_dirs"

    the same happens if I try to provide a folder.

    an attempt to enter a different folder after getting that error will hang indefently and refreshing the page causes a server error

    from /var/log/airtime/zendphp.log 

    2016-03-10T15:04:54-07:00 INFO (6): [Preference.php : getValue() : line 173] - Could not con
    nect to database: SQLSTATE[42P01]: Undefined table: 7 ERROR:  relation "cc_pref" does not ex
    ist
    LINE 1: SELECT COUNT(*) FROM cc_pref WHERE keystr = $1

    Any ideas as to whats going on?
  • well, I've got it working. turns out the database just wasn't being created. the sql failed to execute and no errors were being fired.

    I've come across several other errors that I've been able to work out. namely the face that configuration files only seem to write correctly about 1/3 of the time and must be manual edited. also services like airtime-playout and airtime-liquidsoap must be restated manually after a configuration change as the subprocess calls meant to do that just don't work n a systemd system.

    I also had to remove references to clock_safe in some of the liquidsoap .liq files in the input.gstreamer calls to get liquis soap to run () the parameter does not exist in liquidsoap 1.1
  • You're going to be squashing bugs forever...
  • That's fine by me. I'll share my fixes and help the project break away from Debian so it can be used anywhere. Which basically means building for python 3 and supporting systemd