Re-arrange repo files for root dir cleanup
This commit is contained in:
parent
a9b97c7a2b
commit
a7ed46160a
|
@ -151,10 +151,12 @@ To execute Telegraf tests follow these simple steps:
|
||||||
|
|
||||||
- Install docker compose following [these](https://docs.docker.com/compose/install/)
|
- Install docker compose following [these](https://docs.docker.com/compose/install/)
|
||||||
instructions
|
instructions
|
||||||
- mac users should be able to simply do `brew install boot2docker`
|
|
||||||
and `brew install docker-compose`
|
|
||||||
- execute `make test`
|
- execute `make test`
|
||||||
|
|
||||||
|
**OSX users**: you will need to install `boot2docker` or `docker-machine`.
|
||||||
|
The Makefile will assume that you have a `docker-machine` box called `default` to
|
||||||
|
get the IP address.
|
||||||
|
|
||||||
### Unit test troubleshooting
|
### Unit test troubleshooting
|
||||||
|
|
||||||
Try cleaning up your test environment by executing `make test-cleanup` and
|
Try cleaning up your test environment by executing `make test-cleanup` and
|
||||||
|
|
7
Makefile
7
Makefile
|
@ -22,10 +22,11 @@ prepare:
|
||||||
|
|
||||||
docker-compose:
|
docker-compose:
|
||||||
ifeq ($(UNAME), Darwin)
|
ifeq ($(UNAME), Darwin)
|
||||||
ADVERTISED_HOST=$(shell sh -c 'boot2docker ip') docker-compose up -d
|
ADVERTISED_HOST=$(shell sh -c 'boot2docker ip || docker-machine ip default') \
|
||||||
|
docker-compose --file scripts/docker-compose.yml up -d
|
||||||
endif
|
endif
|
||||||
ifeq ($(UNAME), Linux)
|
ifeq ($(UNAME), Linux)
|
||||||
ADVERTISED_HOST=localhost docker-compose up -d
|
ADVERTISED_HOST=localhost docker-compose --file scripts/docker-compose.yml up -d
|
||||||
endif
|
endif
|
||||||
|
|
||||||
test: prepare docker-compose
|
test: prepare docker-compose
|
||||||
|
@ -35,6 +36,6 @@ test-short: prepare
|
||||||
$(GOPATH)/bin/godep go test -short ./...
|
$(GOPATH)/bin/godep go test -short ./...
|
||||||
|
|
||||||
test-cleanup:
|
test-cleanup:
|
||||||
docker-compose kill
|
docker-compose --file scripts/docker-compose.yml kill
|
||||||
|
|
||||||
.PHONY: test
|
.PHONY: test
|
||||||
|
|
|
@ -4,5 +4,5 @@ dependencies:
|
||||||
|
|
||||||
test:
|
test:
|
||||||
override:
|
override:
|
||||||
- bash circle-test.sh
|
- bash scripts/circle-test.sh
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ VAGRANTFILE_API_VERSION = "2"
|
||||||
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
|
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
|
||||||
|
|
||||||
config.vm.box = "ubuntu/trusty64"
|
config.vm.box = "ubuntu/trusty64"
|
||||||
config.vm.synced_folder ".", "/home/vagrant/go/src/github.com/influxdb/telegraf",
|
config.vm.synced_folder "..", "/home/vagrant/go/src/github.com/influxdb/telegraf",
|
||||||
type: "rsync",
|
type: "rsync",
|
||||||
rsync__args: ["--verbose", "--archive", "--delete", "-z", "--safe-links"],
|
rsync__args: ["--verbose", "--archive", "--delete", "-z", "--safe-links"],
|
||||||
rsync__exclude: ["./telegraf", ".vagrant/"]
|
rsync__exclude: ["./telegraf", ".vagrant/"]
|
|
@ -204,7 +204,7 @@ if [ "$1" == "-h" ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
VERSION=`git describe --always --tags | tr -d v`
|
VERSION=`git describe --always --tags | tr -d v`
|
||||||
|
cd `git rev-parse --show-toplevel`
|
||||||
echo -e "\nStarting package process, version: $VERSION\n"
|
echo -e "\nStarting package process, version: $VERSION\n"
|
||||||
|
|
||||||
if [ "$CIRCLE_BRANCH" == "" ]; then
|
if [ "$CIRCLE_BRANCH" == "" ]; then
|
Loading…
Reference in New Issue