Installing Apache, MySQL, PHP in Gentoo Server

All commands are performed as root to install Apache, MySQL, PHP and phpMyAdmin in Gentoo Linux Server. 1. Update your System # emerge –sync 2. Install Apache Webserver # emerge apache The web server ROOT is in /var/www/localhost/htdocs/ # /etc/init.d/apache2 start Then go to http://server-ip/ Add apache2 to the startup script # rc-update -v add … Read more

HTML5 MP3 Player with Folder Feedburner Playlist

WordPress and Standalone HTML5 MP3 Music Player with Playlist for MP3 Folder / Feedburner XML compatible with iOS, Android and supports all browsers Firefox, Chrome, Safari, IE and Opera! Read MP3 Folder URL This plugin can read MP3 folder like http://www.domain.com/mp3/ and automatically create dynamic horizontal & vertical playlist MP3 Folder with song’s index list … Read more

Wowza Live Cam Secure Expired Token

wowza-live-cam-secure-expired-token.php // Encrypt original stream URL http://wowza-server:port/stream/playlist.m3u8 $base64ized = encryptDecrypt($secret_key, $streamURL, 0); // Decrypt stream URL $streamURL = encryptDecrypt($secret_key, $base64ized, 1); stream.php // Expire stream URL after time interval & check secure token if (($current – $timestamp)

Creating Zip Without Recording ROOT Paths

Simply use chdir() to change the working directory before you exec() Or you can use …. exec(“cd /var/www/html/media; zip -r -9 Media.zip . 2>&1”, $log); exec(“mv /var/www/html/media/Media.zip /var/www/html/Media.zip”); Get zip file size exec(“ls -ls /var/www/html/Media.zip | awk ‘{print $6}’ 2>&1”, $size); $zipsize = implode(” “, $size); Without this solution Length Date Time Name ——– —- … Read more

Install Airtime – open source radio automation software

Airtime is open source radio automation software (GPL v3) for GNU/Linux platforms. It’s recommend installing on Ubuntu Linux 12.04 LTS or Debian Squeeze on a computer with at least a 1 GHz processor and 512 MB of RAM for a Server Edition OS or 1GB of RAM for a Desktop Edition OS. Download airtime-easy-setup $ … Read more

Best PHP Encryption Decryption

I was working on Secured & Expired MP3 Link in HTML5 MP3 Player. Hope you already read previous article “Amazon S3 Expiring Link” You can use below code for hiding real mp3 link inside html source using base64_encode, mcrypt_encrypt, base64_decode, mcrypt_decrypt and md5. This function is also useful when you need to secure & expire … Read more

Amazon S3 Expiring Link

I was working on Amazon S3 Cloud HTML5 MP3 Player for S3 Bucket security and Expiring Media links. <?php   if(!function_exists(‘el_crypto_hmacSHA1’)){       /**       * Calculate the HMAC SHA1 hash of a string.       *       * @param string $key The key to hash against       * @param string $data The data to hash       * @param int $blocksize Optional blocksize       * … Read more

Backup Disk Snapshot on Google Compute Engine

Snapshots are stored in Google Cloud Storage, which is secure, incredibly large, and remarkably inexpensive. You might want to think about whether the labor involved in saving snapshots on your local PC, with all the attendant risks of data loss. For pricing, see https://cloud.google.com/pricing/cloud-storage. For example, if you have a 10 GB snapshot, that’s going … Read more

Install Admin Panel in Red5

Hope you already read our previous articles for installing Red5 on different cloud based servers… You can access Red5 Admin Panel after successful install of Red5 Server using http://your-ip-address:5080/demos/adminPanel.html Check if you have access to http://your-ip-address:5080/admin/ ?? You must double check admin application is installed in Red5 Home (i.e. /usr/share/red5/webapps) or not? If you could … Read more

PHP Run Background Process using Exec

If you need to start process in background and get its PID to manage it later using PHP. <?php function runInBackground($command,$log,$priority=0) { if($priority)    $PID=shell_exec(“nohup nice -n $priority $command > $log 2>&1 & echo $!”); else    $PID=shell_exec(“nohup $command > $log 2>&1 & echo $!”); return($PID); } ?> echo $! will return process ID # Command & … Read more