From 3e9c4bef68fae181b973b191b4a1210fb7deb319 Mon Sep 17 00:00:00 2001 From: Michael Hansen Date: Sun, 19 Apr 2020 11:39:46 -0400 Subject: [PATCH] Clean up docker file and docker run.sh --- docker/run.sh | 20 +- docker/templates/Dockerfile.template | 52 ----- docker/templates/all_profiles/profiles.txt | 1 - docker/templates/alsa/pulseaudio.txt | 1 - docker/templates/alsa/rhasspy_user.txt | 0 .../Dockerfile.from-source.alsa.all | 207 ------------------ .../Dockerfile.from-source.alsa.en | 96 -------- .../Dockerfile.from-source.pulseaudio.en | 113 ---------- .../dockerfiles/Dockerfile.prebuilt.alsa.all | 91 -------- .../dockerfiles/Dockerfile.prebuilt.alsa.en | 91 -------- .../Dockerfile.prebuilt.pulseaudio.en | 108 --------- docker/templates/en_profile/profiles.txt | 1 - .../templates/from-source/phonetisaurus.txt | 7 - .../from-source/system_dependencies.txt | 18 -- docker/templates/generate.sh | 67 ------ docker/templates/prebuilt/phonetisaurus.txt | 3 - docker/templates/prebuilt/rhasspy_tools.txt | 3 - .../prebuilt/system_dependencies.txt | 10 - docker/templates/pulseaudio/pulseaudio.txt | 16 -- docker/templates/pulseaudio/rhasspy_user.txt | 3 - docker/templates/shared/gstreamer.txt | 2 - docker/templates/shared/kaldi.txt | 4 - docker/templates/shared/mitlm.txt | 9 - docker/templates/shared/mycroft_precise.txt | 7 - docker/templates/shared/opengrm.txt | 9 - .../templates/shared/python_pocketsphinx.txt | 4 - .../templates/shared/python_requirements.txt | 10 - docker/templates/shared/qemu.txt | 2 - docker/templates/shared/rhasspy_code.txt | 10 - docker/templates/shared/snowboy.txt | 3 - docker/templates/shared/tts.txt | 1 - requirements.txt | 1 - 32 files changed, 14 insertions(+), 956 deletions(-) delete mode 100755 docker/templates/Dockerfile.template delete mode 100755 docker/templates/all_profiles/profiles.txt delete mode 100755 docker/templates/alsa/pulseaudio.txt delete mode 100755 docker/templates/alsa/rhasspy_user.txt delete mode 100644 docker/templates/dockerfiles/Dockerfile.from-source.alsa.all delete mode 100644 docker/templates/dockerfiles/Dockerfile.from-source.alsa.en delete mode 100644 docker/templates/dockerfiles/Dockerfile.from-source.pulseaudio.en delete mode 100644 docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.all delete mode 100644 docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.en delete mode 100644 docker/templates/dockerfiles/Dockerfile.prebuilt.pulseaudio.en delete mode 100755 docker/templates/en_profile/profiles.txt delete mode 100755 docker/templates/from-source/phonetisaurus.txt delete mode 100755 docker/templates/from-source/system_dependencies.txt delete mode 100755 docker/templates/generate.sh delete mode 100755 docker/templates/prebuilt/phonetisaurus.txt delete mode 100644 docker/templates/prebuilt/rhasspy_tools.txt delete mode 100755 docker/templates/prebuilt/system_dependencies.txt delete mode 100755 docker/templates/pulseaudio/pulseaudio.txt delete mode 100755 docker/templates/pulseaudio/rhasspy_user.txt delete mode 100644 docker/templates/shared/gstreamer.txt delete mode 100644 docker/templates/shared/kaldi.txt delete mode 100755 docker/templates/shared/mitlm.txt delete mode 100755 docker/templates/shared/mycroft_precise.txt delete mode 100644 docker/templates/shared/opengrm.txt delete mode 100755 docker/templates/shared/python_pocketsphinx.txt delete mode 100755 docker/templates/shared/python_requirements.txt delete mode 100644 docker/templates/shared/qemu.txt delete mode 100755 docker/templates/shared/rhasspy_code.txt delete mode 100755 docker/templates/shared/snowboy.txt delete mode 100644 docker/templates/shared/tts.txt diff --git a/docker/run.sh b/docker/run.sh index f375007..21504f0 100755 --- a/docker/run.sh +++ b/docker/run.sh @@ -1,5 +1,4 @@ #!/usr/bin/env bash -this_dir="$( cd "$( dirname "$0" )" && pwd )" # Try to detemine where Rhasspy is located if [[ -z "${RHASSPY_APP}" ]]; then @@ -16,12 +15,21 @@ if [[ -f "${CONFIG_PATH}" ]]; then # Hass.IO configuration profile_name="$(jq --raw-output '.profile_name' "${CONFIG_PATH}")" profile_dir="$(jq --raw-output '.profile_dir' "${CONFIG_PATH}")" - RHASSPY_ARGS="--profile ${profile_name} --user-profiles ${profile_dir}" + RHASSPY_ARGS=('--profile' "${profile_name}" '--user-profiles' "${profile_dir}") - asoundrc="$(jq --raw-output '.asoundrc' ${CONFIG_PATH})" + # Copy user-defined asoundrc to root + asoundrc="$(jq --raw-output '.asoundrc' "${CONFIG_PATH}")" if [[ ! -z "${asoundrc}" ]]; then echo "${asoundrc}" > /root/.asoundrc fi + + # Add SSL settings + ssl="$(jq --raw-output '.ssl' "${CONFIG_PATH}")" + if [[ "${ssl}" == 'true' ]]; then + certfile="$(jq --raw-output '.certfile' "${CONFIG_PATH}")" + keyfile="$(jq --raw-output '.keyfile' "${CONFIG_PATH}")" + RHASSPY_ARGS+=('--ssl' "${certfile}" "${keyfile}") + fi fi RHASSPY_VENV="${RHASSPY_APP}/.venv" @@ -32,10 +40,10 @@ if [[ -d "${RHASSPY_VENV}" ]]; then export LD_LIBRARY_PATH="${RHASSPY_VENV}/lib:${LD_LIBRARY_PATH}" fi -cd "${RHASSPY_APP}" +cd "${RHASSPY_APP}" || exit 1 -if [[ -z "${RHASSPY_ARGS}" ]]; then +if [[ -z "${RHASSPY_ARGS[*]}" ]]; then python3 app.py "$@" else - python3 app.py ${RHASSPY_ARGS} "$@" + python3 app.py "${RHASSPY_ARGS[@]}" "$@" fi diff --git a/docker/templates/Dockerfile.template b/docker/templates/Dockerfile.template deleted file mode 100755 index fa19651..0000000 --- a/docker/templates/Dockerfile.template +++ /dev/null @@ -1,52 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -QEMU - -SYSTEM_DEPENDENCIES - -RHASSPY_TOOLS - -PYTHON_REQUIREMENTS - -PYTHON_POCKETSPHINX - -SNOWBOY - -TTS - -KALDI - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -GSTREAMER - -PULSEAUDIO - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - -RHASSPY_USER - -PROFILES - -RHASSPY_CODE - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/all_profiles/profiles.txt b/docker/templates/all_profiles/profiles.txt deleted file mode 100755 index 99b7797..0000000 --- a/docker/templates/all_profiles/profiles.txt +++ /dev/null @@ -1 +0,0 @@ -COPY profiles/ ${RHASSPY_APP}/profiles/ diff --git a/docker/templates/alsa/pulseaudio.txt b/docker/templates/alsa/pulseaudio.txt deleted file mode 100755 index 139567b..0000000 --- a/docker/templates/alsa/pulseaudio.txt +++ /dev/null @@ -1 +0,0 @@ -ENV RHASSPY_APP /usr/share/rhasspy diff --git a/docker/templates/alsa/rhasspy_user.txt b/docker/templates/alsa/rhasspy_user.txt deleted file mode 100755 index e69de29..0000000 diff --git a/docker/templates/dockerfiles/Dockerfile.from-source.alsa.all b/docker/templates/dockerfiles/Dockerfile.from-source.alsa.all deleted file mode 100644 index 6c884c8..0000000 --- a/docker/templates/dockerfiles/Dockerfile.from-source.alsa.all +++ /dev/null @@ -1,207 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ - -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/openfst-1.6.2-1_${BUILD_ARCH}.deb / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then \ - apt-get install --no-install-recommends --yes libfst-dev libfst-tools; \ - else \ - dpkg -i /openfst-1.6.2-1_${BUILD_ARCH}.deb; \ - rm /openfst*.deb; \ - fi - -RHASSPY_TOOLS - -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt - -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* - -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi - -RUN apt-get install --no-install-recommends --yes flite libttspico-utils - -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good - -ENV RHASSPY_APP /usr/share/rhasspy - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - - - -COPY profiles/zh/profile.json \ - profiles/zh/custom_words.txt \ - profiles/zh/espeak_phonemes.txt \ - profiles/zh/phoneme_examples.txt \ - profiles/zh/frequent_words.txt \ - profiles/zh/sentences.ini \ - profiles/zh/stop_words.txt ${RHASSPY_APP}/profiles/zh/ - -COPY profiles/hi/ \ - profiles/hi/profile.json \ - profiles/hi/custom_words.txt \ - profiles/hi/espeak_phonemes.txt \ - profiles/hi/phoneme_examples.txt \ - profiles/hi/frequent_words.txt \ - profiles/hi/sentences.ini \ - profiles/hi/stop_words.txt ${RHASSPY_APP}/profiles/hi/ - -COPY profiles/el/profile.json \ - profiles/el/custom_words.txt \ - profiles/el/espeak_phonemes.txt \ - profiles/el/phoneme_examples.txt \ - profiles/el/frequent_words.txt \ - profiles/el/sentences.ini \ - profiles/el/stop_words.txt ${RHASSPY_APP}/profiles/el/ - -COPY profiles/de/profile.json \ - profiles/de/custom_words.txt \ - profiles/de/espeak_phonemes.txt \ - profiles/de/phoneme_examples.txt \ - profiles/de/frequent_words.txt \ - profiles/de/sentences.ini \ - profiles/de/stop_words.txt ${RHASSPY_APP}/profiles/de/ - -COPY profiles/it/profile.json \ - profiles/it/custom_words.txt \ - profiles/it/espeak_phonemes.txt \ - profiles/it/phoneme_examples.txt \ - profiles/it/frequent_words.txt \ - profiles/it/sentences.ini \ - profiles/it/stop_words.txt ${RHASSPY_APP}/profiles/it/ - -COPY profiles/es/profile.json \ - profiles/es/custom_words.txt \ - profiles/es/espeak_phonemes.txt \ - profiles/es/phoneme_examples.txt \ - profiles/es/frequent_words.txt \ - profiles/es/sentences.ini \ - profiles/es/stop_words.txt ${RHASSPY_APP}/profiles/es/ - -COPY profiles/fr/profile.json \ - profiles/fr/custom_words.txt \ - profiles/fr/espeak_phonemes.txt \ - profiles/fr/phoneme_examples.txt \ - profiles/fr/frequent_words.txt \ - profiles/fr/sentences.ini \ - profiles/fr/stop_words.txt ${RHASSPY_APP}/profiles/fr/ - -COPY profiles/ru/profile.json \ - profiles/ru/custom_words.txt \ - profiles/ru/espeak_phonemes.txt \ - profiles/ru/phoneme_examples.txt \ - profiles/ru/frequent_words.txt \ - profiles/ru/sentences.ini \ - profiles/ru/stop_words.txt ${RHASSPY_APP}/profiles/ru/ - -COPY profiles/nl/profile.json \ - profiles/nl/custom_words.txt \ - profiles/nl/espeak_phonemes.txt \ - profiles/nl/phoneme_examples.txt \ - profiles/nl/frequent_words.txt \ - profiles/nl/sentences.ini \ - profiles/nl/stop_words.txt ${RHASSPY_APP}/profiles/nl/ - -COPY profiles/vi/profile.json \ - profiles/vi/custom_words.txt \ - profiles/vi/espeak_phonemes.txt \ - profiles/vi/phoneme_examples.txt \ - profiles/vi/frequent_words.txt \ - profiles/vi/sentences.ini \ - profiles/vi/stop_words.txt ${RHASSPY_APP}/profiles/vi/ - -COPY profiles/pt/profile.json \ - profiles/pt/custom_words.txt \ - profiles/pt/espeak_phonemes.txt \ - profiles/pt/phoneme_examples.txt \ - profiles/pt/frequent_words.txt \ - profiles/pt/sentences.ini \ - profiles/pt/stop_words.txt ${RHASSPY_APP}/profiles/pt/ - -COPY profiles/sv/profile.json \ - profiles/sv/custom_words.txt \ - profiles/sv/espeak_phonemes.txt \ - profiles/sv/phoneme_examples.txt \ - profiles/sv/frequent_words.txt \ - profiles/sv/sentences.ini \ - profiles/sv/stop_words.txt ${RHASSPY_APP}/profiles/sv/ - -COPY profiles/ca/profile.json \ - profiles/ca/custom_words.txt \ - profiles/ca/espeak_phonemes.txt \ - profiles/ca/phoneme_examples.txt \ - profiles/ca/frequent_words.txt \ - profiles/ca/sentences.ini \ - profiles/ca/stop_words.txt ${RHASSPY_APP}/profiles/ca/ - -COPY profiles/en/profile.json \ - profiles/en/custom_words.txt \ - profiles/en/espeak_phonemes.txt \ - profiles/en/phoneme_examples.txt \ - profiles/en/frequent_words.txt \ - profiles/en/sentences.ini \ - profiles/en/stop_words.txt ${RHASSPY_APP}/profiles/en/ - -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/dockerfiles/Dockerfile.from-source.alsa.en b/docker/templates/dockerfiles/Dockerfile.from-source.alsa.en deleted file mode 100644 index 9015f6f..0000000 --- a/docker/templates/dockerfiles/Dockerfile.from-source.alsa.en +++ /dev/null @@ -1,96 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ - -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/openfst-1.6.2-1_${BUILD_ARCH}.deb / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then \ - apt-get install --no-install-recommends --yes libfst-dev libfst-tools; \ - else \ - dpkg -i /openfst-1.6.2-1_${BUILD_ARCH}.deb; \ - rm /openfst*.deb; \ - fi - -RHASSPY_TOOLS - -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt - -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* - -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi - -RUN apt-get install --no-install-recommends --yes flite libttspico-utils - -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good - -ENV RHASSPY_APP /usr/share/rhasspy - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - - - -COPY profiles/en/ ${RHASSPY_APP}/profiles/en/ - -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/dockerfiles/Dockerfile.from-source.pulseaudio.en b/docker/templates/dockerfiles/Dockerfile.from-source.pulseaudio.en deleted file mode 100644 index d662f8f..0000000 --- a/docker/templates/dockerfiles/Dockerfile.from-source.pulseaudio.en +++ /dev/null @@ -1,113 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ - -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/openfst-1.6.2-1_${BUILD_ARCH}.deb / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then \ - apt-get install --no-install-recommends --yes libfst-dev libfst-tools; \ - else \ - dpkg -i /openfst-1.6.2-1_${BUILD_ARCH}.deb; \ - rm /openfst*.deb; \ - fi - -RHASSPY_TOOLS - -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt - -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* - -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi - -RUN apt-get install --no-install-recommends --yes flite libttspico-utils - -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good - -RUN apt-get install -y pulseaudio -COPY etc/pulseaudio.client.conf /etc/pulse/client.conf - -# Create new user -ENV UNAME=rhasspy -RUN export UNAME=$UNAME UID=1000 GID=1000 && \ - mkdir -p "/home/${UNAME}" && \ - echo "${UNAME}:x:${UID}:${GID}:${UNAME} User,,,:/home/${UNAME}:/bin/bash" >> /etc/passwd && \ - echo "${UNAME}:x:${UID}:" >> /etc/group && \ - mkdir -p /etc/sudoers.d && \ - echo "${UNAME} ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/${UNAME} && \ - chmod 0440 /etc/sudoers.d/${UNAME} && \ - chown ${UID}:${GID} -R /home/${UNAME} && \ - gpasswd -a ${UNAME} audio - -ENV RHASSPY_APP /home/${UNAME} - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - -# Switch to new user -USER $UNAME -ENV HOME /home/${UNAME} - -COPY profiles/en/ ${RHASSPY_APP}/profiles/en/ - -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.all b/docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.all deleted file mode 100644 index 6d390de..0000000 --- a/docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.all +++ /dev/null @@ -1,91 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ - -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/rhasspy-tools_${BUILD_ARCH}.tar.gz / -RUN tar -C /usr -xvf /rhasspy-tools_${BUILD_ARCH}.tar.gz && \ - rm -f /rhasspy-tools_${BUILD_ARCH}.tar.gz - -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt - -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* - -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi - -RUN apt-get install --no-install-recommends --yes flite libttspico-utils lame - -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good - -ENV RHASSPY_APP /usr/share/rhasspy - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - - - -COPY profiles/ ${RHASSPY_APP}/profiles/ - -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ -COPY VERSION ${RHASSPY_APP}/ - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.en b/docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.en deleted file mode 100644 index e4eb157..0000000 --- a/docker/templates/dockerfiles/Dockerfile.prebuilt.alsa.en +++ /dev/null @@ -1,91 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ - -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libfst-dev libfst-tools \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/rhasspy-tools_${BUILD_ARCH}.tar.gz / -RUN tar -C /usr -xvf /rhasspy-tools_${BUILD_ARCH}.tar.gz && \ - rm -f /rhasspy-tools_${BUILD_ARCH}.tar.gz - -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt - -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* - -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi - -RUN apt-get install --no-install-recommends --yes flite libttspico-utils - -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good - -ENV RHASSPY_APP /usr/share/rhasspy - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - - - -COPY profiles/en/ ${RHASSPY_APP}/profiles/en/ - -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/dockerfiles/Dockerfile.prebuilt.pulseaudio.en b/docker/templates/dockerfiles/Dockerfile.prebuilt.pulseaudio.en deleted file mode 100644 index eb7c692..0000000 --- a/docker/templates/dockerfiles/Dockerfile.prebuilt.pulseaudio.en +++ /dev/null @@ -1,108 +0,0 @@ -ARG BUILD_FROM -FROM $BUILD_FROM -LABEL maintainer="Michael Hansen " - -ARG BUILD_ARCH -ARG CPU_ARCH -ENV LANG C.UTF-8 - -ARG MAKE_THREADS=4 - -WORKDIR / - -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ - -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libfst-dev libfst-tools \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/rhasspy-tools_${BUILD_ARCH}.tar.gz / -RUN tar -C /usr -xvf /rhasspy-tools_${BUILD_ARCH}.tar.gz && \ - rm -f /rhasspy-tools_${BUILD_ARCH}.tar.gz - -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt - -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* - -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi - -RUN apt-get install --no-install-recommends --yes flite libttspico-utils - -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz - -RUN ldconfig - -# Copy bw and mllr_solve to /usr/bin -RUN find / -name bw -exec cp '{}' /usr/bin/ \; -RUN find / -name mllr_solve -exec cp '{}' /usr/bin/ \; - -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good - -RUN apt-get install -y pulseaudio -COPY etc/pulseaudio.client.conf /etc/pulse/client.conf - -# Create new user -ENV UNAME=rhasspy -RUN export UNAME=$UNAME UID=1000 GID=1000 && \ - mkdir -p "/home/${UNAME}" && \ - echo "${UNAME}:x:${UID}:${GID}:${UNAME} User,,,:/home/${UNAME}:/bin/bash" >> /etc/passwd && \ - echo "${UNAME}:x:${UID}:" >> /etc/group && \ - mkdir -p /etc/sudoers.d && \ - echo "${UNAME} ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/${UNAME} && \ - chmod 0440 /etc/sudoers.d/${UNAME} && \ - chown ${UID}:${GID} -R /home/${UNAME} && \ - gpasswd -a ${UNAME} audio - -ENV RHASSPY_APP /home/${UNAME} - -# Copy script to run -COPY docker/run.sh /run.sh -RUN chmod +x /run.sh - -# Switch to new user -USER $UNAME -ENV HOME /home/${UNAME} - -COPY profiles/en/ ${RHASSPY_APP}/profiles/en/ - -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ - -ENV CONFIG_PATH /data/options.json -ENV KALDI_PREFIX /opt - -ENTRYPOINT ["/run.sh"] \ No newline at end of file diff --git a/docker/templates/en_profile/profiles.txt b/docker/templates/en_profile/profiles.txt deleted file mode 100755 index d2a7c9a..0000000 --- a/docker/templates/en_profile/profiles.txt +++ /dev/null @@ -1 +0,0 @@ -COPY profiles/en/ ${RHASSPY_APP}/profiles/en/ diff --git a/docker/templates/from-source/phonetisaurus.txt b/docker/templates/from-source/phonetisaurus.txt deleted file mode 100755 index c25b508..0000000 --- a/docker/templates/from-source/phonetisaurus.txt +++ /dev/null @@ -1,7 +0,0 @@ -COPY download/phonetisaurus-2019.tar.gz /phonetisaurus.tar.gz -RUN cd / && tar -xf phonetisaurus.tar.gz -RUN cd /phonetisaurus && \ - ./configure && \ - make -j $MAKE_THREADS && \ - make install && \ - rm -rf /phonetisaurus* diff --git a/docker/templates/from-source/system_dependencies.txt b/docker/templates/from-source/system_dependencies.txt deleted file mode 100755 index 2995280..0000000 --- a/docker/templates/from-source/system_dependencies.txt +++ /dev/null @@ -1,18 +0,0 @@ -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain - -COPY download/openfst-1.6.2-1_${BUILD_ARCH}.deb / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then \ - apt-get install --no-install-recommends --yes libfst-dev libfst-tools; \ - else \ - dpkg -i /openfst-1.6.2-1_${BUILD_ARCH}.deb; \ - rm /openfst*.deb; \ - fi diff --git a/docker/templates/generate.sh b/docker/templates/generate.sh deleted file mode 100755 index 7e176b3..0000000 --- a/docker/templates/generate.sh +++ /dev/null @@ -1,67 +0,0 @@ -#!/usr/bin/env bash - -# Directory of *this* script -DIR="$( cd "$( dirname "$0" )" && pwd )" -template="$DIR/Dockerfile.template" -out="$DIR/dockerfiles" -mkdir -p "$out" - -# ----------------------------------------------------------------------------- - -# Uppercases an input string -function upper { - tr '[[:lower:]]' '[[:upper:]]' -} - -# Creates m4 "define" statements from text files in one or more directories. -# The contents of dir/file.txt will be the value of variable FILE. -function set_variables { - echo "divert(-1)" - while [[ ! -z "$1" ]]; do - if [[ -d "$1" ]]; then - for var_file in $(find "$1" -type f -name "*.txt"); do - var_name=$(basename "$var_file" .txt | upper) - echo "define(\`$var_name', \`$(cat $var_file)')" - done - elif [[ -f "$1" ]]; then - var_file="$1" - var_name=$(basename "$var_file" .txt | upper) - echo "define(\`$var_name', \`$(cat $var_file)')" - fi - - shift - done - echo "divert(0)dnl" -} - -# ----------------------------------------------------------------------------- - -#------------ -# From source -#------------ -# set_variables "$DIR/shared/" "$DIR/from-source/" \ -# "$DIR/alsa/" "$DIR/en_profile/" \ -# | cat - "$template" | m4 > "$out/Dockerfile.from-source.alsa.en" - -# set_variables "$DIR/shared/" "$DIR/from-source/" \ -# "$DIR/pulseaudio/" "$DIR/en_profile/" \ -# | cat - "$template" | m4 > "$out/Dockerfile.from-source.pulseaudio.en" - -# set_variables "$DIR/shared/" "$DIR/from-source/" \ -# "$DIR/alsa/" "$DIR/all_profiles/" \ -# | cat - "$template" | m4 > "$out/Dockerfile.from-source.alsa.all" - -#----------- -# Pre-built -#----------- -# set_variables "$DIR/shared/" "$DIR/prebuilt/" \ -# "$DIR/alsa/" "$DIR/en_profile/" \ -# | cat - "$template" | m4 > "$out/Dockerfile.prebuilt.alsa.en" - -# set_variables "$DIR/shared/" "$DIR/prebuilt/" \ -# "$DIR/pulseaudio/" "$DIR/en_profile/" \ -# | cat - "$template" | m4 > "$out/Dockerfile.prebuilt.pulseaudio.en" - -set_variables "$DIR/shared/" "$DIR/prebuilt/" \ - "$DIR/alsa/" "$DIR/all_profiles/" \ - | cat - "$template" | m4 > "$out/Dockerfile.prebuilt.alsa.all" diff --git a/docker/templates/prebuilt/phonetisaurus.txt b/docker/templates/prebuilt/phonetisaurus.txt deleted file mode 100755 index 91d45c6..0000000 --- a/docker/templates/prebuilt/phonetisaurus.txt +++ /dev/null @@ -1,3 +0,0 @@ -COPY download/phonetisaurus-2019_${BUILD_ARCH}.deb /phonetisaurus.deb -RUN dpkg -i /phonetisaurus.deb && \ - rm /phonetisaurus.deb diff --git a/docker/templates/prebuilt/rhasspy_tools.txt b/docker/templates/prebuilt/rhasspy_tools.txt deleted file mode 100644 index 3c67dad..0000000 --- a/docker/templates/prebuilt/rhasspy_tools.txt +++ /dev/null @@ -1,3 +0,0 @@ -COPY download/rhasspy-tools_${BUILD_ARCH}.tar.gz / -RUN tar -C /usr -xvf /rhasspy-tools_${BUILD_ARCH}.tar.gz && \ - rm -f /rhasspy-tools_${BUILD_ARCH}.tar.gz diff --git a/docker/templates/prebuilt/system_dependencies.txt b/docker/templates/prebuilt/system_dependencies.txt deleted file mode 100755 index 28fde8d..0000000 --- a/docker/templates/prebuilt/system_dependencies.txt +++ /dev/null @@ -1,10 +0,0 @@ -RUN apt-get update && \ - apt-get install --no-install-recommends --yes \ - bash jq unzip \ - python3 python3-pip python3-dev \ - build-essential portaudio19-dev swig \ - libatlas-base-dev \ - sox espeak flite alsa-utils \ - git curl \ - autoconf libtool automake bison \ - sphinxbase-utils sphinxtrain diff --git a/docker/templates/pulseaudio/pulseaudio.txt b/docker/templates/pulseaudio/pulseaudio.txt deleted file mode 100755 index 719efe7..0000000 --- a/docker/templates/pulseaudio/pulseaudio.txt +++ /dev/null @@ -1,16 +0,0 @@ -RUN apt-get install -y pulseaudio -COPY etc/pulseaudio.client.conf /etc/pulse/client.conf - -# Create new user -ENV UNAME=rhasspy -RUN export UNAME=$UNAME UID=1000 GID=1000 && \ - mkdir -p "/home/${UNAME}" && \ - echo "${UNAME}:x:${UID}:${GID}:${UNAME} User,,,:/home/${UNAME}:/bin/bash" >> /etc/passwd && \ - echo "${UNAME}:x:${UID}:" >> /etc/group && \ - mkdir -p /etc/sudoers.d && \ - echo "${UNAME} ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/${UNAME} && \ - chmod 0440 /etc/sudoers.d/${UNAME} && \ - chown ${UID}:${GID} -R /home/${UNAME} && \ - gpasswd -a ${UNAME} audio - -ENV RHASSPY_APP /home/${UNAME} diff --git a/docker/templates/pulseaudio/rhasspy_user.txt b/docker/templates/pulseaudio/rhasspy_user.txt deleted file mode 100755 index a73a849..0000000 --- a/docker/templates/pulseaudio/rhasspy_user.txt +++ /dev/null @@ -1,3 +0,0 @@ -# Switch to new user -USER $UNAME -ENV HOME /home/${UNAME} diff --git a/docker/templates/shared/gstreamer.txt b/docker/templates/shared/gstreamer.txt deleted file mode 100644 index ef092eb..0000000 --- a/docker/templates/shared/gstreamer.txt +++ /dev/null @@ -1,2 +0,0 @@ -# Install gstreamer and plugins -RUN apt-get install --no-install-recommends --yes gstreamer1.0-tools gstreamer1.0-plugins-good diff --git a/docker/templates/shared/kaldi.txt b/docker/templates/shared/kaldi.txt deleted file mode 100644 index e4e040b..0000000 --- a/docker/templates/shared/kaldi.txt +++ /dev/null @@ -1,4 +0,0 @@ -COPY download/kaldi_${BUILD_ARCH}.tar.gz /kaldi.tar.gz -RUN mkdir -p /opt && \ - tar -C /opt -xzf /kaldi.tar.gz && \ - rm /kaldi.tar.gz diff --git a/docker/templates/shared/mitlm.txt b/docker/templates/shared/mitlm.txt deleted file mode 100755 index ae1da04..0000000 --- a/docker/templates/shared/mitlm.txt +++ /dev/null @@ -1,9 +0,0 @@ -# Install mitlm -RUN apt-get install --no-install-recommends --yes gfortran -COPY download/mitlm-0.4.2.tar.xz / -RUN cd / && tar -xf mitlm-0.4.2.tar.xz && cd mitlm-0.4.2/ && \ - ./configure && \ - make -j $MAKE_THREADS && \ - make install && \ - rm -rf /mitlm-0.4.2* - diff --git a/docker/templates/shared/mycroft_precise.txt b/docker/templates/shared/mycroft_precise.txt deleted file mode 100755 index ec0f18b..0000000 --- a/docker/templates/shared/mycroft_precise.txt +++ /dev/null @@ -1,7 +0,0 @@ -# Install Mycroft Precise -COPY download/precise-engine_0.3.0_${CPU_ARCH}.tar.gz /precise-engine.tar.gz -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then \ - cd / && tar -xzf /precise-engine.tar.gz && \ - ln -s /precise-engine/precise-engine /usr/bin/precise-engine && \ - rm /precise-engine.tar.gz; \ - fi diff --git a/docker/templates/shared/opengrm.txt b/docker/templates/shared/opengrm.txt deleted file mode 100644 index f060bd5..0000000 --- a/docker/templates/shared/opengrm.txt +++ /dev/null @@ -1,9 +0,0 @@ -# Install Opengrm -COPY download/opengrm-ngram-1.3.3.tar.gz / -RUN cd / && tar -xf opengrm-ngram-1.3.3.tar.gz && \ - cd opengrm-ngram-1.3.3 && \ - ./configure && \ - make -j $MAKE_THREADS && \ - make install && \ - ldconfig && \ - rm -rf /opengrm* diff --git a/docker/templates/shared/python_pocketsphinx.txt b/docker/templates/shared/python_pocketsphinx.txt deleted file mode 100755 index 21fada0..0000000 --- a/docker/templates/shared/python_pocketsphinx.txt +++ /dev/null @@ -1,4 +0,0 @@ -# Install Pocketsphinx Python module with no sound -COPY download/pocketsphinx-python.tar.gz / -RUN python3 -m pip install --no-cache-dir /pocketsphinx-python.tar.gz && \ - rm -rf /pocketsphinx-python* diff --git a/docker/templates/shared/python_requirements.txt b/docker/templates/shared/python_requirements.txt deleted file mode 100755 index f669550..0000000 --- a/docker/templates/shared/python_requirements.txt +++ /dev/null @@ -1,10 +0,0 @@ -# Install Python dependencies -RUN python3 -m pip install --no-cache-dir setuptools wheel - -RUN apt-get install -y libfreetype6-dev libpng-dev pkg-config libffi-dev libssl-dev -COPY requirements.txt /requirements.txt -RUN if [ "$BUILD_ARCH" != "amd64" ]; then \ - grep -v flair /requirements.txt > /requirements-noflair.txt; \ - mv /requirements-noflair.txt /requirements.txt; \ - fi -RUN python3 -m pip install --no-cache-dir -r /requirements.txt diff --git a/docker/templates/shared/qemu.txt b/docker/templates/shared/qemu.txt deleted file mode 100644 index 1bd2671..0000000 --- a/docker/templates/shared/qemu.txt +++ /dev/null @@ -1,2 +0,0 @@ -COPY etc/qemu-arm-static /usr/bin/ -COPY etc/qemu-aarch64-static /usr/bin/ diff --git a/docker/templates/shared/rhasspy_code.txt b/docker/templates/shared/rhasspy_code.txt deleted file mode 100755 index a49724e..0000000 --- a/docker/templates/shared/rhasspy_code.txt +++ /dev/null @@ -1,10 +0,0 @@ -COPY profiles/defaults.json ${RHASSPY_APP}/profiles/ -COPY docker/rhasspy ${RHASSPY_APP}/bin/ -COPY dist/ ${RHASSPY_APP}/dist/ -COPY etc/wav/* ${RHASSPY_APP}/etc/wav/ -COPY rhasspy/profile_schema.json ${RHASSPY_APP}/rhasspy/ -COPY rhasspy/train/jsgf2fst/*.py ${RHASSPY_APP}/rhasspy/train/jsgf2fst/ -COPY rhasspy/train/*.py ${RHASSPY_APP}/rhasspy/train/ -COPY *.py ${RHASSPY_APP}/ -COPY rhasspy/*.py ${RHASSPY_APP}/rhasspy/ -COPY VERSION ${RHASSPY_APP}/ diff --git a/docker/templates/shared/snowboy.txt b/docker/templates/shared/snowboy.txt deleted file mode 100755 index c278307..0000000 --- a/docker/templates/shared/snowboy.txt +++ /dev/null @@ -1,3 +0,0 @@ -# Install snowboy -COPY download/snowboy-1.3.0.tar.gz / -RUN if [ "$BUILD_ARCH" != "aarch64" ]; then pip3 install --no-cache-dir /snowboy-1.3.0.tar.gz; fi diff --git a/docker/templates/shared/tts.txt b/docker/templates/shared/tts.txt deleted file mode 100644 index f161f78..0000000 --- a/docker/templates/shared/tts.txt +++ /dev/null @@ -1 +0,0 @@ -RUN apt-get install --no-install-recommends --yes flite libttspico-utils lame diff --git a/requirements.txt b/requirements.txt index e58851e..4983729 100755 --- a/requirements.txt +++ b/requirements.txt @@ -1,4 +1,3 @@ -attrs adapt-parser==0.3.4 aiohttp==3.6.2 doit==0.31.1