etcher/.travis.yml
Juan Cruz Viotti 76b6bdfd06 chore: cache ~/.pkg-cache in Travis CI and Appveyor CI (#1598)
Looks like pkg downloads node binaries from GitHub Releases, and GitHub
may impose a rate limiting if we download too many things from them in a
short period of time (likely to happen when there are many concurrent
PRs).

In order to mitigate this issue, this commit adds `$HOME/.pkg-cache`,
the directory where pkg stores node binaries, to the CI services cache.

See: https://github.com/resin-io/etcher/pull/1594
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
2017-07-14 11:48:45 -04:00

82 lines
1.5 KiB
YAML

language: node_js
sudo: false
node_js:
- "6.10.3"
# Remove wine from cache
before_cache:
- rm -rf $HOME/.cache/electron-builder/wine
cache:
ccache: true
directories:
- $HOME/.cache/electron
- $HOME/.cache/electron-builder
- $HOME/.npm/_prebuilds
- $HOME/Library/Caches/electron
- $HOME/Library/Caches/electron-builder
- $HOME/.pkg-cache
- node_modules
services:
- docker
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- libstdc++-6-dev
env:
global:
- CCACHE_TEMPDIR=/tmp/.ccache-temp
- CCACHE_COMPRESS=1
- CC="clang"
- CXX="clang++"
- HOMEBREW_NO_AUTO_UPDATE=1
matrix:
- TARGET_ARCH=x64
- TARGET_ARCH=x86
matrix:
fast_finish: true
exclude:
- os: osx
env: TARGET_ARCH=x86
os:
- linux
- osx
before_install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then PATH=/usr/local/opt/ccache/libexec:$PATH; fi
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
export HOST_OS="darwin";
else
export HOST_OS="$TRAVIS_OS_NAME";
fi
install:
- travis_wait ./scripts/ci/install.sh -o $HOST_OS -r $TARGET_ARCH
script:
- ./scripts/ci/test.sh -o $HOST_OS -r $TARGET_ARCH
- ./scripts/ci/build-installers.sh -o $HOST_OS -r $TARGET_ARCH
deploy:
provider: script
skip_cleanup: true
script: scripts/ci/deploy-aws-s3.sh -o $HOST_OS -r $TARGET_ARCH
on:
branch: master
notifications:
email: false
webhooks:
urls:
- https://webhooks.gitter.im/e/0a019c8b9828eb9f6a72
on_success: change
on_failure: always
on_start: never