Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore!: cleanup unused cmd #6045

Open
wants to merge 5 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,6 @@ Session.vim
/cmd/*/.ethereum/
*.iml

# created for running container
_assets/compose/bootnode/keys

# do not vendor nested vendor/ dirs
vendor/**/vendor

Expand Down
27 changes: 0 additions & 27 deletions .travis.yml

This file was deleted.

36 changes: 0 additions & 36 deletions BOOTNODE.md

This file was deleted.

37 changes: 0 additions & 37 deletions CMakeLists.txt

This file was deleted.

75 changes: 0 additions & 75 deletions MAILSERVER.md

This file was deleted.

98 changes: 3 additions & 95 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.PHONY: statusgo statusd-prune all test clean help
.PHONY: statusgo all test clean help
.PHONY: statusgo-android statusgo-ios

# Clear any GOROOT set outside of the Nix shell
Expand Down Expand Up @@ -66,11 +66,7 @@ BUILD_FLAGS_MOBILE ?=
networkid ?= StatusChain

DOCKER_IMAGE_NAME ?= statusteam/status-go
BOOTNODE_IMAGE_NAME ?= statusteam/bootnode
STATUSD_PRUNE_IMAGE_NAME ?= statusteam/statusd-prune

DOCKER_IMAGE_CUSTOM_TAG ?= $(RELEASE_TAG)

DOCKER_TEST_WORKDIR = /go/src/github.com/status-im/status-go/
DOCKER_TEST_IMAGE = golang:1.13

Expand Down Expand Up @@ -145,23 +141,10 @@ $(GO_CMD_BUILDS): ##@build Build any Go project from cmd folder
echo "Compilation done." ;\
echo "Run \"build/bin/$(notdir $@) -h\" to view available commands."

bootnode: ##@build Build discovery v5 bootnode using status-go deps
bootnode: build/bin/bootnode

node-canary: ##@build Build P2P node canary using status-go deps
node-canary: generate
node-canary: build/bin/node-canary

statusgo: ##@build Build status-go as statusd server
statusgo: build/bin/statusd
statusd: statusgo

statusd-prune: ##@statusd-prune Build statusd-prune
statusd-prune: build/bin/statusd-prune

spiff-workflow: ##@build Build node for SpiffWorkflow BPMN software
spiff-workflow: build/bin/spiff-workflow

status-cli: ##@build Build status-cli to send messages
status-cli: build/bin/status-cli

Expand All @@ -173,15 +156,6 @@ run-status-backend: generate
run-status-backend: ##@run Start status-backend server listening to localhost:PORT
go run ./cmd/status-backend --address localhost:${PORT}

statusd-prune-docker-image: SHELL := /bin/sh
statusd-prune-docker-image: ##@statusd-prune Build statusd-prune docker image
@echo "Building docker image for ststusd-prune..."
docker build --file _assets/build/Dockerfile-prune . \
--label "commit=$(GIT_COMMIT)" \
--label "author=$(GIT_AUTHOR)" \
-t $(BOOTNODE_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG) \
-t $(STATUSD_PRUNE_IMAGE_NAME):latest

statusgo-cross: statusgo-android statusgo-ios
@echo "Full cross compilation done."
@ls -ld build/bin/statusgo-*
Expand Down Expand Up @@ -268,48 +242,10 @@ docker-image: ##@docker Build docker image (use DOCKER_IMAGE_NAME to set the ima
-t $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG) \
-t $(DOCKER_IMAGE_NAME):latest

bootnode-image: SHELL := /bin/sh
bootnode-image:
@echo "Building docker image for bootnode..."
docker build --file _assets/build/Dockerfile-bootnode . \
--build-arg 'build_tags=$(BUILD_TAGS)' \
--build-arg 'build_flags=$(BUILD_FLAGS)' \
--label 'commit=$(GIT_COMMIT)' \
--label 'author=$(GIT_AUTHOR)' \
-t $(BOOTNODE_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG) \
-t $(BOOTNODE_IMAGE_NAME):latest

push-docker-images: SHELL := /bin/sh
push-docker-images: docker-image bootnode-image
docker push $(BOOTNODE_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG)
docker push $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG)

clean-docker-images: SHELL := /bin/sh
clean-docker-images:
docker rmi -f $$(docker image ls --filter="reference=$(DOCKER_IMAGE_NAME)" --quiet)

