Open ollyde opened 2 years ago
Logs from server
I've provided a simple setup to emulate this. Still doesn't work.
index.js
const ffprobe = require('ffprobe');
const ffprobeStatic = require('ffprobe-static');
const init = async () => {
console.log('Running')
try {
const info = await ffprobe("https://storage.googleapis.com/vegiano-dev/dummy-videos/prcessing_video_1.mp4", { path: ffprobeStatic.path })
console.log(info);
} catch (e) {
console.error(e)
}
}
init();
Dockerfile
FROM ubuntu:22.10
# Update
RUN apt-get -y update
RUN apt install -y wget
RUN apt-get install -y --no-install-recommends ffmpeg
# Install node 16
ENV NODE_VERSION=16.15.1
RUN apt install -y curl
RUN curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash
ENV NVM_DIR=/root/.nvm
RUN . "$NVM_DIR/nvm.sh" && nvm install v${NODE_VERSION}
RUN . "$NVM_DIR/nvm.sh" && nvm use v${NODE_VERSION}
RUN . "$NVM_DIR/nvm.sh" && nvm alias default v${NODE_VERSION}
ENV PATH="/root/.nvm/versions/node/v${NODE_VERSION}/bin/:${PATH}"
RUN node --version
RUN npm --version
# Create app directory
RUN mkdir -p /app
WORKDIR /app
# Move app and build app
WORKDIR /app
COPY . /app
# Start the app.
EXPOSE 8080
EXPOSE 5000
CMD ["node", "index.js"]
It works locally just fine. MacOS M1 Max.
On Prod/Docker release "streams" is undefined.
I have the following dependencies
Importing
The following code.
The following docker file