Skip to content

Commit 462c5d9

Browse files
committed
switch travis to using docker
1 parent 0dcd2b5 commit 462c5d9

File tree

1 file changed

+5
-12
lines changed

1 file changed

+5
-12
lines changed

.travis.yml

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
language: python
22

3+
services:
4+
- docker
5+
36
python:
47
- "2.6"
58
- "2.7"
@@ -8,27 +11,17 @@ python:
811
- "3.6"
912
- "3.7"
1013

11-
addons:
12-
apt:
13-
packages:
14-
- oracle-java8-installer
15-
1614
env:
1715
# different connection classes to test
1816
- TEST_ES_CONNECTION=Urllib3HttpConnection
1917
- TEST_ES_CONNECTION=RequestsHttpConnection
2018

2119
before_install:
22-
- sudo update-java-alternatives -s java-8-oracle
23-
- export JAVA_HOME=/usr/lib/jvm/java-8-oracle/jre
24-
- java -version
20+
- docker run --rm --detach --publish 9200:9200 --env "discovery.type=single-node" -e path.repo=/tmp -e "repositories.url.allowed_urls=http://*" -e node.attr.testattr=test -e node.name=test --name elasticsearch docker.elastic.co/elasticsearch/elasticsearch:7.4.0
2521

2622
install:
27-
- curl -L -o /tmp/es-snap.zip https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-6.1.1.zip
28-
- unzip /tmp/es-snap.zip -d /tmp/
29-
- /tmp/elasticsearch-*/bin/elasticsearch -E path.repo=/tmp -E repositories.url.allowed_urls='http://*' -E node.attr.testattr=test -d
3023
- git clone https://github.com/elastic/elasticsearch.git ../elasticsearch
31-
- pip install .
24+
- pip install .[develop]
3225

3326
script:
3427
- python setup.py test

0 commit comments

Comments
 (0)