forked from home-assistant/core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move docker installation scripts to virtualization/Docker path. Split…
…s out openalpr to seperate script. (home-assistant#5676)
- Loading branch information
1 parent
89ec752
commit 8247acb
Showing
10 changed files
with
155 additions
and
132 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#!/bin/bash | ||
# Sets up ffmpeg. | ||
|
||
# Stop on errors | ||
set -e | ||
|
||
PACKAGES=( | ||
ffmpeg | ||
) | ||
|
||
# Add jessie-backports | ||
echo "Adding jessie-backports" | ||
echo "deb http://deb.debian.org/debian jessie-backports main" >> /etc/apt/sources.list | ||
apt-get update | ||
|
||
apt-get install -y --no-install-recommends -t jessie-backports ${PACKAGES[@]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/bin/bash | ||
# Sets up openalpr. | ||
|
||
# Stop on errors | ||
set -e | ||
|
||
PACKAGES=( | ||
# homeassistant.components.image_processing.openalpr_local | ||
libopencv-dev libtesseract-dev libleptonica-dev liblog4cplus-dev | ||
) | ||
|
||
apt-get install -y --no-install-recommends ${PACKAGES[@]} | ||
|
||
# Clone the latest code from GitHub | ||
git clone https://github.com/openalpr/openalpr.git /usr/local/src/openalpr | ||
|
||
# Setup the build directory | ||
cd /usr/local/src/openalpr/src | ||
mkdir -p build | ||
cd build | ||
|
||
# Setup the compile environment | ||
cmake -DWITH_TEST=FALSE -DWITH_BINDING_JAVA=FALSE --DWITH_BINDING_PYTHON=FALSE --DWITH_BINDING_GO=FALSE -DWITH_DAEMON=FALSE -DCMAKE_INSTALL_PREFIX:PATH=/usr/local .. | ||
|
||
# compile the library | ||
make | ||
|
||
# Install the binaries/libraries to your local system (prefix is /usr/local) | ||
make install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/bin/bash | ||
# Sets up tellstick. | ||
|
||
# Stop on errors | ||
set -e | ||
|
||
PACKAGES=( | ||
# homeassistant.components.tellstick | ||
libtelldus-core2 | ||
) | ||
|
||
# Add Tellstick repository | ||
echo "deb http://download.telldus.com/debian/ stable main" >> /etc/apt/sources.list.d/telldus.list | ||
wget -qO - http://download.telldus.se/debian/telldus-public.key | apt-key add - | ||
|
||
apt-get update | ||
apt-get install -y --no-install-recommends ${PACKAGES[@]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
#!/bin/bash | ||
# Install requirements and build dependencies for Home Assinstant in Docker. | ||
|
||
# Stop on errors | ||
set -e | ||
|
||
INSTALL_TELLSTICK="${INSTALL_TELLSTICK:-yes}" | ||
INSTALL_OPENALPR="${INSTALL_OPENALPR:-yes}" | ||
INSTALL_FFMPEG="${INSTALL_FFMPEG:-yes}" | ||
INSTALL_OPENZWAVE="${INSTALL_OPENZWAVE:-yes}" | ||
INSTALL_LIBCEC="${INSTALL_LIBCEC:-yes}" | ||
INSTALL_PHANTOMJS="${INSTALL_PHANTOMJS:-yes}" | ||
|
||
# Required debian packages for running hass or components | ||
PACKAGES=( | ||
# build-essential is required for python pillow module on non-x86_64 arch | ||
build-essential | ||
# homeassistant.components.image_processing.openalpr_local | ||
libxrandr-dev | ||
# homeassistant.components.device_tracker.nmap_tracker | ||
nmap net-tools libcurl3-dev | ||
# homeassistant.components.device_tracker.bluetooth_tracker | ||
bluetooth libglib2.0-dev libbluetooth-dev | ||
) | ||
|
||
# Required debian packages for building dependencies | ||
PACKAGES_DEV=( | ||
cmake git | ||
# python-openzwave | ||
cython3 libudev-dev | ||
# libcec | ||
swig | ||
) | ||
|
||
# Install packages | ||
apt-get update | ||
apt-get install -y --no-install-recommends ${PACKAGES[@]} ${PACKAGES_DEV[@]} | ||
|
||
if [ "$INSTALL_TELLSTICK" == "yes" ]; then | ||
virtualization/Docker/scripts/tellstick | ||
fi | ||
|
||
if [ "$INSTALL_OPENALPR" == "yes" ]; then | ||
virtualization/Docker/scripts/openalpr | ||
fi | ||
|
||
if [ "$INSTALL_FFMPEG" == "yes" ]; then | ||
virtualization/Docker/scripts/ffmpeg | ||
fi | ||
|
||
if [ "$INSTALL_OPENZWAVE" == "yes" ]; then | ||
virtualization/Docker/scripts/python_openzwave | ||
fi | ||
|
||
if [ "$INSTALL_LIBCEC" == "yes" ]; then | ||
virtualization/Docker/scripts/libcec | ||
fi | ||
|
||
if [ "$INSTALL_PHANTOMJS" == "yes" ]; then | ||
virtualization/Docker/scripts/phantomjs | ||
fi | ||
|
||
# Remove packages | ||
apt-get remove -y --purge ${PACKAGES_DEV[@]} | ||
apt-get -y --purge autoremove | ||
|
||
# Cleanup | ||
apt-get clean | ||
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* build/ |