node.jsgccdockerfileagora.ionode-gyp

Agora On-Premise-Recording-Nodejs build.sh Error in Dockerfile


I'm encountering build issues with Agora's On-Premise-Recording-Nodejs in a Dockerfile setup. The build.sh script throws multiple C++ warnings related to variable initialization order in IAgoraRecordingEngine.h. Specifically, the warnings are about how certain member variables in the RecordingConfig constructor are being initialized in a different order than they are declared in the class.

Log error

Screen log error 1

Screen log error 2

Dockerfile

FROM ubuntu:18.04

RUN apt-get update && apt-get install -y \
    curl \
    gnupg \
    build-essential \
    gcc \
    g++ \
    make \
    git \
    ffmpeg \
    tar \
    tree \
    python3 \
    && curl -fsSL https://deb.nodesource.com/setup_14.x | bash -  && \
    apt-get install -y nodejs \
    && apt-get clean \
    && rm -rf /var/lib/apt/lists/* \
    && npm install -g node-gyp@8.4.1

ADD https://download.agora.io/ardsdk/release/Agora_Recording_SDK_for_Linux_v2_3_4_FULL.tar.gz /tmp/
RUN tar -xzf /tmp/Agora_Recording_SDK_for_Linux_v2_3_4_FULL.tar.gz -C /tmp/ && \
    rm /tmp/Agora_Recording_SDK_for_Linux_v2_3_4_FULL.tar.gz

RUN git clone --branch dev/nodejs14 https://github.com/AgoraIO/Basic-Recording.git /tmp/Basic-Recording
RUN mv /tmp/Agora_Recording_SDK_for_Linux_FULL /tmp/Basic-Recording/On-Premise-Recording-Nodejs/record/src/sdk

RUN cd /tmp/Basic-Recording/On-Premise-Recording-Nodejs/record && ./build_debug.sh

Solution

  • For those it might help, I developed an alternative solution based on the initial concept using Agora's resources. You can find the project here: https://github.com/lkaopremier/agora-on-premise-recording.