forked from pywren/pywren
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
88 lines (81 loc) · 4.18 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
language: python
sudo: required
# https://docs.travis-ci.com/user/ci-environment/ to get a modern gcc etc
dist: xenial
# notes from http://conda.pydata.org/docs/travis.html
python:
- "2.7"
- "3.5"
- "3.6"
- "3.7"
install:
# We do this conditionally because it saves us some downloading if the
# version is the same.
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then
wget https://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh -O miniconda.sh;
export RANDOM_ID=`python -c "from random import choice; print ''.join([choice('1234567890') for i in range(6)])"`;
else
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
export RANDOM_ID=`python -c "from random import choice; print(''.join([choice('1234567890') for i in range(6)]))"`;
fi
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- printenv TRAVIS_PULL_REQUEST
- printenv TRAVIS_PULL_REQUEST_BRANCH
- printenv TRAVIS_COMMIT
- printenv TRAVIS_BRANCH
- printenv
- hash -r
- conda config --set always_yes yes --set changeps1 no
- conda update -q conda
# Useful for debugging any issues with conda
- conda info -a
- conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION numpy pytest cython nose boto3 PyYAML Click pytest numba
- source activate test-environment
- pip install glob2 pylint tornado awscli pylint
- tests/install_pywren.sh
- tests/run_pylint.sh
before_script:
- export EPOCH_STAMP=`date +%s`
- export BUILD_GUID=`echo $TRAVIS_JOB_NUMBER | sed 's/\./_/g'`_${EPOCH_STAMP}_${RANDOM_ID}
- echo CLEAN BUILD ID IS $BUILD_GUID
- export BUCKET_NAME=`echo pywren_travis_$BUILD_GUID | sed 's/_/-/g'`
- echo $BUCKET_NAME
- pywren test_config
- pywren get_aws_account_id
script:
- pywren create_config --lambda_role=pywren_travis_test_$BUILD_GUID --function_name=pywren_travis_$BUILD_GUID --bucket_name=$BUCKET_NAME --sqs_queue=pywren_travis_$BUILD_GUID --standalone_name=pywren_travis_$BUILD_GUID
- pywren create_role
- pywren create_bucket
- pywren create_instance_profile
- pywren create_queue
- sleep 10
- pywren deploy_lambda
- tests/lambda_tests.sh
- tests/ec2_standalone_tests.sh
- tests/ec2_macroreduce_tests.sh
- tests/cmdline_tests.sh
after_script:
# always make sure we do this cleanup if we can
- pywren delete_queue
- pywren delete_lambda
- pywren delete_instance_profile
- pywren delete_role
- pywren delete_bucket
- pywren standalone terminate_instances
after_failure:
- pywren delete_queue
- pywren delete_lambda
- pywren delete_instance_profile
- pywren delete_role
- pywren delete_bucket
- pywren standalone terminate_instances
env:
global:
- secure: "NXt+Ni70refb3MsomErOP9Arnw0C/SkCBIkwmZ4jEB6pTaZzonwjSlssE8fLnIkt3lAba45VcVgPAnqy85AqrUQ1KD9zZuE/R0+3W/qk10i3HJggKQuIVj3vnHn5WvLZw0G/9XHme1E3TE3XjutzzqyY3BKU8k1itogqLLO3UX4E6DoX4TgicQbt2YfODySFC9Jyi97anRoeIt245FXjt1JYRaRbaagFcsPMS5SHsqQno2oTCPi/CPD2txbyBRH2MhmezmwQOVsrsBOVIV97VIFJbdA4liJbFTZurYPFM3xApuZIhq+c4kdX7a1Fef4rrL+tpdW3RIx0qIY7q2XLZU5O8/WvAG/IBKXbEYDDEpoDXGcuIkYvS8VtNN9eBGbFLoGX+hEGNhgdiyPCZRv+ICCcXccIjsC13iXP35chzVy7MXkOdDNypZxa5dv0P3RZujfznj4GGWFoNWiX8YvgezL2QYZFJBbw+1vRL3TUOVeRvYlomd54KDVELsMXJ6KGsAKazyEFe+WP3cDOOxIwKXR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