Commit a9d38e79 authored by David Trattnig's avatar David Trattnig
Browse files

Fixes for docker config.

parent bce5b55e
...@@ -78,9 +78,8 @@ python ...@@ -78,9 +78,8 @@ python
.noseids .noseids
# Configurations # Configurations
config/engine.ini config/engine.docker.ini
config/docker/engine.ini
env.list env.list
# Socket # Socket
src/liquidsoap/engine.sock socket/engine.sock
\ No newline at end of file \ No newline at end of file
...@@ -16,6 +16,7 @@ RUN mkdir -p /srv/src ...@@ -16,6 +16,7 @@ RUN mkdir -p /srv/src
RUN mkdir -p /srv/config RUN mkdir -p /srv/config
RUN /usr/local/bin/python -m pip install --upgrade pip RUN /usr/local/bin/python -m pip install --upgrade pip
COPY src /srv/src COPY src /srv/src
COPY config/sample-docker.engine.ini /srv/config/engine.ini
COPY requirements.txt /srv COPY requirements.txt /srv
COPY contrib/postgresql-requirements.txt /srv COPY contrib/postgresql-requirements.txt /srv
COPY meta.py /srv COPY meta.py /srv
......
...@@ -80,11 +80,11 @@ if [[ $docker == "true" ]]; then ...@@ -80,11 +80,11 @@ if [[ $docker == "true" ]]; then
if [[ $mode == "engine" ]]; then if [[ $mode == "engine" ]]; then
if [[ -z "${AURA_ENGINE_CONFIG_PATH}" ]]; then if [[ -z "${AURA_ENGINE_CONFIG_PATH}" ]]; then
AURA_ENGINE_CONFIG_PATH="$BASE_DIR/config/engine.docker.ini" AURA_ENGINE_CONFIG_PATH=$(readlink -f "${BASE_DIR}/config/engine.docker.ini")
fi fi
if [[ -z "${AURA_ENGINE_SOCKET_DIR}" ]]; then if [[ -z "${AURA_ENGINE_SOCKET_DIR}" ]]; then
AURA_ENGINE_SOCKET_DIR="$BASE_DIR/../engine-core/socket" AURA_ENGINE_SOCKET_DIR=$(readlink -f "${BASE_DIR}/../engine-core-quickstart/socket")
fi fi
if [[ -z "${AURA_ENGINE_CONTROL_CHANNEL}" ]]; then if [[ -z "${AURA_ENGINE_CONTROL_CHANNEL}" ]]; then
...@@ -92,20 +92,26 @@ if [[ $docker == "true" ]]; then ...@@ -92,20 +92,26 @@ if [[ $docker == "true" ]]; then
fi fi
if [[ -z "${AURA_ENGINE_AUDIO_SOURCE_DIR}" ]]; then if [[ -z "${AURA_ENGINE_AUDIO_SOURCE_DIR}" ]]; then
AURA_ENGINE_AUDIO_SOURCE_DIR="$BASE_DIR/audio/source" AURA_ENGINE_AUDIO_SOURCE_DIR=$(readlink -f "${BASE_DIR}/audio/source")
fi fi
if [[ -z "${AURA_ENGINE_AUDIO_PLAYLIST_DIR}" ]]; then if [[ -z "${AURA_ENGINE_AUDIO_PLAYLIST_DIR}" ]]; then
AURA_ENGINE_AUDIO_PLAYLIST_DIR="$BASE_DIR/audio/playlist" AURA_ENGINE_AUDIO_PLAYLIST_DIR=$(readlink -f "${BASE_DIR}/audio/playlist")
fi fi
echo AURA_ENGINE_CONFIG_PATH="$AURA_ENGINE_CONFIG_PATH"
echo AURA_ENGINE_SOCKET_DIR="$AURA_ENGINE_SOCKET_DIR"
echo AURA_ENGINE_CONTROL_CHANNEL="$AURA_ENGINE_CONTROL_CHANNEL"
echo AURA_ENGINE_AUDIO_SOURCE_DIR="$AURA_ENGINE_AUDIO_SOURCE_DIR"
echo AURA_ENGINE_AUDIO_PLAYLIST_DIR="$AURA_ENGINE_AUDIO_PLAYLIST_DIR"
exec sudo docker run \ exec sudo docker run \
--network="host" \ --network="host" \
--name aura-engine \ --name aura-engine \
--rm \ --rm \
-u $UID:$GID \ -u $UID:$GID \
-p $AURA_ENGINE_CONTROL_CHANNEL:1337/tcp \ -p "$AURA_ENGINE_CONTROL_CHANNEL":1337/tcp \
-v "$AURA_ENGINE_CONFIG_PATH":"/srv/config/engine.ini":ro \ -v "$AURA_ENGINE_CONFIG_PATH":"/srv/config/engine.ini" \
-v "$AURA_ENGINE_SOCKET_DIR":"/srv/socket" \ -v "$AURA_ENGINE_SOCKET_DIR":"/srv/socket" \
-v "$AURA_ENGINE_AUDIO_SOURCE_DIR":"/var/audio/source":ro \ -v "$AURA_ENGINE_AUDIO_SOURCE_DIR":"/var/audio/source":ro \
-v "$AURA_ENGINE_AUDIO_PLAYLIST_DIR":"/var/audio/playlist" \ -v "$AURA_ENGINE_AUDIO_PLAYLIST_DIR":"/var/audio/playlist" \
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment