-
-
Notifications
You must be signed in to change notification settings - Fork 137
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v1.6.3 Merge
- Loading branch information
Showing
9 changed files
with
159 additions
and
17 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,17 @@ | ||
sudo: true | ||
dist: xenial | ||
language: minimal | ||
services: | ||
- docker | ||
|
||
jobs: | ||
include: | ||
- stage: "Build and Push" | ||
script: | ||
- docker build -t boerderij/varken:$TRAVIS_BRANCH . | ||
- docker images | ||
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin | ||
- docker push boerderij/varken:$TRAVIS_BRANCH | ||
|
||
env: | ||
global: | ||
- secure: c91+zQXN28Anr2q94vhJAzN36teKovgniNmUI0MaejYfwcShN8TVeojkxbP+AxZuvGh1AfvB26LQeuPqAAntoNxvtPg3PLxv93rRSkAf0jk9apm9biYDAJNAM3OSiqCGfzfNhtUHmPmybRy2UmRXpHc6ZU1GmOdX2yyXCC2S6wjJOGabRpCA2Lw1vNnQuSJMDZ78amybZNmqAkK+rxe9hH2TGwcSImW8dlW2Ryt8H4a2s9VW9rbebQF+PzY4pw+OlIarpVUXZzUyEq8PS2EmJTuhrNA+RtZWJ4yRZ33jK4UqZRJzfC4FniZzSqtV/P3YGgSFNzhM87y5VhNiauX6QmtIDfLUV6c86cWCy24O41SrAJQOi4CLszJVkYfyggVFoRFegNS2+njN+f2Bbbx3rHtmNds0cDSfFuK3XhtTe0EhNgHLXOCX4IyAGzYWO+afmbqm/8S+m/QjCT28+0GgxYSqD2qO3FuPRA7woWucrKl2xa/tYikkurkDif0yBHxPac8mB8KLPLrjGzHlBG6SYYpTlpjWJrddbYhm0EZVmMkkFHRHLcOK8AOHKQipQBHmP+wvTGouwaZ8Uv5+uDNZ76st4BZR1tfXCtZ6A0RLRspo0wJ5EKlrNr8OIQGdj1G4TJ0H029mycqkAQ5yFPlvF/wAZ0shVFb/uMejpQw+2ks= | ||
addons: | ||
apt: | ||
packages: | ||
- docker-ce | ||
branches: | ||
only: | ||
- master | ||
deploy: | ||
- provider: script | ||
script: bash deploy.sh | ||
on: | ||
branch: master |
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,21 @@ | ||
FROM arm32v6/python:3.7.2-alpine | ||
|
||
LABEL maintainers="dirtycajunrice,samwiseg0" | ||
|
||
ENV DEBUG="False" | ||
|
||
COPY / /app | ||
|
||
COPY /tmp/qemu-arm-static /usr/bin/qemu-arm-static | ||
|
||
RUN \ | ||
python3 -m pip install -r /app/requirements.txt && \ | ||
chown -R abc:abc \ | ||
/config \ | ||
/app | ||
|
||
WORKDIR /app | ||
|
||
CMD cp /app/data/varken.example.ini /config/varken.example.ini && python3 /app/Varken.py --data-folder /config | ||
|
||
VOLUME /config |
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,21 @@ | ||
FROM arm64v8/python:3.7.2-alpine | ||
|
||
LABEL maintainers="dirtycajunrice,samwiseg0" | ||
|
||
ENV DEBUG="False" | ||
|
||
COPY / /app | ||
|
||
COPY /tmp/qemu-arm-static /usr/bin/qemu-arm-static | ||
|
||
RUN \ | ||
python3 -m pip install -r /app/requirements.txt && \ | ||
chown -R abc:abc \ | ||
/config \ | ||
/app | ||
|
||
WORKDIR /app | ||
|
||
CMD cp /app/data/varken.example.ini /config/varken.example.ini && python3 /app/Varken.py --data-folder /config | ||
|
||
VOLUME /config |
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,21 @@ | ||
FROM arm32v7/python:3.7.2-slim | ||
|
||
LABEL maintainers="dirtycajunrice,samwiseg0" | ||
|
||
ENV DEBUG="False" | ||
|
||
COPY / /app | ||
|
||
COPY /tmp/qemu-arm-static /usr/bin/qemu-arm-static | ||
|
||
RUN \ | ||
python3 -m pip install -r /app/requirements.txt && \ | ||
chown -R abc:abc \ | ||
/config \ | ||
/app | ||
|
||
WORKDIR /app | ||
|
||
CMD cp /app/data/varken.example.ini /config/varken.example.ini && python3 /app/Varken.py --data-folder /config | ||
|
||
VOLUME /config |
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,54 @@ | ||
#!/usr/bin/env bash | ||
VERSION="$(grep -i version varken.__init__.py | cut -d' ' -f3 | tr -d \")" | ||
|
||
# Docker | ||
GITHUB_USER='dirtycajunrice' | ||
DOCKER_USER='dirtycajunrice' | ||
PROJECT='varken' | ||
NAMESPACE="boerderij/${PROJECT}" | ||
|
||
# Docker experimental config | ||
echo '{"experimental":true}' | sudo tee /etc/docker/daemon.json | ||
[[ -d ~/.docker ]] || mkdir ~/.docker | ||
[[ -f ~/.docker/config.json ]] || touch ~/.docker/config.json | ||
echo '{"experimental":"enabled"}' | sudo tee ~/.docker/config.json | ||
sudo service docker restart | ||
|
||
# Auth | ||
echo "$DOCKER_PASSWORD" | docker login -u="$DOCKER_USER" --password-stdin | ||
|
||
# Latest x64 | ||
docker build -t "${NAMESPACE}:latest" . && \ | ||
docker push "${NAMESPACE}:latest" && \ | ||
# Versioned x64 | ||
docker tag "${NAMESPACE}:latest" "${NAMESPACE}:${VERSION}" && \ | ||
docker push "${NAMESPACE}:${VERSION}" && \ | ||
# x64 Arch | ||
docker tag "${NAMESPACE}:latest" "${NAMESPACE}:latest-amd64" && \ | ||
docker push "${NAMESPACE}:latest-amd64" | ||
|
||
# Prepare qemu for ARM builds | ||
docker run --rm --privileged multiarch/qemu-user-static:register --reset | ||
wget -P tmp/ "https://github.com/multiarch/qemu-user-static/releases/download/v3.1.0-2/qemu-aarch64-static" | ||
wget -P tmp/ "https://github.com/multiarch/qemu-user-static/releases/download/v3.1.0-2/qemu-arm-static" | ||
chmod +x tmp/qemu-aarch64-static tmp/qemu-arm-static | ||
|
||
# ARM images | ||
for i in $(ls *arm*); do | ||
arch="$(echo ${i} | cut -d. -f2)" | ||
# Latest | ||
docker build -f "./Dockerfile.${arch}" -t "${NAMESPACE}:latest-${arch}" . && \ | ||
docker push "${NAMESPACE}:latest-${arch}" && \ | ||
# Versioned | ||
docker tag "${NAMESPACE}:latest-${arch}" "${NAMESPACE}:${VERSION}-${arch}" && \ | ||
docker push "${NAMESPACE}:${VERSION}-${arch}" | ||
done | ||
|
||
wget -O manifest-tool https://github.com/estesp/manifest-tool/releases/download/v0.9.0/manifest-tool-linux-amd64 && \ | ||
chmod +x manifest-tool && \ | ||
python3 manifest_generator.py && \ | ||
./manifest-tool --username "$DOCKER_USER" --password "$DOCKER_PASSWORD" push from-spec ".manifest.yaml" | ||
# Git tags | ||
git remote set-url origin "https://${GITHUB_USER}:${GITHUB_API_KEY}@github.com/${NAMESPACE}.git" && \ | ||
git tag "${VERSION}" && \ | ||
git push --tags |
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 |
---|---|---|
@@ -1,2 +1,2 @@ | ||
VERSION = "1.6.2" | ||
VERSION = "1.6.3" | ||
BRANCH = 'master' |
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