Skip to content

Commit

Permalink
deployment: Cache ffmpeg for AMIs on start media node
Browse files Browse the repository at this point in the history
  • Loading branch information
cruizba committed Mar 7, 2022
1 parent 90a6652 commit b0fc2f9
Showing 1 changed file with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,8 @@ Resources:
"/usr/local/bin/testRecording.sh":
content: |
#!/bin/bash -x
# This script checks the recording COMPOSED and cache it from AMIs to the EBS volume.
# https://serverfault.com/a/837118
TEST_RECORDING_DIR="/opt/openvidu/test-recording"

docker run -d --rm --name=test-recording -e URL=https://openvidu.io/ -v "${TEST_RECORDING_DIR}":/recordings openvidu/openvidu-recording:OPENVIDU_RECORDING_DOCKER_TAG
Expand All @@ -121,6 +123,11 @@ Resources:
# Clean test recording
docker rm -f test-recording
rm -rf "${TEST_RECORDING_DIR}"

# Cache ffmpeg binary
INSTALLATION_DIR="/opt/kms"
MEDIASOUP_IMAGE="$(grep MEDIASOUP_IMAGE "${INSTALLATION_DIR}"/docker-compose.yml | cut -d'=' -f2)"
docker run -it --entrypoint /ffmpeg "${MEDIASOUP_IMAGE}" -version
mode: "000755"
owner: "root"
group: "root"
Expand Down

0 comments on commit b0fc2f9

Please sign in to comment.