-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
dfbc455
commit d5b0a38
Showing
5 changed files
with
49 additions
and
7 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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
language: python | ||
if: branch = master OR tag IS present | ||
python: 3.6 | ||
services: | ||
- docker | ||
|
||
before_script: | ||
- echo "$DOCKER_PASSWORD" | sudo docker login -u "$DOCKER_USERNAME" --password-stdin | ||
- echo "$QUAY_PASSWORD" | sudo docker login -u "$QUAY_USERNAME" --password-stdin quay.io | ||
|
||
jobs: | ||
include: | ||
- stage: Build recent x86_64 image | ||
script: make build ARCH=x86_64 GIT_TAG=${TRAVIS_TAG} PUSH=true | ||
|
||
- stage: Build recent ARM image | ||
script: make build ARCH=arm GIT_TAG=${TRAVIS_TAG} PUSH=true |
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,9 +1,21 @@ | ||
SUDO=sudo | ||
|
||
all: build build_arm | ||
|
||
build: | ||
${SUDO} docker build . -t wolnosciowiec/reverse-networking | ||
.SILENT: | ||
PUSH=true | ||
SUDO=sudo | ||
SHELL=/bin/bash | ||
QUAY_REPO=quay.io/riotkit/reverse-networking | ||
|
||
build_arm: | ||
${SUDO} docker build -f ./armhf.Dockerfile . -t wolnosciowiec/reverse-networking:armhf | ||
build: ## Build and push (args: PUSH, ARCH, GIT_TAG) | ||
set -e; DOCKER_TAG="latest-dev-${ARCH}"; \ | ||
\ | ||
if [[ "${GIT_TAG}" != '' ]]; then \ | ||
DOCKER_TAG=${GIT_TAG}-${ARCH}; \ | ||
fi; \ | ||
\ | ||
${SUDO} docker build . -f ./${ARCH}.Dockerfile -t ${QUAY_REPO}:$${DOCKER_TAG}; \ | ||
${SUDO} docker tag ${QUAY_REPO}:$${DOCKER_TAG} ${QUAY_REPO}:$${DOCKER_TAG}-$$(date '+%Y-%m-%d'); \ | ||
\ | ||
if [[ "${PUSH}" == "true" ]]; then \ | ||
${SUDO} docker push ${QUAY_REPO}:$${DOCKER_TAG}-$$(date '+%Y-%m-%d'); \ | ||
${SUDO} docker push ${QUAY_REPO}:$${DOCKER_TAG}; \ | ||
fi |
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
File renamed without changes.
File renamed without changes.