mirror of
https://github.com/scottlamb/moonfire-nvr.git
synced 2025-11-20 01:50:24 -05:00
Initial docker support (#55)
* Dockerfile which allows full build on ubuntu * No cross-compile yet * Fixed build scripts bug found with docker Signed-off-by: Dolf Starreveld <dolf@starreveld.com>
This commit is contained in:
committed by
Scott Lamb
parent
58152e8d94
commit
eaae640703
@@ -82,7 +82,7 @@ catPrefix()
|
||||
|
||||
mkdir_moonfire()
|
||||
{
|
||||
sudo -u ${NVR_USER} -H mkdir "$@"
|
||||
sudo -u "${NVR_USER}" -H mkdir "$@"
|
||||
}
|
||||
|
||||
echo_multi()
|
||||
@@ -342,7 +342,8 @@ prep_moonfire_user()
|
||||
--ingroup "${NVR_GROUP}" --home "${NVR_HOME}"
|
||||
fi
|
||||
if [ ! -d "${NVR_HOME}" ]; then
|
||||
mkdir_moonfire "${NVR_HOME}"
|
||||
sudo mkdir "${NVR_HOME}"
|
||||
sudo chown "${NVR_USER}:${NVR_GROUP}" "${NVR_HOME}"
|
||||
fi
|
||||
sudo chown ${NVR_USER}:${NVR_GROUP} "${NVR_HOME}"
|
||||
}
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
|
||||
initEnvironmentVars
|
||||
makePrepConfig
|
||||
export DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
|
||||
# Process command line options
|
||||
@@ -119,9 +120,9 @@ if ! versionAtLeast "$ffv" "$FFMPEG_MIN_VERSION"; then
|
||||
echo_info -x "Fetching FFmpeg source..."
|
||||
git clone --depth 1 -b "release/${FFMPEG_RELEASE_VERSION}" https://github.com/FFmpeg/FFmpeg.git
|
||||
cd FFmpeg
|
||||
pt=`uname -p 2>& /dev/null`
|
||||
pt=`uname -p 2>/dev/null`
|
||||
if [ -z "${pt##*86*}" ]; then
|
||||
sudo apt-get install -y yasm
|
||||
DEBIAN_FRONTEND=noninteractive sudo apt-get install -y yasm
|
||||
fi
|
||||
./configure --enable-shared
|
||||
make
|
||||
|
||||
Reference in New Issue
Block a user