Skip to content

Commit

Permalink
Fix Makefile to work in CI.
Browse files Browse the repository at this point in the history
  • Loading branch information
lfittl committed Mar 22, 2016
1 parent 503308d commit 701b6d1
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
4 changes: 1 addition & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,7 @@ WORKDIR $CODE_DIR
# We run this all in one layer to reduce the resulting image size
RUN apk-install -t build-deps make curl libc-dev gcc go git tar \
&& curl -o /usr/local/bin/gosu -sSL "https://github.com/tianon/gosu/releases/download/1.6/gosu-amd64" \
&& go get -d \
&& make -C $GOPATH/src/github.com/lfittl/pg_query.go build \
&& go get \
&& make build \
&& go build -o $HOME_DIR/collector \
&& rm -rf $GOPATH \
&& apk del --purge build-deps
Expand Down
10 changes: 9 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
test:
default: build test

build:
go get -d
make -C ${GOPATH}/src/github.com/lfittl/pg_query_go build
go get
go build -o pganalyze-collector

test: build
go test -v ./ ./dbstats ./scheduler

.PHONY: test
2 changes: 1 addition & 1 deletion explain/explain.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"encoding/json"
"fmt"

pg_query "github.com/lfittl/pg_query.go"
pg_query "github.com/lfittl/pg_query_go"
"github.com/pganalyze/collector/util"
)

Expand Down

0 comments on commit 701b6d1

Please sign in to comment.