From 233124bcb7325e04efed462462a60f6679f01736 Mon Sep 17 00:00:00 2001 From: John Hill Date: Wed, 18 Sep 2024 07:53:35 -0700 Subject: [PATCH] add restart commands --- docker/Makefile | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/docker/Makefile b/docker/Makefile index 737c814..7effc2b 100644 --- a/docker/Makefile +++ b/docker/Makefile @@ -17,9 +17,9 @@ endef .PHONY: all all-10hz clean yamcs-up yamcs-down yamcs-simulator yamcs-simulator-10hz yamcs-shell help -all: clean yamcs-simulator ## run all: clean, yamcs-up (yamcs-down) and yamcs-simulator +all: clean yamcs-up yamcs-simulator ## run all: clean, yamcs-up (yamcs-down) and yamcs-simulator -all-10hz: clean yamcs-simulator-10hz ## run all: clean, yamcs-up (yamcs-down) and yamcs-simulator +all-10hz: clean yamcs-up yamcs-simulator-10hz ## run all: clean, yamcs-up (yamcs-down) and yamcs-simulator yamcs-up: | yamcs-down ## bring up yamcs system docker compose up -d @@ -28,14 +28,21 @@ yamcs-down: ## bring down yamcs system $(call print_message,33,Stopping any running docker-yamcs containers...) docker compose down -v --remove-orphans -yamcs-simulator: yamcs-up ## run yamcs simulator +yamcs-simulator: ## run yamcs simulator $(call print_message,36,Connect via http://localhost:8090/ system may take about 50 seconds to startup) cd .. && $(PYTHON) ./simulator.py -yamcs-simulator-10hz: yamcs-up ## run yamcs simulator at 10hz +yamcs-simulator-10hz: ## run yamcs simulator at 10hz $(call print_message,36,Connect via http://localhost:8090/ system may take about 50 seconds to startup) cd .. && $(PYTHON) ./simulator.py --rate=10 +yamcs-simulator-down: ## stop the yamcs simulator + $(call print_message,33,Stopping the yamcs simulator...) + pkill -f simulator.py + $(call print_message,32,Simulator stopped successfully) + +yamcs-simulator-restart: yamcs-simulator-down yamcs-simulator ## stop the yamcs simulator and start it again + yamcs-shell: ## shell into yamcs container docker compose up -d && docker compose exec yamcs bash