Skip to content

Update .travis.yml #3745

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
Apr 26, 2019
7 changes: 4 additions & 3 deletions .scripts/docker_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@

set -ev

docker build -t apinf/platform:$DOCKER_TAG .

if [ "${TRAVIS_PULL_REQUEST}" = "false" -a "${TRAVIS_REPO_SLUG}" = "apinf/platform" ]
then
docker build -t apinf/platform:$DOCKER_TAG .
docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
docker push apinf/platform:$DOCKER_TAG
docker login -u="$DOCKER_USERNAME" -p="$DOCKER_PASSWORD"
docker push apinf/platform:$DOCKER_TAG
fi
31 changes: 10 additions & 21 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,10 @@
sudo: false

group: deprecated-2017Q4
dist: xenial

language: node_js
node_js:
- '8'

addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- g++-4.8
addons:
chrome: stable

branches:
Expand All @@ -21,40 +14,36 @@ branches:
before_cache:
- rm -f $HOME/.meteor/log/*.log

cache:
yarn: true
directories:
- $HOME/.meteor

services:
- docker
- xvfb

before_install:
- ls -la
- sudo apt-get update
- sudo apt-get install g++ build-essential xvfb

# Install meteor locally on CI
- if [ ! -e "$HOME/.meteor/meteor" ]; then cat .travis_install_meteor | sed s/--progress-bar/-sL/g | /bin/sh; fi


before_script:
#Previously used yarn, but now after migrating to meteor 1.8, yarn fails to create some binaries.
- meteor npm install
- yarn run lint
- npm run lint
- npm view chimp version
- npm view chromedriver version
# Start X Virtual Frame Buffer for headless testing with real browsers
- ./.scripts/start-xvfb.sh


install:
- export PATH="$HOME/.meteor:$PATH"

script:
# Run meteor and chimp from node.js
- travis_retry yarn test
- travis_retry npm run test
# Build docker image
- ./.scripts/docker_build.sh

env:
global:
- DISPLAY=:99.0
- TEST_MODE: "true"
- CXX=g++-4.8
- TEST_MODE: "true"
4 changes: 3 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# A base Docker image for Meteor applications. https://hub.docker.com/r/jshimko/meteor-launchpad/
FROM jshimko/meteor-launchpad:latest
#FROM jshimko/meteor-launchpad:latest - jessie deps
#FROM abernix/meteord:onbuild - is not starting
FROM pixolution/meteor-launchpad:v2.3.1
# the version (that bit after :) is dependent somehow on meteor versions. it used to be 1.1.1 but now as we go for Meteor 1.8, let's use latest.
# If you get in trouble with starting Meteor, this might be something to look at
MAINTAINER apinf <info@apinf.io>