forked from subspacecloud/subspace
-
Notifications
You must be signed in to change notification settings - Fork 131
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Remove old dockerfiles to avoid confusion * Moving Dockerfiles to scripts directory * Add newline between badges and table of contents * Updating Makefile to output 'subspace' - Updating .gitignore for this too * remove '-linux-amd64' from binary name * Better layer caching and call 'make build' * reduce layer size by removing apt cache * Updating for new web/cmd directories * Call make build in Dockerfile * Fixing bindata removal * ADD: Multiple tags * Update multi-arch-manifest.yaml Co-authored-by: Adrián González Barbosa <[email protected]> Co-authored-by: jack1902 <[email protected]>
- Loading branch information
1 parent
7027ea8
commit 83ba088
Showing
11 changed files
with
84 additions
and
117 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
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -1,13 +1,22 @@ | ||
all: subspace | ||
.DEFAULT_GOAL := help | ||
.PHONY: help | ||
|
||
BUILD_VERSION?=unknown | ||
|
||
subspace: | ||
go run github.com/kevinburke/go-bindata/go-bindata -o cmd/subspace/bindata.go --prefix "web/" --pkg main web/... \ | ||
&& CGO_ENABLED=0 GOOS=linux GOARCH=amd64 \ | ||
go build -v --compiler gc --ldflags "-extldflags -static -s -w -X main.version=${BUILD_VERSION}" -o subspace ./cmd/subspace | ||
|
||
clean: | ||
rm -f subspace cmd/subspace/bindata.go | ||
help: ## Display this help message and exit | ||
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' | ||
|
||
build: clean ## Build the binary | ||
@echo "Creating bindata.go..." | ||
@go run github.com/kevinburke/go-bindata/go-bindata -o cmd/subspace/bindata.go --prefix "web/" --pkg main web/... | ||
@echo "+++ bindata.go created" | ||
|
||
.PHONY: clean | ||
@echo "Compiling subspace..." | ||
@CGO_ENABLED=0 \ | ||
go build -v --compiler gc --ldflags "-extldflags -static -s -w -X main.version=${BUILD_VERSION}" -o subspace ./cmd/subspace \ | ||
&& rm cmd/subspace/bindata.go | ||
@echo "+++ subspace compiled" | ||
|
||
clean: ## Remove old binaries | ||
rm -f subspace cmd/subspace/bindata.go |
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
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
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
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
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
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
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
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