should build now!
This commit is contained in:
parent
f98f22d9cc
commit
d33f093ab5
@ -3,7 +3,7 @@ FROM golang:1.13 as builder
|
||||
WORKDIR /go/src/github.com/sneak/feta
|
||||
COPY . .
|
||||
|
||||
RUN go get -v && make build
|
||||
RUN make build
|
||||
|
||||
WORKDIR /go
|
||||
RUN tar cvfz go-src.tgz src && du -sh *
|
||||
|
15
Makefile
15
Makefile
@ -34,11 +34,15 @@ run: build
|
||||
./$(FN)
|
||||
|
||||
clean:
|
||||
rm ./$(FN)
|
||||
-rm ./$(FN)
|
||||
|
||||
build: ./$(FN)
|
||||
|
||||
./$(FN): *.go cmd/*/*.go
|
||||
go-get:
|
||||
go get -v
|
||||
cd cmd/$(FN) && go get -v
|
||||
|
||||
./$(FN): *.go cmd/*/*.go go-get
|
||||
cd cmd/$(FN) && go build -o ../../$(FN) $(GOFLAGS) .
|
||||
|
||||
fmt:
|
||||
@ -49,7 +53,10 @@ test: build-docker-image
|
||||
is_uncommitted:
|
||||
git diff --exit-code >/dev/null 2>&1
|
||||
|
||||
build-docker-image: is_uncommitted clean
|
||||
build-docker-image: clean
|
||||
docker build -t $(IMAGENAME) .
|
||||
|
||||
build-docker-image-dist: is_uncommitted clean
|
||||
docker build -t $(IMAGENAME):$(VERSION) -t $(IMAGENAME):latest -t $(IMAGENAME):$(BUILDTIMETAG) .
|
||||
|
||||
dist: build-docker-image
|
||||
@ -64,4 +71,4 @@ upload-docker-image: build-docker-image
|
||||
docker push $(IMAGENAME):$(BUILDTIMETAG)
|
||||
docker push $(IMAGENAME):latest
|
||||
|
||||
.PHONY: build fmt test is_uncommitted build-docker-image dist hub upload-docker-image clean run rundebug default
|
||||
.PHONY: build fmt test is_uncommitted build-docker-image dist hub upload-docker-image clean run rundebug default build-docker-image-dist
|
||||
|
Loading…
Reference in New Issue
Block a user