# See https://www.gnu.org/software/make/manual/html_node/Target_002dspecific.html to understand this magic.
push-docker-images-latest: SHELL := /bin/sh
push-docker-images-latest: GIT_BRANCH = $(shell git rev-parse --abbrev-ref HEAD)
push-docker-images-latest: GIT_LOCAL = $(shell git rev-parse @)
push-docker-images-latest: GIT_REMOTE = $(shell git fetch -q && git rev-parse remotes/origin/develop || echo 'NO_DEVELOP')
push-docker-images-latest:
echo $(GIT_BRANCH)
echo $(GIT_LOCAL)
echo $(GIT_REMOTE)
@echo "Pushing latest docker images..."
@echo "Checking git branch..."
ifneq ("$(GIT_BRANCH)", "develop")
$(error You should only use develop branch to push the latest tag!)
exit 1
endif
ifneq ("$(GIT_LOCAL)", "$(GIT_REMOTE)")
$(error The local git commit does not match the remote origin!)
exit 1
endif
docker push $(BOOTNODE_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG)
docker push $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_CUSTOM_TAG)

setup: ##@setup Install all tools
setup: setup-dev

Expand Down Expand Up @@ -402,19 +338,15 @@ test-functional: export FUNCTIONAL_TESTS_REPORT_CODECOV ?= false
test-functional:
@./_assets/scripts/run_functional_tests.sh

canary-test: node-canary
# TODO: uncomment that!
#_assets/scripts/canary_test_mailservers.sh ./config/cli/fleet-eth.prod.json

lint-panics: generate
go run ./cmd/lint-panics -root="$(call sh, pwd)" -skip=./cmd -test=false ./...

lint: generate lint-panics
golangci-lint run ./...

ci: generate lint canary-test test-unit test-e2e ##@tests Run all linters and tests at once
ci: generate lint test-unit test-e2e ##@tests Run all linters and tests at once

ci-race: generate lint canary-test test-unit test-e2e-race ##@tests Run all linters and tests at once + race
ci-race: generate lint test-unit test-e2e-race ##@tests Run all linters and tests at once + race

clean: ##@other Cleanup
rm -fr build/bin/* mailserver-config.json
Expand All @@ -440,30 +372,6 @@ update-fleet-config: ##@other Update fleets configuration from fleets.status.im
@go generate ./static
@echo "Done"

run-bootnode-systemd: ##@Easy way to run a bootnode locally with Docker Compose
@cd _assets/systemd/bootnode && $(MAKE)

run-bootnode-docker: ##@Easy way to run a bootnode locally with Docker Compose
@cd _assets/compose/bootnode && $(MAKE)

run-mailserver-systemd: ##@Easy Run a mailserver locally with systemd
@cd _assets/systemd/mailserver && $(MAKE)

run-mailserver-docker: ##@Easy Run a mailserver locally with Docker Compose
@cd _assets/compose/mailserver && $(MAKE)

clean-bootnode-systemd: ##@Easy Clean your systemd service for running a bootnode
@cd _assets/systemd/bootnode && $(MAKE) clean

clean-bootnode-docker: ##@Easy Clean your Docker container running a bootnode
@cd _assets/compose/bootnode && $(MAKE) clean

clean-mailserver-systemd: ##@Easy Clean your systemd service for running a mailserver
@cd _assets/systemd/mailserver && $(MAKE) clean

clean-mailserver-docker: ##@Easy Clean your Docker container running a mailserver
@cd _assets/compose/mailserver && $(MAKE) clean

migration: DEFAULT_MIGRATION_PATH := appdatabase/migrations/sql
migration:
touch $(DEFAULT_MIGRATION_PATH)/$$(date '+%s')_$(D).up.sql
Expand Down
3 changes: 0 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
- [How to Build](./_docs/how-to-build.md)
- [How to Contribute](CONTRIBUTING.md)
- [How to Release](RELEASING.md)
- [How to run a Bootnode](BOOTNODE.md)
- [How to run a Mailserver](MAILSERVER.md)
- [How to run a Waku node](./_examples/README.md#run-waku-node)
- [How to configure status-go](/config/README.md)
- [How to run status-go as HTTP server](/cmd/status-backend/README.md)

Expand Down
15 changes: 0 additions & 15 deletions WAKU.md

This file was deleted.

24 changes: 0 additions & 24 deletions _assets/build/Dockerfile-bootnode

This file was deleted.

Loading