Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

help for app engine #5406

Closed
funfarooq opened this issue Apr 12, 2015 · 1 comment
Closed

help for app engine #5406

funfarooq opened this issue Apr 12, 2015 · 1 comment

Comments

@funfarooq
Copy link

@funfarooq funfarooq commented Apr 12, 2015

currently i have youtube-dl server on my hostgator server with following code

$url = 'http://www.youtube.com/watch?v=rClUpezLmrY';

 $string = 'python youtube-dl -g '.$url;
//echo $string;
$string2 = 'python youtube-dl --help';
exec($string, $result, $status);

// echo json_encode(array('status' => $status, 'url_orginal'=>$url, 'url' => $result, 'command' => $string));
$urlf = json_encode(array( ''=> $result));
$urlf = str_replace('{"":["','',$urlf);
$urlf = str_replace('"]}','',$urlf);
$urlf = str_replace('/','/',$urlf);
echo $urlf;

it use to work fine but my ip address is blocked by youtube and now i wanna move it google app engine and it doesnot support execute command if you help me out with some thing that can be executed on google app engine will be lot help full

@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Apr 12, 2015

You'll have to write it in python and use youtube-dl as a python module. Note that since the python version in the App Engine is missing some standard library modules, you have to patch youtube-dl. If you don't want to start the project yourself, you can look into youtube-dl-api-server.

(By the way: I hope you saniteze $url, otherwise you are vulnerable to attacks)

@jaimeMF jaimeMF closed this Apr 12, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.