woodpecker/Makefile

40 lines
1.1 KiB
Makefile
Raw Normal View History

2015-05-15 21:55:26 +00:00
.PHONY: dist
SHA := $(shell git rev-parse --short HEAD)
VERSION := 0.4.0-alpha
2014-02-07 10:10:01 +00:00
2015-09-02 23:52:59 +00:00
all: build
build:
go run make.go bindata build
2015-08-24 18:25:01 +00:00
# Execute the database test suite against mysql 5.5
#
# You can launch a mysql container locally for testing:
# docker run -rm -e MYSQL_ALLOW_EMPTY_PASSWORD=yes -e MYSQL_DATABASE=test -p 3306:3306 mysql:5.5
test_mysql:
mysql -P 3306 --protocol=tcp -u root -e 'create database if not exists test;'
TEST_DRIVER="mysql" TEST_DATASOURCE="root@tcp(127.0.0.1:3306)/test" go test -short github.com/drone/drone/pkg/store/builtin
mysql -P 3306 --protocol=tcp -u root -e 'drop database test;'
2015-05-24 01:52:04 +00:00
run:
bin/drone --debug
2015-05-18 02:25:53 +00:00
# installs the drone binaries into bin
install:
install -t /usr/local/bin bin/drone
install -t /usr/local/bin bin/drone-agent
2015-08-19 19:38:08 +00:00
docker:
docker build --file=cmd/drone-build/Dockerfile.alpine --rm=true -t drone/drone-build .
2015-05-15 21:55:26 +00:00
# creates a debian package for drone
# to install `sudo dpkg -i drone.deb`
dist:
mkdir -p dist/drone/usr/local/bin
mkdir -p dist/drone/var/lib/drone
mkdir -p dist/drone/var/cache/drone
cp bin/drone dist/drone/usr/local/bin
-dpkg-deb --build dist/drone