Commit 55715963 authored by xa's avatar xa

better ci

parent b769893e
---
Prepare container:
stages:
- build
- test
- documentation
- release
prepare container:
stage: build
script:
- docker build -t errorist/aionsq:latest .
tags:
- docker-build
except:
- docs
Test:
tests:
stage: test
image: errorist/aionsq:latest
script:
- python -m pip install -e .
- python -m pip install -r requirements-test.txt
- py.test tests/ --cov aionsq --cov-report term-missing --flake8
- python -m pip install python-snappy
- py.test --cov aionsq --cov-report term-missing tests/
tags:
- python3.5
except:
- docs
pages:
stage: documentation
script:
- python -m pip install sphinx
- python -m pip install -r docs/requirements.txt
- sphinx-build -b html docs public
artifacts:
paths:
- public
only:
- master
- docs
tags:
- python3.5
FROM errorist/py:3.5
FROM hub.errorist.xyz/py:3.5
MAINTAINER Xavier Barbosa <clint.northwood@gmail.com>
ENV NSQ_VERSION=0.3.6
ENV GOLANG_VERSION=1.5.1
ENV NSQ_PACKAGE=nsq-${NSQ_VERSION}.linux-amd64.go${GOLANG_VERSION}
ENV NSQ_VERSION 0.3.7
RUN apk add --no-cache curl python3-dev snappy-dev tar
RUN mkdir -p /usr/local/bin
RUN curl -O https://s3.amazonaws.com/bitly-downloads/nsq/${NSQ_PACKAGE}.tar.gz
RUN tar zxvf ${NSQ_PACKAGE}.tar.gz -C /usr/local/bin --strip-components 2 --owner=0
RUN python -m pip install python-snappy
RUN apk add --no-cache snappy-dev
RUN curl -O https://s3.amazonaws.com/bitly-downloads/nsq/nsq-0.3.6.linux-amd64.go1.6.tar.gz \
&& tar zxvf nsq-${NSQ_VERSION}.linux-amd64.go1.6.tar.gz
ENV PATH=$PATH:$PWD/nsq-${NSQ_VERSION}.linux-amd64.go1.6/bin
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment