Skip to content

Instantly share code, notes, and snippets.

View zoharbabin's full-sized avatar
💭
dreaming, breaking, building

Zohar Babin zoharbabin

💭
dreaming, breaking, building
View GitHub Profile
@zoharbabin
zoharbabin / kc.py
Last active February 4, 2016 18:23
A phenny/jenni IRC Bot module for searching the Kaltura Knowledge Center and presenting the results from the first search results page in the IRC chat. Join us at #kaltura on irc.freenode.net http://www.zoharbabin.com/kaltura-knowledge-center-search-irc-bot-module
#!/usr/bin/env python
"""
kc.py - jenni's Kaltura Knowledge Center Search Module
author Zohar Babin <[email protected]>
http://www.zoharbabin.com/kaltura-knowledge-center-search-irc-bot-module
Copyright Kaltura Inc.
Licensed under AGPL v3.
More info:
Returns the list of search results from the first page in the Kaltura Knowledge Center (http://knowledge.kaltura.com)
@zoharbabin
zoharbabin / job-description-kaltura-dev-advocate.md
Last active December 21, 2015 13:59
Developer Advocate, Engineering Community Manager for Kaltura

We're video geeks, developers of the world's leading most feature-rich and flexible video management platform. Open Source! As a the Developer Advocate, you are the connection to our community, our contributors and our technology partners. You will be the role model Kalturian.

Developer Advocates connect with and educate developers about the Kaltura platform and all its products, they write code sample, produce trainings and guidelines while strategizing with the marketing team and building partner relationships with the business team. You will work with app developers, partners and core contributors.

You will be expected to be a developer who thrives on the cutting edge of technology, loves building web applications and solve new problems. You will also work with and lead our partners who push our technology to its limits and build solutions that amplify the Kaltura platform and create unique video experiences. Your job is to make developers, partners and contributors successful as they implement Kaltura,

@zoharbabin
zoharbabin / player-iframe-close-js-event.html
Created February 5, 2014 21:44
JavaScript Close Event for Player iframe Plugin: http://player.kaltura.com/docs/LimeSurvey (this should be called from within the LimeSurvey's close message window)
<script>
function getUrlParams() {
var params = { };
document.referrer.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(str,key,value) {
params[key] = value;
});
return params;
}
var params = getUrlParams();
@zoharbabin
zoharbabin / remove_mysql_mac_os.md
Created April 18, 2014 12:00
Remove and Cleanup MySQL from Mac OS 10.9+
sudo rm /usr/local/mysql 
sudo rm -rf /usr/local/mysql* 
sudo rm -rf /Library/StartupItems/MySQLCOM 
sudo rm -rf /Library/PreferencePanes/My* 

Edit /etc/hostconfig and remove the line MYSQLCOM=-YES-

rm -rf ~/Library/PreferencePanes/My* 
sudo rm -rf /Library/Receipts/mysql* 
<div style="width: 60%;display: inline-block;position: relative;">
<div id="dummy" style="margin-top: 56.25%;"></div>
<div id="kaltura-player1" style="position:absolute;top:0;left:0;left: 0;right: 0;bottom:0;border:solid thin black;">
</div>
</div>
<script src="http://cdnapi.kaltura.com/p/1038862/sp/103886200/embedIframeJs/uiconf_id/26982371/partner_id/1038862?autoembed=true&amp;entry_id=1_v78epfrp&amp;playerId=kaltura-player1&amp;cache_st=1417643453&amp;width=560&amp;height=395&amp;flashvars[streamerType]=auto"></script>
@zoharbabin
zoharbabin / addTagsToAllKalturaEntries.py
Last active February 2, 2022 15:36
Kaltura API Python Script for adding tags to all entries in the account
# This script loops through all media entries in a given Kaltura account
# and sets tags to all entries (it also checks if a list of tags is not already set on the entry before adding)
# this script requires the Kaltura Python 2.7 client library: http://www.kaltura.com/api_v3/testme/client-libs.php
import sys
import os
sys.path.append(os.path.join(os.path.dirname(__file__), '..'))
from KalturaClient import *
@zoharbabin
zoharbabin / gist:3cdda60f0fae508f523b23cf276b1b8a
Created January 26, 2017 09:20 — forked from tonymtz/gist:d75101d9bdf764c890ef
Uninstall nodejs from OSX Yosemite
# first:
lsbom -f -l -s -pf /var/db/receipts/org.nodejs.pkg.bom | while read f; do sudo rm /usr/local/${f}; done
sudo rm -rf /usr/local/lib/node /usr/local/lib/node_modules /var/db/receipts/org.nodejs.*
# To recap, the best way (I've found) to completely uninstall node + npm is to do the following:
# go to /usr/local/lib and delete any node and node_modules
cd /usr/local/lib
sudo rm -rf node*
@zoharbabin
zoharbabin / concat-mts-files.sh
Created May 7, 2017 05:03 — forked from jbuchbinder/concat-mts-files.sh
Concatenate MTS AVCHD files under Linux
#!/bin/bash
## Solution from: http://stackoverflow.com/questions/26150533/join-avchd-mts-files-on-linux
## ffmpeg -i "concat:00000.MTS|00001.MTS|00002.MTS" -c copy output.m2ts
## File with .m2ts extension, etc
OUT="$1"; shift
## Format : "concat:00000.MTS|00001.MTS|00002.MTS"
IN="concat:$1"; shift
@zoharbabin
zoharbabin / certbotresetcert.sh
Created July 23, 2017 16:11
Delete and reinstall SSL certificates with certbot on Ubuntu
certbot certificates
# find the path to the fullchain certificate you wish to reinstall
certbot revoke --cert-path /etc/letsencrypt/live/... #path to the cert from above
certbot delete --cert-name yourdomain.com
rm -Rf /etc/apache2/sites-available/000-default-le-ssl.conf #or whatever the name of the apache conf you had it configured on
rm -Rf 000-default-le-ssl.conf #or whatever the name of the apache conf you had it configured on
sudo apache2ctl restart
certbot #follow the guide to setup the new certificate
@zoharbabin
zoharbabin / create-subaccounts.php
Created October 31, 2017 15:05
Create Kaltura Sub-Accounts
<?php
if (count($argv)<6){
echo __FILE__ . ' <partner email> <partner passwd> <partner name> <service_url> <parent partner ID> '."\n";
exit (1);
}
require_once('/opt/kaltura/web/content/clientlibs/php5/KalturaClient.php');
$templatePartnerId = null; //enter the id of the account to copy content/settings from as template
$config = new KalturaConfiguration();
$config->serviceUrl = $argv[4];
$client = new KalturaClient($config);