Skip to content
Permalink
Browse files

fix CCACHE dir

  • Loading branch information
3nids committed Mar 5, 2019
1 parent 1e11e11 commit 943492e6758e0779c8253a31e759863356fd9526
Showing with 10 additions and 8 deletions.
  1. +4 −4 .ci/travis/docker_image/script.sh
  2. +1 −1 .docker/docker-compose.travis.yml
  3. +5 −3 .travis.yml
@@ -17,10 +17,10 @@

set -e

mkdir -p "CCACHE_DIR_IMAGE_BUILD"
mkdir -p "${CCACHE_DIR}"

# copy ccache dir within QGIS source so it can be accessed from docker
cp -r ${CCACHE_DIR_IMAGE_BUILD} ${TRAVIS_BUILD_DIR}/.ccache_image_build
cp -r ${CCACHE_DIR} ${TRAVIS_BUILD_DIR}/.ccache_image_build
# building docker images
DIR=$(git rev-parse --show-toplevel)/.docker
pushd "${DIR}"
@@ -33,10 +33,10 @@ echo "${bold}Pushing image to docker hub...${endbold}"
docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
docker push "qgis/qgis:${DOCKER_TAG}"
echo "Copy build cache from Docker container to Travis cache directory"
rm -rf "${CCACHE_DIR_IMAGE_BUILD:?}/"*
rm -rf "${CCACHE_DIR:?}/"*
container_id=$(docker images -q "qgis/qgis:${DOCKER_TAG}")
docker start ${container_id}
docker cp ${container_id}:/usr/src/QGIS/.ccache_image_build ${CCACHE_DIR_IMAGE_BUILD}
docker cp ${container_id}:/usr/src/QGIS/.ccache_image_build ${CCACHE_DIR}
popd
echo "Trigger build of PyQGIS Documentation"
body='{
@@ -16,7 +16,7 @@ services:
image: qgis/qgis3-build-deps:${DOCKER_TAG}
volumes:
- ${TRAVIS_BUILD_DIR}:/root/QGIS
- ${CCACHE_DIR_TESTING}:/root/.ccache # if changed, also change env var
- ${CCACHE_DIR}:/root/.ccache # if changed, also change env var
links:
- postgres
- mssql
@@ -8,15 +8,14 @@ cache:
pip: true
directories:
- ${HOME}/.ccache_testing
- ${HOME}/.ccache_docker_build
- ${HOME}/.ccache_docker_build_cosmic
- ${HOME}/.ccache_docker_build_bionic
timeout: 1000
if: NOT branch =~ /^(cherry-pick-)?backport-\d+-on-/

env:
global:
- TRAVIS_TIMESTAMP=$(date +%s)
- CCACHE_DIR_TESTING=${HOME}/.ccache_testing
- CCACHE_DIR_IMAGE_BUILD=${HOME}/.ccache_docker_build
# Docker hub username and passowrd
- secure: "b7eMDIolaAnq1voGKC1ez7Kcf+/A0WZDJEHBvNwk2KubBfrGOE83GMDrFNF4NqjIprqIAvVKj+TrX1ckCvs24re3IqUJo71TaF1IgxzDDPwSsmNh5UMmvZkeiJys9bWjqDO9wYR5ietNmIE18qyMc8ToJk8oKm6AXuAG2n6znmM="
- secure: "PHCp7F3nApp38Mz6b4/OLxgfBiikRGzPQDHg3R5LX+SQOll24c/DMtwpPwizNuFEiCFcRmJ9uc1t0HWEerIZe5uqm7AtE/nMXBsvDZ+hj4Tz/fEBF98a1k4WLYheN1exFidVkJgdAeiwMOOUQXw5KuIX62bxBdzsdcd0QGwxiXo="
@@ -42,6 +41,7 @@ matrix:
services: docker
env:
- TRAVIS_CONFIG=linux
- CCACHE_DIR=${HOME}/.ccache_testing
- DOCKER_TAG=$( [[ $TRAVIS_REPO_SLUG =~ qgis/QGIS ]] && echo $TRAVIS_BRANCH | sed 's/master/latest/' || echo "latest" )
- DOCKER_BUILD_DEPS_FILE=qgis3-build-deps.dockerfile

@@ -104,6 +104,7 @@ matrix:
services: docker
env:
- TRAVIS_CONFIG=docker_image
- CCACHE_DIR=${HOME}/.ccache_docker_build_bionic
- DOCKER_TAG=$( echo $TRAVIS_BRANCH | sed 's/master/latest/' )
- DOCKER_BUILD_DEPS_FILE=qgis3-build-deps.dockerfile

@@ -116,6 +117,7 @@ matrix:
services: docker
env:
- TRAVIS_CONFIG=docker_image
- CCACHE_DIR=${HOME}/.ccache_docker_build_cosmic
- DOCKER_TAG="$( echo $TRAVIS_BRANCH | sed 's/master/latest/' )_cosmic"
- DOCKER_BUILD_DEPS_FILE=qgis3-build-deps-cosmic.dockerfile

0 comments on commit 943492e

Please sign in to comment.
You can’t perform that action at this time.