-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from elodina/travis
Travis build
- Loading branch information
Showing
1 changed file
with
45 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
language: go | ||
go: | ||
- 1.3 | ||
- 1.4 | ||
- 1.5 | ||
- 1.6 | ||
- tip | ||
|
||
before_install: | ||
- export KAFKA_VERSION=0.8.2.1 | ||
- export SCALA_VERSION=2.10 | ||
- export KAFKA_RELEASE=kafka_$SCALA_VERSION-$KAFKA_VERSION | ||
- export KAFKA_URL=https://archive.apache.org/dist/kafka/$KAFKA_VERSION/$KAFKA_RELEASE.tgz | ||
- export KAFKA_PATH=/tmp/$KAFKA_RELEASE | ||
- export BROKER_ID=1 | ||
- export HOST_IP=localhost | ||
- export PORT=9092 | ||
- export ZK_VERSION=3.4.6 | ||
- export ZK_RELEASE=zookeeper-$ZK_VERSION | ||
- export ZK_URL=https://archive.apache.org/dist/zookeeper/zookeeper-$ZK_VERSION/$ZK_RELEASE.tar.gz | ||
- export ZK_HOME=/tmp/$ZK_RELEASE | ||
- export REGISTRY_VERSION=1.0 | ||
- export SCALA_VERSION=2.10.4 | ||
- export REGISTRY_URL=http://packages.confluent.io/archive/$REGISTRY_VERSION/confluent-$REGISTRY_VERSION-$SCALA_VERSION.tar.gz | ||
- export REGISTRY_HOME=/tmp/confluent-$REGISTRY_VERSION | ||
- export GOMAXPROCS=1 | ||
- wget -q $KAFKA_URL -O /tmp/$KAFKA_RELEASE.tgz | ||
- tar xfz /tmp/$KAFKA_RELEASE.tgz -C /tmp | ||
- wget -q $ZK_URL -O /tmp/$ZK_RELEASE.tar.gz | ||
- tar -xzf /tmp/$ZK_RELEASE.tar.gz -C /tmp | ||
- cp $ZK_HOME/conf/zoo_sample.cfg $ZK_HOME/conf/zoo.cfg | ||
- wget -q $REGISTRY_URL -O /tmp/confluent-$REGISTRY_VERSION-$SCALA_VERSION.tgz | ||
- tar xfz /tmp/confluent-$REGISTRY_VERSION-$SCALA_VERSION.tgz -C /tmp | ||
- $ZK_HOME/bin/zkServer.sh start | ||
- sed -r -i "s/(zookeeper.connect)=(.*)/\\1=$ZK_PORT_2181_TCP_ADDR/g" $KAFKA_PATH/config/server.properties | ||
- sed -r -i "s/(broker.id)=(.*)/\\1=$BROKER_ID/g" $KAFKA_PATH/config/server.properties | ||
- sed -r -i "s/#(advertised.host.name)=(.*)/\\1=$HOST_IP/g" $KAFKA_PATH/config/server.properties | ||
- sed -r -i "s/^(port)=(.*)/\\1=$PORT/g" $KAFKA_PATH/config/server.properties | ||
- sed -r -i "s/^(log4j.rootLogger)=(.*)( stdout)/\\1=WARN\\3/g" $KAFKA_PATH/config/log4j.properties | ||
- $KAFKA_PATH/bin/kafka-server-start.sh $KAFKA_PATH/config/server.properties & | ||
- $REGISTRY_HOME/bin/schema-registry-start $REGISTRY_HOME/etc/schema-registry/schema-registry.properties & | ||
- sleep 15 | ||
|
||
script: | ||
- go test -v -race |