Merge pull request #11 from horjulf/develop

Add docker build by branch
pull/54/head
James 7 years ago committed by desimaniac
commit a929709aad

@ -1,23 +0,0 @@
# Git
.git
# Systemd files
systemd
# Logs
*.log*
# Configs
*.json
# Byte-compiled / optimized / DLL files
**/__pycache__
*.py[cod]
*$py.class
*.pyc
# Pyenv
**/.python-version
# User-specific stuff:
.idea

@ -0,0 +1,2 @@
# Hooks
hooks

@ -1,13 +1,12 @@
FROM python:3.6-alpine3.7
# Default branch to master
ARG BRANCH=master
ENV \
# App directory
APP_DIR=traktarr \
# Branch to clone
BRANCH=master \
# Config file
BRANCH=${BRANCH} \
TRAKTARR_CONFIG=/config/config.json \
# Log file
TRAKTARR_LOGFILE=/config/traktarr.log
RUN \
@ -15,7 +14,7 @@ RUN \
apk --no-cache -U upgrade && \
echo "** Install OS dependencies **" && \
apk --no-cache -U add git && \
echo "** Get Traktarr **" && \
echo "** Get Traktarr branch: ${BRANCH} **" && \
git clone --depth 1 --branch ${BRANCH} https://github.com/l3uddz/traktarr.git /${APP_DIR} && \
echo "** Install PIP dependencies **" && \
pip install --no-cache-dir --upgrade pip setuptools && \

@ -0,0 +1,3 @@
#!/bin/bash
docker build --build-arg BRANCH=${SOURCE_BRANCH} -f ${DOCKERFILE_PATH} -t ${IMAGE_NAME} .
Loading…
Cancel
Save