Kaltura CE from git on MacPorts

Handy Commands to restart Apache and MySQL

These would be handy to put into a script to start or stop your development environment if you don’t want to have your web development running at all times.

sudo launchctl load -w /Library/LaunchDaemons/org.macports.mysql5.plist
sudo apachectl restart

sudo launchctl unload /Library/LaunchDaemons/org.macports.mysql5.plist
sudo apachectl stop

Caveats

I’ve got a heavily customized system of apache config files and some /etc/hosts modifications on my system so that my config files for specific virtual hosts are loaded by the following line in my httpd.conf:

Include /Users/papyromancer/src/apache-passengers/*.active

I’d also linked my /Users directory to /home to preserve consistency in my scripts for use in Ubuntu and OS-X. Adjust your shell commands to suit your setup.

Installing Prerequistes

Apache 2, MySQL 5, PHP

Follow these detailed instructions. Pay particular attention to setting up the mysql user and databases and setting up apache to use php.

sudo port install apache2
sudo port install mysql5-server
sudo port install php5 +apache2 +mysql5 +pear

This was the only additional step needed after following that tutorial

sudo port install php5-gd php5-imap php5-curl

NOTE: You MUST use php version 5.2. Kaltura will not work with version 5.3.

At this point I’m not going to install memcached since this isn’t running a production environment.

Setup Kaltura

Get Kaltura

git clone git://github.com/papyromancer/kaltura-ce.git

I’ve had limited success installing Kaltura as the root directory of a web host, and because I’m going to be installing MediaWiki, Drupal, and Wordpress into this same virtual host I’ve decided to link my clone of the Kaltura code (in its own branch) into a separate folder where I will link the other applications as well:

mkdir kaltura-apache
cd kaltura-apache
ln -s ../kaltura-ce kaltura

I’ve also installed the regular old Kaltura CE i

Setup Kaltura virtual host within Apache

<VirtualHost *:80>
  ServerName kaltura.local
  DocumentRoot /home/papyromancer/src/kaltura/kaltura-apache

  <Directory /home/papyromancer/src/kaltura/kaltura-apache>
    Options Indexes FollowSymLinks ExecCGI Includes
    AllowOverride All
    Order Allow,Deny
    Allow from all
  </Directory>
</VirtualHost>

Directories

Run some scripts to create missing directories and correct directory permissions. Run the next two commands in your kaltura-ce directory.

mkdir content/uploads kaltura/alpha/cache indicators conversions archive
install/fixperms.sh

FFMPEG

I have a nice compilation of ffmpeg from macports that I’m sure I’ll integrate into This Kaltura installation at some point, but for right now I’m just going to download the binaries from http://kaltura.org/ unzip and link into the source code checkout from the root directory of my source code checkout. YMMV

ln -s /home/papyromancer/src/kaltura/kalturaCE/kaltura/bin kaltura/bin

Run the Kaltura web based install

  1. Setup a mysql database.
  2. Visit your local virtual host for kaltura

I haven’t worried about email and memcached on my install, but you may want to.

So that didn’t work…

Here’s an additional step I did at some point in the install, but it may not be needed:

sudo ln /opt/local/bin/php /opt/lampp/bin/php
@6 months ago
#git #kaltura #kalturaCE #kaltura-ce #macports #os-x