Page tree
Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Current »

The video upload feature in our product allows administrators to enhance their users' experience by enabling them to upload videos from their local machines.

To provide flexibility and compatibility, we offer two options for video processing: FFMPEG and Mux. This guide will walk you through the step-by-step process of configuring and setting up these video processing options to ensure seamless and efficient video uploads.

Configure video upload with FFMPEG

Install FFMPEG on your server

Some hosting providers support FFMPEG by default. Thus, please check with your hosting provider for the FFMPEG Path

If FFMPEG isn't available, you have to begin by installing FFMPEG on your server or hosting environment. You can download the latest version of FFMPEG from their official website or use package managers specific to your operating system.

If you aren't familiar with FFMPEG setup, please get in touch with your hosting provider or system admin for assistance to install this tool.

Configure FFMPEG Path

Once FFMPEG is installed, ensure that the system recognizes its path. Now, we will configure FFMPEG service on MetaFox site

Let's log into your MetaFox with the Admin user and go to AdminCP Dashboard > App Settings > Videos

Click on the Services menu on the header bar, then click on the FFMPEG item as the screenshot.

Configure 2 settings with the proper paths of FFMPEG and FFPROBE you got in step 1. Note that the FFPROBE will be installed automatically along with FFMPEG.

Then save changes.

You can go to the Settings section by clicking on the Settings top menu. Choose the FFMPEG service for video upload and save changes as below screenshot

You will need to make sure that MetaFox cron has been set up for uploaded videos to process.

Configure video upload with Mux Integration

Create a Mux Account and configure Mux

If you haven't already, sign up for a Mux account at https://mux.com/. Mux provides powerful video processing capabilities, including adaptive streaming and analytics.

After registering Mux account successfully, you will need to set up Mux to get Access Token (Client ID and Client Secret ) and Webhook Secret

Set up Access Token

Once registered, log in to your Mux dashboard.

Navigate to "Settings": In your Mux dashboard, locate and click on the "Settings" option, typically found in the top-right corner of the page.

Choose the Access Tokens menu or within the "Settings" section, select "Access Tokens." Here, you can manage your API tokens.

Click on the "Create New Token" button to generate a new Access Token. Provide a descriptive name for the token, and you can also assign permissions to control API access as below. Then click "Create" to generate the Access Token.

Once the Access Token is generated, copy it immediately and store it securely in a safe location. This Access Token is essential for authenticating requests of your MetaFox site to the Mux API.

Setting Up Mux Webhook

In your Mux dashboard, go to the "Settings" section.

Access Webhooks: Within the "Settings" section, select "Webhooks." This is where you'll set up and manage your Webhooks.

Create a New Webhook: Click on the "Create New Webhook" button to set up a new webhook. You'll need to provide specific details about the webhook.

Configure Webhook Details: Enter the URL where you want to receive the webhook notifications in the "Delivery URL" field. You can also choose the events you want to be notified about, such as video uploads, errors, or completed encoding jobs. Optionally, you can set a secret to ensure data integrity and security.

Save and Verify: After configuring the webhook details, click "Save Webhook." Mux will then send a verification request to the URL you provided. Ensure that your server can receive this verification request and respond with a 200 status code to confirm the webhook.

Test the Webhook: To ensure the webhook is functioning correctly, perform a test by triggering one of the selected events. Verify that your server receives the webhook notification and handles it appropriately.

Configure Mux service on MetaFox

Go to AdminCP Dashboard > App Settings > Video > Services. Then choose Mux Video item as below

Fill in the settings with the proper values you have when setting up your Mux account. Then save changes.

Go to the Settings section by clicking on the Settings top menu. Choose the Mux service for video upload and save changes as below screenshot.

Congratulations! You have successfully set up the video upload functionality using either FFMPEG or Mux. 

Now, you will see that the Upload option is enabled for users when creating a video




  • No labels