First we fetch all videos data and store it as a json file in local. Here we fetch 20 videos and retrancode them at a time.
Execute the following command in terminal to store videos data in local :
$ CLIENT_SECRET=<CLIENT_SECRET> CLIENT_ID=<CLIENT_ID> BRIGHTCOVE_ACCOUNT_ID=<BRIGHTCOVE_ACCOUNT_ID> FUNCTION_NAME=storeBrightcoveVideoDataInJson FILE_DIR_PATH=<FILE_DIR_PATH> node brighcove_videos_bulk_retranscode.js
Execute the following command in terminal to retranscode videos :
$ CLIENT_SECRET=<CLIENT_SECRET> CLIENT_ID=<CLIENT_ID> BRIGHTCOVE_ACCOUNT_ID=<BRIGHTCOVE_ACCOUNT_ID> INGETION_PROFILE=<INGETION_PROFILE> BRIGHTCOVE_VIDEO_MIN_VIEWS=<BRIGHTCOVE_VIDEO_MIN_VIEWS> FUNCTION_NAME=retranscodeVideos FILE_DIR_PATH=<FILE_DIR_PATH> sh brightcove_all_videos_retranscode.sh