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

Web hosting #116

Open
Zainmansour opened this issue Sep 24, 2022 · 5 comments
Open

Web hosting #116

Zainmansour opened this issue Sep 24, 2022 · 5 comments
Labels

Comments

@Zainmansour
Copy link

what I have to do to use this library in my website if I want to deploy it to a webhost like vercel

@derhuerst
Copy link
Collaborator

What do you mean exactly? Run ffmpeg on the server to convert media?

@Zainmansour
Copy link
Author

yes how can I initialize my server to use ffmpeg?

@derhuerst
Copy link
Collaborator

ffmpeg-static just makes sure that you have an ffmpeg binary suitable for your platform & architecture installed. The path to this ffmpeg binary can be obtained by require('ffmpeg-static').

You can then execute ffmpeg however you please:

Does that answer your question?

@Zainmansour
Copy link
Author

Zainmansour commented Oct 1, 2022

I am not sure that you understood my question
focus with my please:
to install ffmpeg on my machine I downloaded it manually and add the path of /bin folder to environment variables in win 10
I create a website and I use ffmpeg it works fine on my machine so if I wanna deploy my website to a web hosting server like ( heroku or vercel ) how I can initialize the environment to use ffmpeg because I can't install it manually??
hope you understand and sorry for my poor english

@derhuerst
Copy link
Collaborator

to install ffmpeg on my machine I downloaded it manually

This a valid way to install ffmpeg!

This package (ffmpeg-static) is intended for automatic usage: If you want your Node.js-based project to use ffmpeg, you can use ffmpeg-static as a dependency to obtain an ffmpeg binary, instead of manually downloading one.

This only works in an environment where you can spawn child processes, not sure if this works on Vercel; But I know it works on a plain old Linux-based VM/VPS used for web hosting.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants