Skip to content

Commit

Permalink
fix: remove obsolete makefile targets
Browse files Browse the repository at this point in the history
  • Loading branch information
aeneasr committed Oct 20, 2020
1 parent e946487 commit dc5d37f
Showing 1 changed file with 14 additions and 25 deletions.
39 changes: 14 additions & 25 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ lint: .bin/golangci-lint

# Runs full test suite including tests where databases are enabled
.PHONY: test-legacy-migrations
test-legacy-migrations: test-resetdb sqlbin
test-legacy-migrations: test-resetdb .bin/go-bindata
cd internal/fizzmigrate/client; go-bindata -o sql_migration_files.go -pkg client ./migrations/sql/...
cd internal/fizzmigrate/consent; go-bindata -o sql_migration_files.go -pkg consent ./migrations/sql/...
cd internal/fizzmigrate/jwk; go-bindata -o sql_migration_files.go -pkg jwk ./migrations/sql/...
cd internal/fizzmigrate/oauth2; go-bindata -o sql_migration_files.go -pkg oauth2 ./migrations/sql/...
source scripts/test-env.sh && go test -tags legacy_migration_test sqlite -failfast -timeout=20m ./internal/fizzmigrate
docker rm -f hydra_test_database_mysql
docker rm -f hydra_test_database_postgres
Expand Down Expand Up @@ -69,13 +73,8 @@ test-resetdb: node_modules

# Runs tests in short mode, without database adapters
.PHONY: docker
docker: .bin/packr2
packr2
GO111MODULE=on GOOS=linux GOARCH=amd64 go build -tags sqlite
packr2 clean
docker build -t oryd/hydra:latest .
docker build -f Dockerfile-alpine -t oryd/hydra:latest-alpine .
rm hydra
docker:
docker build -f .docker/Dockerfile-build -t oryd/hydra:latest-sqlite .

.PHONY: e2e
e2e: node_modules test-resetdb
Expand Down Expand Up @@ -105,18 +104,6 @@ format: .bin/goreturns node_modules
mocks: .bin/mockgen
mockgen -package oauth2_test -destination oauth2/oauth2_provider_mock_test.go github.com/ory/fosite OAuth2Provider

# Adds sql files to the binary using go-bindata
.PHONY: sqlbin
sqlbin: .bin/go-bindata
cd internal/fizzmigrate/client; go-bindata -o sql_migration_files.go -pkg client ./migrations/sql/...
cd internal/fizzmigrate/consent; go-bindata -o sql_migration_files.go -pkg consent ./migrations/sql/...
cd internal/fizzmigrate/jwk; go-bindata -o sql_migration_files.go -pkg jwk ./migrations/sql/...
cd internal/fizzmigrate/oauth2; go-bindata -o sql_migration_files.go -pkg oauth2 ./migrations/sql/...

# Runs all code generators
.PHONY: gen
gen: mocks sqlbin sdk

# Generates the SDKs
.PHONY: sdk
sdk: .bin/cli
Expand All @@ -129,12 +116,11 @@ sdk: .bin/cli
swagger generate client -f ./.schema/api.swagger.json -t internal/httpclient -A Ory_Hydra
make format


.PHONY: install-stable
install-stable: .bin/packr2
install-stable:
HYDRA_LATEST=$$(git describe --abbrev=0 --tags)
git checkout $$HYDRA_LATEST
packr2
make pack
GO111MODULE=on go install \
-tags sqlite \
-ldflags "-X github.com/ory/hydra/cmd.Version=$$HYDRA_LATEST -X github.com/ory/hydra/cmd.Date=`TZ=UTC date -u '+%Y-%m-%dT%H:%M:%SZ'` -X github.com/ory/hydra/cmd.Commit=`git rev-parse HEAD`" \
Expand All @@ -143,7 +129,10 @@ install-stable: .bin/packr2
git checkout master

.PHONY: install
install: .bin/packr2
packr2
install: pack
GO111MODULE=on go install -tags sqlite .
packr2 clean

.PHONY: pack
pack: .bin/packr2
packr2

0 comments on commit dc5d37f

Please sign in to comment.