| sudo: required |
| |
| matrix: |
| include: |
| - dist: trusty |
| language: python |
| python: 2.7 |
| services: |
| - docker |
| script: |
| - docker pull apacherocketmq/rocketmq-client-python-ci:latest |
| - docker run --rm -it -v `pwd`:/io -w /io apacherocketmq/rocketmq-client-python-ci:latest /io/manylinux.sh |
| - ls dist/ |
| - sudo rm -rf build *.egg-info |
| - pip install -Ur dev-requirements.txt |
| - pip install -e . |
| - pytest --cov=rocketmq -v tests |
| - pip install codecov && codecov |
| # Try to install binary wheel |
| - pip install --force-reinstall dist/*.whl |
| - dist: trusty |
| language: python |
| python: 3.6 |
| services: |
| - docker |
| script: |
| - docker pull apacherocketmq/rocketmq-client-python-ci:latest |
| - docker run --rm -it -v `pwd`:/io -w /io apacherocketmq/rocketmq-client-python-ci:latest /io/manylinux.sh |
| - ls dist/ |
| - sudo rm -rf build *.egg-info |
| - pip install -Ur dev-requirements.txt |
| - pip install -e . |
| - pytest --cov=rocketmq -v tests |
| - pip install codecov && codecov |
| # Try to install binary wheel |
| - pip install --force-reinstall dist/*.whl |
| # Build source distribution |
| - if [[ "${TRAVIS_TAG:-}" != "" ]]; then sudo python setup.py sdist; fi |
| |
| before_script: |
| - if [ "$TRAVIS_OS_NAME" == "osx" ]; then export JAVA_HOME=$(/usr/libexec/java_home); fi |
| - wget http://us.mirrors.quenda.co/apache/rocketmq/4.5.2/rocketmq-all-4.5.2-bin-release.zip |
| - unzip rocketmq-all-4.5.2-bin-release.zip |
| - cd rocketmq-all-4.5.2-bin-release |
| - perl -i -pe's/-Xms8g -Xmx8g -Xmn4g/-Xms2g -Xmx2g -Xmn1g/g' bin/runbroker.sh |
| - nohup sh bin/mqnamesrv & |
| - nohup sh bin/mqbroker -n localhost:9876 & |
| - sleep 10 |
| - ./bin/mqadmin updateTopic -b '127.0.0.1:10911' –n '127.0.0.1:9876' -t test |
| - ./bin/mqadmin updateSubGroup -b '127.0.0.1:10911' –n '127.0.0.1:9876' -g testGroup |
| - cd .. |
| |
| after_failure: |
| - cat ~/logs/rocketmq-cpp/*.log.* |
| |
| after_success: |
| - | |
| if [[ "${TRAVIS_TAG:-}" != "" && $TRAVIS_PYTHON_VERSION != "2.7" ]]; then |
| sudo python -m pip install -U twine; |
| twine upload --skip-existing dist/*; |
| fi |